摘要: public static class RSAHelper { /// <summary> /// RSA的容器 可以解密的源字符串长度为 DWKEYSIZE/8-11 /// </summary> public const int DWKEYSIZE = 1024; /// <summary> / 阅读全文
posted @ 2021-10-22 08:54 龙丶谈笑风声 阅读(811) 评论(0) 推荐(0) 编辑
摘要: public static class RSAExtensions { /// <summary> /// 把java的私钥转换成.net的xml格式 /// </summary> /// <param name="rsa"></param> /// <param name="privateJava 阅读全文
posted @ 2021-10-22 08:51 龙丶谈笑风声 阅读(160) 评论(0) 推荐(0) 编辑
摘要: public static class RsaKeysFormatExtensions { /// <summary> /// XML公钥转成Pem公钥 /// </summary> /// <param name="xmlPublicKey"></param> /// <returns></ret 阅读全文
posted @ 2021-10-21 17:36 龙丶谈笑风声 阅读(1674) 评论(0) 推荐(0) 编辑
摘要: public static void Generator(out string PrivarteKey, out string PublicKey, int KeySize = 1024) { RSACryptoServiceProvider rea = new RSACryptoServicePr 阅读全文
posted @ 2021-10-21 17:35 龙丶谈笑风声 阅读(825) 评论(0) 推荐(0) 编辑
摘要: 使用类库:“BouncyCastle.NetCore”(.Net FrameWork使用“BouncyCastle”) /// <summary> /// 生成PEM格式的公钥和密钥 /// </summary> /// <param name="strength">长度</param> /// < 阅读全文
posted @ 2021-10-21 17:32 龙丶谈笑风声 阅读(1192) 评论(0) 推荐(0) 编辑
摘要: /// <summary> /// LDAP工具类 /// </summary> public static class LDAPUtil { public static string Domain = "SHTAI";//域名称 public static string Host = "ip";/ 阅读全文
posted @ 2021-10-21 13:47 龙丶谈笑风声 阅读(286) 评论(0) 推荐(0) 编辑
摘要: /// <summary> /// DataTable帮助类 /// </summary> public class DataTableHelper { /// <summary> /// dataTable赋值给另一个DataTable /// 注意rows是否对应,否则就会修改成错误数据 /// 阅读全文
posted @ 2021-10-21 13:46 龙丶谈笑风声 阅读(414) 评论(0) 推荐(0) 编辑
摘要: public class RSAHelper { public static void Generator(out string PrivarteKey, out string PublicKey, int KeySize = 1024) { RSACryptoServiceProvider rea 阅读全文
posted @ 2021-10-21 13:45 龙丶谈笑风声 阅读(522) 评论(0) 推荐(0) 编辑
摘要: public class MSqlHelper: IDisposable { private string ConnectionString = ""; /// <summary> /// 批量操作每批次记录数 /// </summary> public static int BatchSize = 阅读全文
posted @ 2021-10-21 13:43 龙丶谈笑风声 阅读(1235) 评论(0) 推荐(0) 编辑
摘要: public class CacheHelper { public static IMemoryCache _memoryCache = new MemoryCache(new MemoryCacheOptions()); /// <summary> /// 缓存绝对过期时间 /// </summa 阅读全文
posted @ 2021-10-21 13:42 龙丶谈笑风声 阅读(330) 评论(0) 推荐(0) 编辑