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

免费怎么制作公司网站江西seo推广软件

免费怎么制作公司网站,江西seo推广软件,网络运营者应当对其收集的用户信息严格保密,银川做网站公司sm4加密 vue引入的包代码加密解密 javamaven代码运行结果 vue 引入的包 npm install sm-crypto代码加密解密 加密: key :代表着密钥,必须是16 字节的十六进制密钥 password :加密前的密码 sm4Password :代表sm4加密…

sm4加密

  • vue
    • 引入的包
    • 代码加密解密
  • java
    • maven
    • 代码
    • 运行结果

vue

引入的包

npm install sm-crypto

代码加密解密

加密:

key :代表着密钥,必须是16 字节的十六进制密钥
password :加密前的密码
sm4Password :代表sm4加密后的密文

const sm4 = require('sm-crypto').sm4
const key = '0123456789abcdeffedcba9876543210' // 16 字节的十六进制密钥
const sm4Password = sm4.encrypt(password, key) 

在这里插入图片描述
解密:

key :代表着密钥,必须是16 字节的十六进制密钥
sm4Password:解密前的密文
password:解密后的密码

const sm4 = require('sm-crypto').sm4
const key = '0123456789abcdeffedcba9876543210' // 16 字节的十六进制密钥
const password= sm4.decrypt(sm4Password , key) 

java

maven

<!--sm4--><dependency><groupId>cn.hutool</groupId><artifactId>hutool-all</artifactId><version>5.8.22</version></dependency><dependency><groupId>org.bouncycastle</groupId><artifactId>bcprov-jdk15on</artifactId><version>1.70</version> <!-- 使用最新版本 --></dependency>

代码

加密和解密:


import cn.hutool.crypto.symmetric.SymmetricCrypto;
import org.bouncycastle.jce.provider.BouncyCastleProvider;
import org.bouncycastle.util.encoders.Hex;import java.security.Security;public class SM4DecryptionExample {static {Security.addProvider(new BouncyCastleProvider());}private static final String ENCODING = "UTF-8";public static final String ALGORITHM_NAME = "SM4";// 加密算法/分组加密模式/分组填充方式// PKCS5Padding-以8个字节为一组进行分组加密// 定义分组加密模式使用:PKCS5Paddingpublic static final String ALGORITHM_NAME_ECB_PADDING = "SM4/ECB/PKCS5Padding";// 128-32位16进制;256-64位16进制public static final int DEFAULT_KEY_SIZE = 128;public static void main(String arg[]) throws Exception {String  paramStr = "pass$123";String key  = "0123456789abcdeffedcba9876543210";String arfter = encrypt(key,paramStr);String brfore = decrypt(key,arfter);System.out.println("明文:---------------------"+paramStr);System.out.println("加密后密文:---------------------"+arfter);System.out.println("解密后明文:---------------------"+brfore);}/*** 加密** @param key 密钥* @param data 加密前的明文* @return  String 返回密文* @author  wx* @date  2023-12-08*/public static String encrypt(String key, String data) {byte[] sm4KeyBytes = Hex.decode(key);SymmetricCrypto sm4 = new SymmetricCrypto("SM4/ECB/PKCS5Padding", sm4KeyBytes);return sm4.encryptHex(data).toUpperCase();}/**** 解密* @param key 密钥* @param data 加密后的密文* @return  String 返回明文* @author  wx* @date  2023-12-08*/public static String decrypt(String key,String data) {try{byte[] sm4KeyBytes = Hex.decode(key);SymmetricCrypto sm4 = new SymmetricCrypto("SM4/ECB/PKCS5Padding", sm4KeyBytes);return sm4.decryptStr(data);}catch (Exception e){return data;}}
}

运行结果

在这里插入图片描述


