View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0004250 | unreal | module api | public | 2013-12-15 08:04 | 2015-05-23 17:49 |
Reporter | s0beit | Assigned To | syzop | ||
Priority | normal | Severity | tweak | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | 3.2.10.2 | ||||
Fixed in Version | 3.4-alpha3 | ||||
Summary | 0004250: HOOKTYPE_RAWPACKET_IN parameters inconsistent with HOOKTYPE_PACKET | ||||
Description | Unlike HOOKTYPE_PACKET, I am unable to modify the length of the buffer passed through HOOKTYPE_RAWPACKET_IN. This is because HOOKTYPE_PACKET passes int*, while HOOKTYPE_RAWPACKET_IN passes int (non-pointer value), this means you are unable to modify the length of a buffer if it changes going in the opposite direction. | ||||
Additional Information | It is perhaps possible to return 0 (so that the function stops executing) and emulate the rest of read_packet within the callback, this is a hacky workaround but it can be done in a pinch I suppose. | ||||
Tags | No tags attached. | ||||
3rd party modules | |||||
|
I'm pretty sure this was intentional because changing the length (at that point) can potentially cause issues. |
|
For a module I'm making it is required that I modify the data in and out (and it must be the raw packet) Not sure what issues you're talking about specifically. |
|
Changed in 3.4-alpha3: https://github.com/unrealircd/unrealircd/commit/c66d21374821e6990c42490cc9ce479fe3573bdf Module coders: HOOKTYPE_RAWPACKET_IN: third argument is now int * rather than int so you can change the length (and readbuf is of 8K size, so should be plenty). Requested by s0beit in 0004250. |
Date Modified | Username | Field | Change |
---|---|---|---|
2013-12-15 08:04 | s0beit | New Issue | |
2014-01-12 10:25 | syzop | Priority | high => normal |
2014-01-12 10:26 | syzop | Note Added: 0017872 | |
2014-01-13 11:58 | s0beit | Note Added: 0017891 | |
2014-03-14 01:14 | peterkingalexander | Issue cloned: 0004261 | |
2015-05-23 17:49 | syzop | Note Added: 0018332 | |
2015-05-23 17:49 | syzop | Status | new => resolved |
2015-05-23 17:49 | syzop | Fixed in Version | => 3.4-alpha3 |
2015-05-23 17:49 | syzop | Resolution | open => fixed |
2015-05-23 17:49 | syzop | Assigned To | => syzop |
2017-01-06 15:48 | syzop | Category | module => module api |