firebase-js-sdk icon indicating copy to clipboard operation
firebase-js-sdk copied to clipboard

HEAD requests return 400

Open marawannwh opened this issue 5 years ago • 8 comments

This is our storage rules

service firebase.storage {
  match /b/{bucket}/o {
    match /{allPaths=**} {
    	allow read;
      allow write: if request.auth != null;
    }
  }
}

GET works, but for some reason, HEAD doesn't.

marawannwh avatar Feb 12 '20 19:02 marawannwh

I found a few problems with this issue:

  • I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.
  • This issue does not seem to follow the issue template. Make sure you provide all the required information.

google-oss-bot avatar Feb 12 '20 19:02 google-oss-bot

Hi @mrwnmonm, I tried making a HEAD request using fetch and got 400 error, yet indeed GET works as expected (quickstart). Is it the same use case you're trying on? If it's not, you may share a repro code and detailed steps so I can debug it on my end and ask necessary assistance from the right person. Thanks!

rommelpe avatar Feb 13 '20 14:02 rommelpe

I guess it is the same.

marawannwh avatar Feb 13 '20 21:02 marawannwh

Adding GCS docs stating that the HEAD request should be supported.

@mrwnmonm thanks, the issue label was added to get attention from Storage folks.

rommelpe avatar Feb 17 '20 10:02 rommelpe

Got feedback from the team that this feature isn't yet available on our SDK. We have an existing internal FR (b/27876138) for it though I can't share any timelines or specifics at the moment.

We'll treat this as a feature request as well and keep it open. Thanks for bringing this up, @mrwnmonm!

rommelpe avatar Feb 19 '20 09:02 rommelpe

any update on this?

itsmitchyyy avatar Nov 11 '21 05:11 itsmitchyyy

This is still valid. What's the status on this?

bompi88 avatar Sep 09 '22 19:09 bompi88

Also checking in. I am dealing with a customer who wishes to do a HEAD request as a preflight-style check of the content size of a firebase storage asset before fully downloading it.

ianmpeerly avatar Sep 16 '22 17:09 ianmpeerly