HTTP 308 错误永久重定向 (Permanent Redirect)

HTTP 308 错误永久重定向 (Permanent Redirect)

测试环境访问另一个系统时报错
使用curl 测试

复制代码
curl --location --request POST 'http://xxxxx.cn/login' \ 

--header 'Content-Type: application/json' \
--data-raw '{
  "username": "admin",
  "password": "123456" 
}'
curl: (60) SSL certificate problem: self-signed certificate
More details here: https://curl.se/docs/sslcerts.html

curl failed to verify the legitimacy of the server and therefore could not
establish a secure connection to it. To learn more about this situation and
how to fix it, please visit the web page mentioned above.

结果说是证书问题 因为请求里面用的是http 测试环境没有配置

然后使用-k还会出现别的错误就不再演示

正确配置

xxxx.cn 这个域名指向 192.168.1.156 这个 IP 地址

复制代码
vim /etc/hosts

192.168.1.156   xxxx.cn
相关推荐
G_H_S_3_17 分钟前
【网络运维】Docker 存储:镜像层与数据卷的管理应用
linux·运维·网络·docker
还鮟2 小时前
靶机远程控制实验命令与入门实践(Linux)
linux·网络·安全
Hello.Reader4 小时前
Flink Process Table Functions(PTF)实战详解:把 SQL 变成“可编程算子”,状态、时间、定时器一把梭
网络·sql·flink
2301_773730316 小时前
网络编程—TCP传输控制协议
服务器·网络·tcp/ip
云老大TG:@yunlaoda3606 小时前
华为云国际站代理商DAS的跨境合规适配是如何保障数据合规的?
网络·数据库·华为云
科技块儿6 小时前
【账号安全预警】如何基于IP查询进行登录异常识别、账号防盗?
网络协议·tcp/ip·安全
TG:@yunlaoda360 云老大6 小时前
华为云国际站代理商DAS的跨境合规适配在游戏出海场景中的应用
服务器·网络·游戏·华为云
没有bug.的程序员6 小时前
熔断、降级、限流:高可用架构的三道防线
java·网络·jvm·微服务·架构·熔断·服务注册
知新坊7 小时前
飞牛NAS 没有公网 IP?使用它让 NAS 访问、文件远程像在局域网
网络·网络协议·tcp/ip
emma羊羊7 小时前
【AWVS】漏扫工具
网络·安全·web安全·awvs