C# c语言中哪种加密和解密算法最好?

C# c语言中哪种加密和解密算法最好?,c#,winforms,C#,Winforms,我想要非常好的c?加密和解密算法 我在谷歌上搜索了一些页面,。。我有一个 private string base64Encode(string sData) { try { byte[] encData_byte = new byte[sData.Length]; encData_byte = System.Text.Encoding.UTF8.GetBytes(sD

我想要非常好的c?加密和解密算法

我在谷歌上搜索了一些页面,。。我有一个

 private string base64Encode(string sData)
        {
            try
            {
                byte[] encData_byte = new byte[sData.Length];
                encData_byte = System.Text.Encoding.UTF8.GetBytes(sData);
                string encodedData = Convert.ToBase64String(encData_byte);            
                return encodedData;
            }
            catch (Exception ex)
            {
                throw new Exception("Error in base64Encode" + ex.Message);
            }
        }

  public string base64Decode(string sData)
        {
            System.Text.UTF8Encoding encoder = new System.Text.UTF8Encoding();
            System.Text.Decoder utf8Decode = encoder.GetDecoder();
            byte[] todecode_byte = Convert.FromBase64String(sData);
            int charCount = utf8Decode.GetCharCount(todecode_byte, 0, todecode_byte.Length);
            char[] decoded_char = new char[charCount];
            utf8Decode.GetChars(todecode_byte, 0, todecode_byte.Length, decoded_char, 0);
            string result = new String(decoded_char);
            return result;
        }
好吗?。否则我建议一个好的


提前谢谢

第一个编码不是加密

加密算法的选择将取决于解决方案的要求。没有抽象的最好


你必须考虑你需要的保护级别,你必须执行操作的时间以及如何传输密钥。

Base64不是加密。最佳解密算法是匹配加密算法的一个。我要加密和解密我的用户ID和密码!!有谁能推荐好的加密和解密算法吗?请下次试着用规范提问。@Sagatharan,在给出大量上下文的情况下,重新问这个问题,一定要解释为什么不使用操作系统内置的功能。谢谢!。我现在很清楚了!。