Пример #1
0
        // GET: /<controller>/
        public IActionResult Index()
        {
            RSAKey rsaKey = RSAHelper.CreateRsaKey();

            ViewData["publicKey"] = rsaKey.PublicKey;
            HttpContext.Session.SetString("privateKey", rsaKey.PrivateKey);

            return(View());
        }