IPFS Authentication Error 403 - Forbidden

import { create as ipfsHttpClient } from "ipfs-http-client";
.
.
.
const projectId = "....";

const projectSecret = "....";

const auth = 'Basic ' + Buffer.from(projectId + ':' + projectSecret).toString('base64');

console.log(auth)

const ipfs = ipfsHttpClient({

  host: 'ipfs.infura.io',

  port: 5001,

  protocol: 'https',

  apiPath: '/api/v0',

  headers: {

    authorization: auth,

  },

});

I’m still getting 403 error

Hi :slight_smile:

This is the repo : https://github.com/anarkrypto/upload-files-to-ipfs-from-browser-panel

This is the demo: Upload files to IPFS from Browser

1 Like

I use your ipfs service to allow my web app to upload (client side) and then pin (server side by authentication).
The new policy forces me to use the same credentials on the client size app and I can’t allow this.
My proposal is to create two login credentials, one only for the upload the other only for the pin, in this way I can
protect my pinned file archive from unauthorized account use.

Is there any further resolution on this? Even after reversion, I’m still getting 403 error even using correct authentication. Without authentication, as it was before, I was getting a 401 error so I’m assuming my authentication is correct.

Can you please open a ticket about this, we’ll need to look closer into it. Thanks !

I think I did here: 403 Error using IPFS gateway

But I’m just repeating a ticket that already appears to be open in this chain. Lots of developers seem to be having the same problem and the posts above support this - “I’m still getting 403 error”. Can you please resolve or provide some clarity on the issue, or suggest alternative to Infura?

i tried, but always same issue
basic auth failure: invalid project id or project secret

tried with postman, but never solved.
very disappointed with ipfs with infura

i tried, but always same issue.
basic auth failure: invalid project id or project secret
image

tried with postman, but never solved.
very disappointed with ipfs with infura

How are you defining the projectID and secret in your code ?

i m very disappointed as i tried for 3 days to solve it.

but could not fix it.

i followed the code in the infura docs.

never helped

image

I’m not seeing that key as a valid projectID on our end, did you create it from the infura dashboard Ethereum API | IPFS API & Gateway | ETH Nodes as a Service | Infura - create new key - network = ipfs ?

That’s an Ethereum key, it doesn’t work for IPFS, you need to create a separate one as suggested.

how can i make api key for the ipfs?

yes, exactly like that

Hi, I am not sure if that is relevant to this topic, but I found that I can’t access the link due to the SSL cert in Chrome and firefox. I am using the DEDICATED GATEWAYS

I can only access the link in Safari. It is infinite loading in all the other browsers ERR_CONNECTION_TIMED_OUT

https://next-nft-polygon-testing.infura-ipfs.io/ipfs/QmQMBzHfadX4AVCnvjVXHV8zJHGb8i1zn5EoBUopeqjfhK

I can’t access the demo link on the ipfs page too
https://meme-nft.infura-ipfs.io/ipfs/QmW5sPVbZDueZwvSuibteAwDFwFXhF8gebfptGBx1DZq1j

I just found the issue. I don’t know why my ISP (Sky in the UK) got some unknown problems with those ipfs links(Maybe it is related to SSL?). Once I use my own mobile phone bandwidth, I am able to see the data.

I implemented everything using my dedicated gateway subdomain, but I still cannot make requests. Does anyone know if there is a solution to this issue here? Looking at the above I don’t really see anything that works

doesn’t work with dedicated gateway (I always get an ERR_SSL_PROTOCOL_ERROR, see here):
https://nftschool.infura-ipfs.io/ipfs/QmZdS6ZDYhfmXMJVH6e9MDQyfuL7iifnrNVXJjKZ2vAWWp

but works on IPFS: