Optimization #7762
closedrust: finish moving extern C definitions to suricata_sys and bindgen
PA Updated by Philippe Antoine over 1 year ago
- Copied from Bug #7667: rust: move extern C definitions to suricata_sys and bindgen added
PA Updated by Philippe Antoine over 1 year ago
applayer.rs and frames.rs share the same problem : we want to bindgen a C function like `AppLayerFrameNewByRelativeOffset` which uses as argument of type `StreamSlice` which is defined in rust
This is going to be the difficult part.
There are some easier things to do first
PA Updated by Philippe Antoine over 1 year ago
- Blocks Feature #7666: rust: zero-dependency crate suricata-ffi added
PA Updated by Philippe Antoine about 1 year ago
- Tracker changed from Bug to Optimization
PA Updated by Philippe Antoine about 1 year ago
- Related to Optimization #4517: cbindgen export the constants from Rust to C, also for macro such as BIT_U8(1), and remove duplicate definitions between rust and C added
PA Updated by Philippe Antoine 12 months ago
Goal : makegit grep 'extern "C" {' rust/src/
return nothing
PA Updated by Philippe Antoine 10 months ago
AppLayerRegisterParser difficulty is that AppLayerParserFPtr uses StreamSlice as an argument and it is defined in rust...
PA Updated by Philippe Antoine 10 months ago ยท Edited
Philippe Antoine wrote in #note-7:
AppLayerRegisterParser difficulty is that AppLayerParserFPtr uses StreamSlice as an argument and it is defined in rust...
Solutions :
- move StreamSlice definition to C
- Have function prototype use a void*, then cast
- AppLayerEventType
- AppLayerGetFileState
- AppLayerGetTxIterTuple
- AppLayerTxData
- AppLayerTxConfig
- AppLayerStateData
@Jason Ish, what do you think about moving definitions to C ?
PA Updated by Philippe Antoine 9 months ago
- Status changed from In Progress to In Review
PA Updated by Philippe Antoine 9 months ago
- Copied to Optimization #8187: rust: move extern C definition to suricata-lua-sys and bindgen added
PA Updated by Philippe Antoine 8 months ago
- Blocks Optimization #4747: app-layer: make tx iterator a mandatory part of the API added
PA Updated by Philippe Antoine 8 months ago
- Status changed from In Review to Closed
https://github.com/OISF/suricata/pull/14667 was the final PR !