pwntools icon indicating copy to clipboard operation
pwntools copied to clipboard

port recv to windows

Open gogo2464 opened this issue 2 years ago • 2 comments

Pwntools Pull Request

Currently pwntools works only on linux. This PR is a start to work with windows. For the moment it has only been tested with the command recv().

Testing

I am going to add tests for windows.

Target Branch

dev

Changelog

fix https://github.com/Gallopsled/pwntools/issues/1930

gogo2464 avatar Nov 19 '21 17:11 gogo2464

This also could be a better implementation than the current Buffer usage. I think the buffer is useless in this class. Could we remove it? It may be easier to maintain. See : https://github.com/Gallopsled/pwntools/blob/dev/pwnlib/tubes/process.py#L664

gogo2464 avatar Nov 20 '21 16:11 gogo2464

I had to reimplement the timeout with the class Thread because the timeout of pwntools does not work on windows.

gogo2464 avatar Nov 27 '21 22:11 gogo2464

See https://github.com/Gallopsled/pwntools/pull/2003#issuecomment-1366980849 etc.

One more thing to keep in mind: don't use a pattern 'X does not work when Y'. Try to dig deeper down the rabbit hole and find out WHY it does not work, or state what research you have done, so that others can see that you put in some actual effort and you are not pretending to do much useful work.

Arusekk avatar Dec 28 '22 23:12 Arusekk