Nacos 2.2.1启动报错

错误信息:

The specified key byte array is 248 bits which is not secure enough

for any JWT HMAC-SHA algorithm. The JWT JWA Specification (RFC 7518,

Section 3.2) states that keys used with HMAC-SHA algorithms MUST have

a size >= 256 bits (the key size must be greater than or equal to the

hash output size). See

https://tools.ietf.org/html/rfc7518#section-3.2 for more information.

翻译如下:

指定的密钥字节数组是248位,这对于任何JWT HMAC-SHA算法来说都不够安全。JWT JWA规范(RFC

7518,第3.2节)规定,与HMAC-SHA算法一起使用的密钥必须具有>=256位的大小(密钥大小必须大于或等于哈希输出大小)。看见https://tools.ietf.org/html/rfc7518#section-3.2了解更多信息。

解决办法:

修改 Nacos/config 文件夹里面 application.properties 文件,在大约第156行:

yaml 复制代码
### The default token (Base64 String):
nacos.core.auth.plugin.nacos.token.secret.key= [建议50位以上base64编码]
相关推荐
阿部多瑞 ABU7 小时前
`chenmo` —— 可编程元叙事引擎 V2.3+
linux·人工智能·python·ai写作
徐同保7 小时前
nginx转发,指向一个可以正常访问的网站
linux·服务器·nginx
HIT_Weston7 小时前
95、【Ubuntu】【Hugo】搭建私人博客:_default&partials
linux·运维·ubuntu
实心儿儿8 小时前
Linux —— 基础开发工具5
linux·运维·算法
oMcLin8 小时前
如何在SUSE Linux Enterprise Server 15 SP4上通过配置并优化ZFS存储池,提升文件存储与数据备份的效率?
java·linux·运维
我是苏苏9 小时前
Web开发:C#通过ProcessStartInfo动态调用执行Python脚本
java·服务器·前端
瑶山9 小时前
Spring Cloud微服务搭建一、Nacos配置和服务注册
spring·spring cloud·微服务·nacos
相偎10 小时前
Ubuntu搭建svn服务器
服务器·ubuntu·svn
咕噜企业分发小米11 小时前
有哪些开源的直播云服务器安全防护方案?
运维·服务器·云计算
开开心心_Every12 小时前
安卓后台录像APP:息屏录存片段,行车用
java·服务器·前端·学习·eclipse·edge·powerpoint