コード例 #1
0
        public byte[] GenerateRandomPrivateKey()
        {
            // The length will be random between 23 and 28
            Random random = new Random();
            int    length = random.Next(23, 28);

            byte[] randomBytes = Encrypter.GenerateTrulyRandom(length);
            return(randomBytes);
        }
コード例 #2
0
 public byte[] GenerateRandomSalt()
 {
     byte[] randomBytes = Encrypter.GenerateTrulyRandom(Utilities.SaltSizeBytes);
     return(randomBytes);
 }