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 分钟前
新手必看!注入攻击的实际案例剖析
网络
John_ToDebug44 分钟前
拆解AI的“五大基础设施”:算力、网络、存储、电力、软件,谁在驱动千亿市值?
网络·人工智能
想唱rap1 小时前
应用层HTTPS协议
服务器·网络·c++·网络协议·http·https
想唱rap1 小时前
传输层协议之UDP
java·linux·网络·c++·网络协议·mysql·udp
AIGC设计所1 小时前
网络安全8大就业领域和待遇对比!
运维·开发语言·网络·安全·web安全·php
网安薯条2 小时前
Kali Linux 虚拟机安装与基础配置保姆级图文教程
linux·运维·网络·安全·web安全·网络安全
yantaohk2 小时前
普通人怎么利用PCDN赚钱?几个接地气的案例告诉你
大数据·网络
wangl_922 小时前
Modbus RTU 与 Modbus TCP 深入指南-目录
网络·网络协议·tcp/ip·tcp·modbus·rtu
05候补工程师2 小时前
【408 应用层通关】DNS 域名解析负载博弈、HTTP 延迟计算与邮件协议全家桶详解
网络·经验分享·笔记·网络协议·计算机网络·http
代码中介商2 小时前
Linux TCP/UDP 网络编程完全指南:从基础到实践
linux·网络·tcp/ip