rust-payjoin icon indicating copy to clipboard operation
rust-payjoin copied to clipboard

Consider dropping `MAX_CONTENT_LENGTH` checks

Open spacebear21 opened this issue 5 months ago • 2 comments

since body is already allocated, and presumably does not exceed the app's limits by the time this code is run, maybe it's better to just remove MAX_CONTENT_LENGTH altogether?

Originally posted by @nothingmuch in https://github.com/payjoin/rust-payjoin/pull/745#discussion_r2135585926

spacebear21 avatar Jun 09 '25 23:06 spacebear21

also this https://github.com/payjoin/rust-payjoin/pull/745#discussion_r2136628205

nothingmuch avatar Jun 10 '25 11:06 nothingmuch

remaining TODOs per @nothingmuch :

  1. (DONE) making the receiver's request body handling stricter
  2. the same change to the sender
  3. enforcing limits on payjoin-cli receiver, which currently uses body.collect()
  4. same thing for payjoin-cli sender, which uses &response.bytes() (from reqwest)

spacebear21 avatar Jun 24 '25 16:06 spacebear21