public static string sign(string content, string privateKey, string input_charset)
{
Encoding code = Encoding.GetEncoding(input_charset);
byte[] Data = code.GetBytes(content);
RSACryptoServiceProvider rsa = DecodePemPrivateKey(privateKey);
SHA1 sh = new SHA1CryptoServiceProvider();
byte[] signData = rsa.SignData(Data, sh);
return Convert.ToBase64String(signData);
}
/// <summary>
/// Ñé֤ǩÃû
/// </summary>
/// <param name="content">ÐèÒªÑéÖ¤µÄÄÚÈÝ</param>
/// <param name="signedString">Ç©Ãû½á¹û</param>
/// <param name="publicKey">¹«Ô¿</param>
/// <param name="input_charset">±àÂë¸ñʽ</param>
/// <returns></returns>
¡¡