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
相关推荐
万粉变现经纪人7 分钟前
如何解决 pip install SSL 报错 ValueError: check_hostname requires server_hostname 问题
网络·python·网络协议·beautifulsoup·bug·ssl·pip
talenteddriver10 分钟前
Java Web:http请求在springboot项目中的传递层级(自用笔记)
java·前端·spring boot·http
刘孬孬沉迷学习13 分钟前
层与天线的区别
网络·学习·5g·信息与通信·mimo·预编码·层映射
冬夜戏雪17 分钟前
【学习日记】【12.30】【14/60】
服务器·网络·学习
广东大榕树信息科技有限公司31 分钟前
如何运用国产信创动环监控系统来保障生产安全与效率提升?
运维·网络·物联网·国产动环监控系统·动环监控系统
松涛和鸣35 分钟前
DAY42 SQLite3 : Dictionary Import and Data Query Implementation with C Language
linux·c语言·数据库·单片机·网络协议·sqlite
乾元1 小时前
Service Mesh 与网络抽象:AI 如何做服务层次网络策略生成(微服务 / 云原生)
网络·人工智能·安全·微服务·云原生·运维开发·service_mesh
可爱又迷人的反派角色“yang”2 小时前
GitLab配置与git集成实践
linux·网络·git·docker·云计算·gitlab
B2_Proxy2 小时前
如何搭建高速稳定安全的网络环境?住宅代理是关键
服务器·网络·安全
不染尘.2 小时前
TCP拥塞控制
服务器·网络·计算机网络·tcp