当前位置:网站首页>Lane cross domain problem
Lane cross domain problem
2022-04-23 02:04:00 【N3verL4nd】
For complex requests , The browser will send a pre check request first
curl -i 'https://ds.fe.test.sankuai.com/api/groupfission/rule/activityList?page=1&size=10&title=' \
-X 'OPTIONS' \
-H 'Accept: */*' \
-H 'Accept-Language: zh-CN,zh;q=0.9' \
-H 'Access-Control-Request-Headers: access-token,client-id,swimlane' \
-H 'Access-Control-Request-Method: GET' \
-H 'Cache-Control: no-cache' \
-H 'Connection: keep-alive' \
-H 'Origin: http://127.0.0.1:8080' \
-H 'Pragma: no-cache' \
-H 'Referer: http://127.0.0.1:8080/' \
-H 'swimlane: 38941-ujzun' \
-H 'Sec-Fetch-Dest: empty' \
-H 'Sec-Fetch-Mode: cors' \
-H 'Sec-Fetch-Site: cross-site' \
-H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36' \
--compressed
SpringMVC Decision is the logic of pre inspection request :

SpringMVC Cross domain Default processing class :org.springframework.web.cors.DefaultCorsProcessor
No, cors To configure , Go straight back to .
HTTP/1.1 403 Forbidden
Server: openresty
Date: Thu, 21 Apr 2022 09:08:48 GMT
Content-Length: 20
Connection: keep-alive
M-TraceId: 5004084855451728121
Allow: GET, HEAD, POST, PUT, DELETE, TRACE, OPTIONS, PATCH
Invalid CORS request%
If the lane is configured with a white list , Trunk without , When sending a pre inspection request , Due to missing header A fixed field causes a call to the trunk . Thus, a cross domain error is reported .

Reference resources
https://www.ruanyifeng.com/blog/2016/04/cors.html
版权声明
本文为[N3verL4nd]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204220839267426.html
边栏推荐
- 006_redis_jedis快速入门
- Redis memory recycling strategy
- Is the availability of proxy IP equal to the efficiency of proxy IP?
- How to configure iptables to realize local port forwarding
- Analyze the advantages and disadvantages of tunnel proxy IP.
- Introduction to esp32 Bluetooth controller API
- BGP服务器在什么业务场景会被用到?
- [experience tutorial] Alipay balance automatically transferred to the balance of treasure how to set off, cancel Alipay balance automatically transferred to balance treasure?
- Unicorn bio raised $3.2 million to turn prototype equipment used to grow meat into commercial products
- How to write the resume of Software Test Engineer so that HR can see it?
猜你喜欢

What should I pay attention to when using proxy IP?

ESP32蓝牙Bluetooth Controller API介绍

搭建网站是用物理机还是云主机好?

What problems will you encounter when dialing VPS?

How to choose a good dial-up server?

Thinkphp内核开发盲盒商城源码v2.0 对接易支付/阿里云短信/七牛云存储

002_Redis_String类型常见的操作命令

89 logistic regression user portrait user response prediction

如何设置电脑ip?

How does Axure set the content of the text box to the current date when the page is loaded
随机推荐
Today will finally write system out. Println()
【动手学深度学习V2】循环神经网络-1.序列模型
J-link v9 使用技巧之虚拟串口功能
How to call out services in idea and display the startup class in services
Is it better to use a physical machine or a virtual machine to build a website?
What are the test steps of dynamic proxy IP?
【dpdk】10. Dpdk DNS learning notes
使用代理IP是需要注意什么?
89 logistic regression user portrait user response prediction
Chinese scientists reveal a new mechanism for breaking through the bottleneck of rice yield
Unity editor hierarchy drop-down menu extension
揭秘被Arm编译器所隐藏的浮点运算
Leetcode39 combined sum
What is BGP server and what are its advantages?
【Chrome扩展程序】content_script的跨域问题
FL studio20. 8 the latest Chinese version installation and download graphic tutorial
2022.4.10-----leetcode. eight hundred and four
How to write the resume of Software Test Engineer so that HR can see it?
Leetcode40 - total number of combinations II
The leader / teacher asks to fill in the EXCEL form document. How to edit the word / Excel file on the mobile phone and fill in the Excel / word electronic document?