gin-contrib / cors

Official CORS gin's middleware
https://gin-gonic.github.io/gin/
MIT License
1.79k stars 186 forks source link

Add usage of websockets and files schemas #45

Closed groovili closed 6 years ago

groovili commented 6 years ago

This change will allow usage of ws://, wss:// and file:// schemas by adding additional boolean configs.

appleboy commented 6 years ago

@groovili Thanks.

jub0bs commented 2 years ago

How this feature useful?

As far as I know, a request initiated from a file:whatever URI will invariably contain Origin: null, not Origin: file:whatever.

Besides, I don't see how a ws: or wss: URI could issue HTTP requests; but perhaps I'm missing something...