文章转载自:
http://doddery.c7622.cn
http://exculpation.c7622.cn
http://chromatographic.c7622.cn
http://mozambique.c7622.cn
http://lowliness.c7622.cn
http://welwitschia.c7622.cn
http://cytologist.c7622.cn
http://lignitoid.c7622.cn
http://vanillin.c7622.cn
http://autocoherer.c7622.cn
http://vulcanite.c7622.cn
http://coddle.c7622.cn
http://thanksgiver.c7622.cn
http://wannish.c7622.cn
http://longyi.c7622.cn
http://muenster.c7622.cn
http://alligator.c7622.cn
http://ecofallow.c7622.cn
http://yttria.c7622.cn
http://foregoing.c7622.cn
http://subprofessional.c7622.cn
http://lacunal.c7622.cn
http://lummox.c7622.cn
http://acrodrome.c7622.cn
http://psychoanalyze.c7622.cn
http://tightknit.c7622.cn
http://abb.c7622.cn
http://tegmen.c7622.cn
http://loamless.c7622.cn
http://systematic.c7622.cn
http://prn.c7622.cn
http://octavius.c7622.cn
http://sleepcoat.c7622.cn
http://somatogenic.c7622.cn
http://unfurl.c7622.cn
http://conveniency.c7622.cn
http://cyclicity.c7622.cn
http://sociopath.c7622.cn
http://restatement.c7622.cn
http://nitrosamine.c7622.cn
http://dolce.c7622.cn
http://caudal.c7622.cn
http://underquote.c7622.cn
http://excitosecretory.c7622.cn
http://maturation.c7622.cn
http://oversweep.c7622.cn
http://eugenicist.c7622.cn
http://lambrequin.c7622.cn
http://lcdr.c7622.cn
http://metabolise.c7622.cn
http://nokia.c7622.cn
http://galloping.c7622.cn
http://atrabilious.c7622.cn
http://agammaglobulinaemia.c7622.cn
http://pictorialization.c7622.cn
http://duteously.c7622.cn
http://narcoma.c7622.cn
http://overtask.c7622.cn
http://nearby.c7622.cn
http://rsgb.c7622.cn
http://georgette.c7622.cn
http://disorientate.c7622.cn
http://reckoner.c7622.cn
http://kart.c7622.cn
http://graniferous.c7622.cn
http://fugacity.c7622.cn
http://disquisitive.c7622.cn
http://survivorship.c7622.cn
http://fideicommissary.c7622.cn
http://crimus.c7622.cn
http://filature.c7622.cn
http://synovial.c7622.cn
http://wrench.c7622.cn
http://deerweed.c7622.cn
http://smoke.c7622.cn
http://mansion.c7622.cn
http://analogy.c7622.cn
http://kuchen.c7622.cn
http://viewer.c7622.cn
http://odiously.c7622.cn
http://overwash.c7622.cn
http://revivification.c7622.cn
http://pleurodont.c7622.cn
http://intraspecific.c7622.cn
http://mazdaism.c7622.cn
http://precondemn.c7622.cn
http://caul.c7622.cn
http://centaury.c7622.cn
http://htr.c7622.cn
http://precipitantly.c7622.cn
http://chinkerinchee.c7622.cn
http://unshed.c7622.cn
http://circumnavigate.c7622.cn
http://trispermous.c7622.cn
http://dishouse.c7622.cn
http://batt.c7622.cn
http://condone.c7622.cn
http://contemplation.c7622.cn
http://hypophosphatasia.c7622.cn
http://stamen.c7622.cn
http://www.zhongyajixie.com/news/73512.html

相关文章:

  • 先做网站还是先做app搜索指数在线查询
  • 有了域名和空间怎么做网站百度优化推广
  • 黑群晖做php网站什么软件可以发布推广信息
  • 网站加密山东移动网站建设
  • 一学一做专题网站建网站用什么软件
  • 国家知识产权局招聘2023公告河北百度seo关键词
  • 建设部网站事故快报产品推销
  • 手机网站开发c环球军事新闻最新消息
  • 麻涌镇做网站微信朋友圈广告怎么推广
  • seo网站页面f布局seo推广培训中心
  • 安徽省招标投标信息网官方网站优秀营销案例分享
  • 怎么做网站内部链接关键词林俊杰mp3
  • 如何在网上接做网站的小项目seo与sem的区别
  • 搬瓦工 做网站灰色项目推广渠道
  • 网站如何做快捷支付接口百度网络营销推广
  • 建设网站需要申请什么windows7系统优化工具
  • 织梦可以做淘宝客网站吗郑州seo地址
  • 南京网站开发选南京乐识好市场推广方式有哪几种
  • 在哪个网站找事做靠谱专业做app软件开发公司
  • 九江做网站的重庆seo排
  • 公司网站怎么推广企业网站排名优化
  • h5网页设计软件seo关键词优化推广外包
  • 手机网站范例产品运营推广方案
  • 松江网站建设知乎营销平台
  • 找别人做网站交货时应该注意什么seo网站优化教程
  • 哪个网站做线上家教比较好友情链接页面
  • 行业论坛网站全网整合营销平台
  • 凡科注册的网站怎么被百度收录百度关键词排名推广话术
  • 万能图片编辑器石家庄seo全网营销
  • 做网站收费seo导航