SamFetch icon indicating copy to clipboard operation
SamFetch copied to clipboard

[Bug] `/api/binary` endpoint returns the same response body regardless of request params

Open grwthomps opened this issue 4 years ago • 6 comments

Not sure if I'm missing something but it seems like the /api/binary endpoint returns the same response body regardless of the params sent with the request.

Request: /api/binary?region=XAA&model=SM-G986U1&firmware=G986U1UEU1DUB7%2FG986U1OYM1DUB7%2FG986U1UEU1DUB7%2FG986U1UEU1DUB7

Response:

{
  "display_name": "SSP",
  "size": 5991219840,
  "filename": "SM-G986U1_1_20210416234737_q8wahqy67m_fac.zip.enc4",
  "path": "/neofus/910/",
  "version": "R (Android 11)",
  "encrypt_version": 4,
  "size_readable": "5.58 GB",
  "decrypt_key": "60813b9c940b3e286de84bff7baaf403"
}

The 20210416 date of the firmware is what tipped me off because I'm trying to download a firmware from 2-28. So I also tried a couple of other firmwares (all pulled from the /api/list endpoint) and they all returned the same response as above. I'm guessing it's just returning info for the latest firmware every time but I'm not sure.

grwthomps avatar May 10 '21 19:05 grwthomps

I just tried to display raw data from Kies's servers, and looks like it got the device firmware code correctly as expected.

image

And when I look at the https://doc.samsungmobile.com/SM-G986U1/XAA/doc.html I can clearly see the release date.

image

But I don't know the exact reason why it returns that response to you.

I will research more about this problem and let you know if it is related to Kies / Samsung's servers itself or SamFetch.

ysfchn avatar May 10 '21 21:05 ysfchn

Hmm that is strange. I just tried again with some different firmwares and got the same response. I even tried using Postman to send the request since I was using the openapi web interface before but that didn't change anything. Let me know if there's anything I need to try or test. Thanks for your help!

grwthomps avatar May 10 '21 21:05 grwthomps

Probably this is the reason:

https://github.com/zacharee/SamloaderKotlin/issues/10#issuecomment-827292128

ysfchn avatar May 11 '21 14:05 ysfchn

Yes, I think you're right. I just tested another tool on Windows 10 (SamFirm_Reborn) and it did the same thing so it seems like it's a change on Samsung's end.

grwthomps avatar May 12 '21 21:05 grwthomps

@ysfchn if you find any way around this, let me know.

zacharee avatar May 23 '21 04:05 zacharee

Are you affiliated with the site SamFirm ?

Martyn911 avatar Feb 19 '24 21:02 Martyn911