firefox - curl command to upload file to form -
i'm trying build curl command upload xpi validation @ mozilla add-on validator.
i've captured traffic fiddler see site doing , try mimic it's behavior curl.
i've seen whats post url, , tried curl https://addons.mozilla.org/en-us/developers/standalone-upload --form 'upload=@path-to-xpi.xpi'
, csrfmiddlewaretoken=@path-to-xpi.xpi
. , tried adding content-type
.
this raw data first request:
post https://addons.mozilla.org/en-us/developers/standalone-upload http/1.1 host: addons.mozilla.org connection: keep-alive content-length: 41021 origin: https://addons.mozilla.org user-agent: mozilla/5.0 (windows nt 6.1; wow64) applewebkit/537.36 (khtml, gecko) chrome/47.0.2526.111 safari/537.36 content-type: multipart/form-data; boundary=----webkitformboundaryi0lecjkejnsfgipu accept: */* referer: https://addons.mozilla.org/en-us/developers/addon/validate accept-encoding: gzip, deflate accept-language: en-us,en;q=0.8,he;q=0.6 cookie: _ga=ga1.2.710702590.1450107779; sessionid=".ejyrvkoulkqll8npts1tsllkznaotyzi8czotezxcte0sczkichonjmo8puo9q5wcvfsuypplc3jic8tti2kz0xrsji0mrcwnde3qzfiskwgmgeuvqjxi_wg_gi9x9z8ukcie1qeqkk4tbg4mz8vprwiilooemyepzmbqs0aqsk0ia:1alyvj:cbzqtnckfrasddftjki9b_wb6ga"
------webkitformboundaryi0lecjkejnsfgipu content-disposition: form-data; name="csrfmiddlewaretoken"
khcuaxlikiadlw18arlxkc63pmkukpdg ------webkitformboundaryi0lecjkejnsfgipu content-disposition: form-data; name="upload"; filename="extension.xpi" content-type: application/octet-stream
currently i'm receiving html page not allowed.
what missing? else should add request receive response?
thanks
Comments
Post a Comment