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
相关推荐
思想是一切事物的源头9 分钟前
渗透测试所需域名和IP信息收集方法
网络·网络协议·tcp/ip·安全性测试
xx.ii14 分钟前
Zabbix模板,监控项,图形的使用方法
服务器·网络·zabbix
Cx330❀27 分钟前
《Linux基础入门指令(二)》:从零开始理解Linux系统
linux·运维·服务器·网络·经验分享
明月与玄武1 小时前
Linux 网络分析终极武器:Tcpdump 深度指南!
网络·php·tcpdump
_dindong1 小时前
Linux网络编程:Socket编程预备
linux·运维·网络·学习
沐浴露z1 小时前
【深入理解计算机网络11】应用层详解:DNS,WWW,HTTP
服务器·网络协议·计算机网络·http
迎風吹頭髮1 小时前
Linux服务器编程实践22-TCP头部选项解析:MSS、窗口扩大因子与SACK
服务器·网络·tcp/ip
_dindong1 小时前
Linux网络编程:宏观网络体系
linux·网络·笔记·学习
想不明白的过度思考者1 小时前
JavaEE初阶——TCP/IP协议栈:从原理到实战
java·网络·网络协议·tcp/ip·java-ee
人邮异步社区2 小时前
内网攻防实战图谱:从红队视角构建安全对抗体系
网络·安全·web安全