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
相关推荐
nbsaas-boot1 小时前
基于 HTTP 构建 MCP Tools 的完整工程解析
网络·网络协议·http·ai
i建模1 小时前
SSL: CERTIFICATE_VERIFY_FAILED feishu 机器人CoPaw
运维·网络·网络协议·ssl·openclaw
艾莉丝努力练剑1 小时前
alarm系统调用的一次性原理揭秘
linux·运维·服务器·开发语言·网络·人工智能·学习
王码码20351 小时前
Flutter for OpenHarmony:使用 pluto_grid 打造高性能数据网格
flutter·http·华为·架构·harmonyos
先跑起来再说1 小时前
从原理到实践:彻底搞懂Cookie和Session的区别
计算机网络·http·https
兰.lan1 小时前
【黑马ai测试】HTTP协议-抓包工具定位-弱网测试-缺陷介绍
网络·python·网络协议·http
ACP广源盛139246256731 小时前
IX8024@ACP#重构新一代 AI 算力产品的高速扩展架构
网络·人工智能·嵌入式硬件·计算机外设·电脑
多年小白3 小时前
Anthropic发布Mythos模型:为什么网络安全板块先跌为敬
网络·人工智能·科技·ai编程
fresh hacker3 小时前
【Linux系统】通用的“系统排障”
linux·运维·服务器·网络·php
liwulin05063 小时前
【ESP32-S3】WiFi 网页遥控 + WebSocket 实时控制编码电机+ 实时数据显示 + 急停 + 速度滑块
网络·websocket·网络协议