Exemplo n.º 1
0
        public override int GetSelectedCipherSuite()
        {
            int selectedCipherSuite = base.GetSelectedCipherSuite();

            if (TlsSrpUtilities.IsSrpCipherSuite(selectedCipherSuite))
            {
                if (mSrpIdentity != null)
                {
                    mLoginParameters = mSrpIdentityManager.GetLoginParameters(mSrpIdentity);
                }
                if (mLoginParameters == null)
                {
                    throw new TlsFatalAlert(115);
                }
            }
            return(selectedCipherSuite);
        }
Exemplo n.º 2
0
        public override int GetSelectedCipherSuite()
        {
            int cipherSuite = base.GetSelectedCipherSuite();

            if (TlsSrpUtilities.IsSrpCipherSuite(cipherSuite))
            {
                if (mSrpIdentity != null)
                {
                    this.mLoginParameters = mSrpIdentityManager.GetLoginParameters(mSrpIdentity);
                }

                if (mLoginParameters == null)
                {
                    throw new TlsFatalAlert(AlertDescription.unknown_psk_identity);
                }
            }

            return(cipherSuite);
        }