Exemplo n.º 1
0
        public IJwsSigner Get(IDictionary <string, object> extParams = null)
        {
            var signer = new Rs256Signer();

            ExtUtil.ResolveParams(EXT_PARAMS, extParams, signer.Params);
            signer.Init();
            return(signer);
        }
Exemplo n.º 2
0
        public static Rs256Signer Load(Stream stream)
        {
            SignerState state;

            using (var sr = new StreamReader(stream))
            {
                state = JsonSerializer.Deserialize <SignerState>(sr.ReadToEnd());
            }

            var signer = new Rs256Signer(state.Params);

            signer.Init();
            signer._rsa.ImportParameters(state.RsaParameters);

            return(signer);
        }
Exemplo n.º 3
0
 public IJwsSigner Load(Stream stream)
 {
     return(Rs256Signer.Load(stream));
 }