Skip to content

manelmontilla/nocors

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

nocors

A simple HTTP reverse proxy that disables CORS in the upstream server.

It intercepts all the preflight requests and adds the proper "Access-Control-Allow-Origin" header to all responses.

Install

go install github.com/manelmontilla/nocors/cmd/nocors@latest

Usage

nocors listen_address dest_address

Example

The following example disables CORS in the upstream server listening in the address: 127.0.0.1:8080

nocors 127.0.0.1:8081 127.0.0.1:8080

To access the server listening in the port 8080 with CORS disabled, just use 127.0.0.1:8081 as base address in your browser.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages