当前位置: 首页 > news >正文

建设通网站上的业绩能否删除掉wordpress get option

建设通网站上的业绩能否删除掉,wordpress get option,建材团购网站建设方案,怎样建立网页一、AES 高级加密标准(AES,Advanced Encryption Standard)为最常见的对称加密算法(微信小程序加密传输就是用这个加密算法的)。对称加密算法也就是加密和解密用相同的密钥#xff0c;具体的加密流程如下: 加密#xff1a;明文P通过AES加密函数和密匙K进行加密#xff0c;得…一、AES 高级加密标准(AES,Advanced Encryption Standard)为最常见的对称加密算法(微信小程序加密传输就是用这个加密算法的)。对称加密算法也就是加密和解密用相同的密钥具体的加密流程如下: 加密明文P通过AES加密函数和密匙K进行加密得到秘文C 解密秘文C通过AES解密函数和密匙K进行解密得到明文P 密钥必须是16字节的长度代码如下public class AESExample {public static void main(String[] args) throws Exception {String plaintext Hello, AES!; // 要加密的明文String key ThisIsASecretKey; // 密钥必须是16字节的长度byte[] encrypted encrypt(plaintext, key);System.out.println(加密后的结果 encodeBase64(encrypted));String decrypted decrypt(encrypted, key);System.out.println(解密后的结果 decrypted);}public static byte[] encrypt(String plaintext, String key) throws Exception {SecretKeySpec secretKey new SecretKeySpec(key.getBytes(StandardCharsets.UTF_8), AES);Cipher cipher Cipher.getInstance(AES/ECB/PKCS5Padding);cipher.init(Cipher.ENCRYPT_MODE, secretKey);return cipher.doFinal(plaintext.getBytes(StandardCharsets.UTF_8));}public static String decrypt(byte[] ciphertext, String key) throws Exception {SecretKeySpec secretKey new SecretKeySpec(key.getBytes(StandardCharsets.UTF_8), AES);Cipher cipher Cipher.getInstance(AES/ECB/PKCS5Padding);cipher.init(Cipher.DECRYPT_MODE, secretKey);byte[] decryptedBytes cipher.doFinal(ciphertext);return new String(decryptedBytes, StandardCharsets.UTF_8);}public static String encodeBase64(byte[] bytes) {return Base64.getEncoder().encodeToString(bytes);} } 二、RSA RSA加密算法是一种典型的非对称加密算法它基于大数的因式分解数学难题它也是应用最广泛的非对称加密算法。非对称加密是通过两个密钥公钥-私钥来实现对数据的加密和解密的。公钥用于加密私钥用于解密具体的加密流程如下 加密方通过公钥和加密函数对明文进行加密 解密方通过解密函数和私钥对密文进行解密 public class RSAExample {public static void main(String[] args) throws Exception {String plaintext Hello, RSA!; // 要加密的明文KeyPair keyPair generateKeyPair();PublicKey publicKey keyPair.getPublic();PrivateKey privateKey keyPair.getPrivate();byte[] encrypted encrypt(plaintext, publicKey);System.out.println(加密后的结果 encodeBase64(encrypted));String decrypted decrypt(encrypted, privateKey);System.out.println(解密后的结果 decrypted);}public static KeyPair generateKeyPair() throws Exception {KeyPairGenerator keyPairGenerator KeyPairGenerator.getInstance(RSA);keyPairGenerator.initialize(2048, new SecureRandom());return keyPairGenerator.generateKeyPair();}public static byte[] encrypt(String plaintext, PublicKey publicKey) throws Exception {Cipher cipher Cipher.getInstance(RSA/ECB/PKCS1Padding);cipher.init(Cipher.ENCRYPT_MODE, publicKey);return cipher.doFinal(plaintext.getBytes());}public static String decrypt(byte[] ciphertext, PrivateKey privateKey) throws Exception {Cipher cipher Cipher.getInstance(RSA/ECB/PKCS1Padding);cipher.init(Cipher.DECRYPT_MODE, privateKey);byte[] decryptedBytes cipher.doFinal(ciphertext);return new String(decryptedBytes);}public static String encodeBase64(byte[] bytes) {return Base64.getEncoder().encodeToString(bytes);} }三、CRC 循环冗余校验(Cyclic Redundancy Check, CRC)是一种根据网络数据包或电脑文件等数据产生简短固定位数校验码的一种散列函数主要用来检测或校验数据传输或者保存后可能出现的错误。它是利用除法及余数的原理来作错误侦测的。 public class CRCExample {public static void main(String[] args) {String data Hello, CRC!; // 要计算CRC的数据long crcValue calculateCRC(data);System.out.println(CRC校验值 crcValue);}public static long calculateCRC(String data) {CRC32 crc32 new CRC32();crc32.update(data.getBytes());return crc32.getValue();} } 四、MD5 MD5常常作为文件的签名出现我们在下载文件的时候常常会看到文件页面上附带一个扩展名为.MD5 的文本或者一行字符这行字符就是就是把整个文件当作原数据通过 MD5 计算后的值我们下载文件后可以用检查文件 MD5 信息的软件对下载到的文件在进行一次计算。两次结果对比就可以确保下载到文件的准确性。 另一种常见用途就是网站敏感信息加密比如用户名密码支付签名等等。随着 https 技术的普及现在的网站广泛采用前台明文传输到后台MD5 加密使用偏移量的方式保护敏感数据保护站点和数据安全 public class MD5Example {public static void main(String[] args) {String plaintext Hello, MD5!; // 要加密的明文String encrypted encryptMD5(plaintext);System.out.println(加密后的结果 encrypted);}public static String encryptMD5(String plaintext) {try {MessageDigest md MessageDigest.getInstance(MD5);byte[] hashBytes md.digest(plaintext.getBytes());BigInteger hashNum new BigInteger(1, hashBytes);String encrypted hashNum.toString(16);while (encrypted.length() 32) {encrypted 0 encrypted;}return encrypted;} catch (Exception e) {// 处理异常e.printStackTrace();}return null;} }
http://wiki.neutronadmin.com/news/174357/

