jwk 0.1.0-nullsafety.0 copy "jwk: ^0.1.0-nullsafety.0" to clipboard
jwk: ^0.1.0-nullsafety.0 copied to clipboard

outdated

JWK (JSON Web Key) encoding and decoding (for package:cryptography).

Pub Package Github Actions CI

Overview #

JWK (JSON Web Key) encoding and decoding. Designed to be used with package:cryptography.

Examples #

Encoding KeyPair #

import 'package:cryptography/cryptography.dart';
import 'package:jwk/jwk.dart';

void main() {
  final keyPair = RsaKeyPairGenerator().newKeyPair();
  final jwk = Jwk.fromKeyPair(keyPair);
  final json = jwk.toJson();
}

Decoding SecretKey #

import 'package:jwk/jwk.dart';

void main() {
  final jwk = Jwk.fromJson({
    'kty': 'OCS',
    'x': 'base 64 string',
  });
  final secretKey = jwk.toSecretKey();
}
5
likes
0
pub points
67%
popularity

Publisher

verified publisherdint.dev

JWK (JSON Web Key) encoding and decoding (for package:cryptography).

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

collection, cryptography

More

Packages that depend on jwk