Skip to content

Commit

Permalink
docs: remove CORS Credentials header (#45)
Browse files Browse the repository at this point in the history
Share App does not need this header.

See also:

- Potential problem with  `Access-Control-Allow-Credentials`: ipfs/kubo#5745
- HTTP Headers Cleanup: ipfs/in-web-browsers#132
  • Loading branch information
lidel authored and fsdiogo committed Nov 19, 2018
1 parent 4ca3fd4 commit 834d167
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 3 deletions.
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ Or do it manually:
```sh
> ipfs config --json API.HTTPHeaders.Access-Control-Allow-Origin '["http://localhost:3000", "https://share.ipfs.io"]'
> ipfs config --json API.HTTPHeaders.Access-Control-Allow-Methods '["PUT", "GET", "POST"]'
> ipfs config --json API.HTTPHeaders.Access-Control-Allow-Credentials '["true"]'
```

To reset the config to its default state run:
Expand Down
1 change: 0 additions & 1 deletion cors-config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ set -e

ipfs config --json API.HTTPHeaders.Access-Control-Allow-Origin "[$ALLOW_ORIGINS]"
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Methods '["PUT", "GET", "POST"]'
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Credentials '["true"]'

echo "IPFS API CORS headers configured for $ALLOW_ORIGINS"
echo "Please restart your IPFS daemon"
1 change: 0 additions & 1 deletion src/components/box/Box.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ export const RawBoxNotAvailable = ({ t }) => (
<div className='pa3 bg-black-80 bt bw4 br2 gray-muted f7 nowrap overflow-x-scroll'>
<code className='db'>$ ipfs config --json API.HTTPHeaders.Access-Control-Allow-Origin '["{ window.location.origin }", "https://share.ipfs.io"]'</code>
<code className='db'>$ ipfs config --json API.HTTPHeaders.Access-Control-Allow-Methods '["PUT", "GET", "POST"]'</code>
<code className='db'>$ ipfs config --json API.HTTPHeaders.Access-Control-Allow-Credentials '["true"]'</code>
</div>
<p className='mv3 navy f6 lh-copy'>{t('box.runDaemon')}</p>
<div className='pa3 bg-black-80 bt bw4 br2 gray-muted f7 nowrap overflow-x-scroll'>
Expand Down

0 comments on commit 834d167

Please sign in to comment.