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
相关推荐
五仁火烧15 分钟前
生产环境中配置了接口3000后,不能启动,改成8080后就可以
linux·网络·安全·vue
橙露26 分钟前
国产PLC与进口PLC全面对比分析:技术、市场与未来趋势
运维·网络
chilavert3181 小时前
技术演进中的开发沉思-302计算机原理:网络基础
网络·计算机原理
Hellc0071 小时前
Docker网络冲突排查与解决方案:完整指南
网络·docker·容器
眠りたいです1 小时前
Docker核心技术和实现原理第二部分:docker镜像与网络原理
运维·网络·docker·容器
ps酷教程2 小时前
HttpPostRequestDecoder源码浅析
java·http·netty
闲人编程2 小时前
消息通知系统实现:构建高可用、可扩展的企业级通知服务
java·服务器·网络·python·消息队列·异步处理·分发器
Xの哲學2 小时前
Linux Platform驱动深度剖析: 从设计思想到实战解析
linux·服务器·网络·算法·边缘计算
ikkkkkkkl2 小时前
计算机网络:物理层
网络·计算机网络·物理层
镜中人★2 小时前
408计算机组成原理考纲知识点
网络·笔记