You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 line
965 B

  1. using GBNewEnergy.Protocol.Enums;
  2. using System.Text;
  3. namespace GBNewEnergy.Protocol
  4. {
  5. public class NEGlobalConfigs
  6. {
  7. /// <summary>
  8. /// 加密编码
  9. /// </summary>
  10. public Encoding NEEncryptEncoding { get; set; } = Encoding.UTF8;
  11. /// <summary>
  12. /// 字符串编码
  13. /// </summary>
  14. public Encoding NEEncoding { get; set; } = Encoding.UTF8;
  15. /// <summary>
  16. /// 数据单元加密方式
  17. /// 0x01:数据不加密;0x02:数据经过 RSA 算法加密;0x03:数据经过 AES128 位算法加密;“0xFE”表示异常,“0xFF”表示无效
  18. /// </summary>
  19. public NEEncryptMethod EncryptMethod { get; set; } = NEEncryptMethod.None;
  20. /// <summary>
  21. /// 数据单元加密
  22. /// 当数据单元存在加密时,应先加密后校验,先校验后解密
  23. /// </summary>
  24. public INEEncrypt Encrypt { get; set; }
  25. }
  26. }