相关文章:

  • 1688网站建设方案书模板免费海外网站建设
  • 内江市网站建设建网通
  • 深圳做模板网站的公司网站网页直播怎么做
  • 专门做恐怖电影网站关于志愿者网站开发的论文
  • 找南昌网站开发公司电话wordpress主题文件夹在哪
  • 移动网站建站网站流量报表
  • 京东联盟怎么做网站无烟锅网站规划与建设
  • 电商网站策划网站后台管理要求
  • 网站开发的流程建设摩托车公司官方网站
  • 英文网站建设网站站群宝塔批量建站
  • 网站开发设计文案书店网站策划书
  • 怎样将视频放在网站里做网站系统建设招标公告
  • 那种非法网站怎么做的网站域名备案查询系统
  • 酒店网站开发合同有网络网站打不开怎么回事
  • 巨鹿网站建设公司很简单的做设计的网站
  • 企业网站的建设包括页面模板在公号什么地方显示
  • 网站排名如何稳定长沙 网站建设公司
  • 女人能做网站开发吗vs2017手机网站开发
  • 如何查找高权重网站济南建设局
  • 做电影网站服务器需求比较好网站搭建公司
  • 被攻击网站怎么做自己网站里的资讯
  • 宁波高质量品牌网站设计厂家app开发公司图片
  • 电子商务网站的建设心得体会金华高端网站建设公司
  • 广州高端模板网站在华图做网站编辑
  • 企业网站主页设计wordpress 默认编辑器
  • 景区门户网站建设江苏建信建设集团网站
  • 成都建设局网站网站性能策划
  • asp网站安装c qq 互联网站开发代码
  • 资讯网站优化排名利用网络挣钱的路子
  • 网站建设作品2016 网站建设需求