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
相关推荐
ysa05103020 小时前
【板子】Dinic(最大网络流)
网络
我星期八休息20 小时前
网络编程—应用层HTTP协议
linux·运维·开发语言·前端·网络·网络协议·http
ShineWinsu21 小时前
对于Linux:UDPsocket编程基础的解析
linux·运维·网络协议·udp·ip·端口号·进程间通信
ITxiaobing202321 小时前
IP库与AppsFlyer数据对账指南:破解国家/地区数据不一致的难题
网络·网络协议
有浔则灵21 小时前
GORM钩子函数详解
网络·安全·web安全
汇智信科1 天前
图谱、向量、关键词、SQL多路一体,FastKG垂域召回率100%拉满
网络·数据库·ai编程·汇智信科·hsim·fastclaw·汇智龙虾
liulilittle1 天前
论分布式系统的半开闭问题
服务器·网络·分布式·系统架构·竞态
FreeBuf_1 天前
仅用六分钟,黑客借助Gemini CLI自主构建并迁移C&C僵尸网络
网络·人工智能
cyforkk1 天前
Vercel 绑定自定义域名极简配置指南
服务器·前端·网络
Yang96111 天前
探索无线新视界:鼎讯信通DXMP系列频谱仪模块深度剖析
运维·网络