-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding SCADA EtherNet/IP and CIP protocol support #2305
Conversation
1. The enip-feature-1495-v13 branch contains support for the ENIP/CIP Industrial protocol 2. This is an app layer implementation which uses the "enip" protocol and "cip_service" and "enip_command" keywords 3. Rebased master to clean out commits done on master and then merged to latest code 4. Addresses failed PR's OISF#1810 and OISF#1819 and OISF#1827 and OISF#2009 and OISF#2011 and OISF#2012 and OISF#2019 and OISF#2030 and OISF#2068 and OISF#2107 5. As requested, added AFL entry points
@@ -271,6 +271,7 @@ typedef enum { | |||
SC_ERR_THRESHOLD_SETUP, | |||
SC_ERR_DNS_CONFIG, | |||
SC_ERR_MODBUS_CONFIG, | |||
SC_ERR_ENIP_CONFIG, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New additions should be at the end to keep id's stable
* @return 1 Packet ok | ||
* @return 0 Packet has errors | ||
*/ | ||
int DecodeENIP(Packet *p, ENIPData *enip_data) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see where this is called from.
SCEnter(); | ||
sigmatch_table[DETECT_CIPSERVICE].name = "cip_service"; //rule keyword | ||
sigmatch_table[DETECT_CIPSERVICE].desc = "Rules for detecting CIP Service "; | ||
sigmatch_table[DETECT_CIPSERVICE].url = "www.solananetworks.com"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've removed these url references. They should point to documentation links in the suricata documentation
sigmatch_table[DETECT_ENIPCOMMAND].url = "www.solananetworks.com"; | ||
sigmatch_table[DETECT_ENIPCOMMAND].Match = NULL; | ||
sigmatch_table[DETECT_ENIPCOMMAND].AppLayerMatch = NULL; | ||
sigmatch_table[DETECT_ENIPCOMMAND].alproto = ALPROTO_ENIP; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These generate compiler warnings, as can be seen in the failed travis ci test. Please don't ignore ANY compiler warning.
I've done fixes and cleanups in #2309, please review those and use that branch for future improvements. |
1. The enip-feature-1495-v15 branch contains support for the ENIP/CIP Industrial protocol 2. This is an app layer implementation which uses the "enip" protocol and "cip_service" and "enip_command" keywords 3. Rebased master to clean out commits done on master and then merged to latest code 4. Addresses failed PR's OISF#1810 and OISF#1819 and OISF#1827 and OISF#2009 and OISF#2011 and OISF#2012 and OISF#2019 and OISF#2030 and OISF#2068 and OISF#2107 and OISF#2305 5. As requested, added AFL entry points
1. The enip-feature-1495-v16 branch contains support for the ENIP/CIP Industrial protocol 2. This is an app layer implementation which uses the "enip" protocol and "cip_service" and "enip_command" keywords 3. Rebased master to clean out commits done on master and then merged to latest code 4. Addresses failed PR's OISF#1810 and OISF#1819 and OISF#1827 and OISF#2009 and OISF#2011 and OISF#2012 and OISF#2019 and OISF#2030 and OISF#2068 and OISF#2107 and OISF#2305 and OISF#2311 5. As requested, added AFL entry points
In extra-data mode, suricata does not output xff data without undocumented conditions (including enabling packet output). This behaviour has been fixed to remove the hidden requirements. Fix included removing previous xff data output implementation and adding a new function for outputting xff that is called after outputting each event. IPv6 XFF entries were also being recorded incorrectly as if they were IPv4 and this has been fixed.
In extra-data mode, suricata does not output xff data without undocumented conditions (including enabling packet output). This behaviour has been fixed to remove the hidden requirements. Fix included removing previous xff data output implementation and adding a new function for outputting xff that is called after outputting each event. IPv6 XFF entries were also being recorded incorrectly as if they were IPv4 and this has been fixed.
Industrial protocol
and "cip_service" and "enip_command" keywords
merged to latest code
Enip feature 1495 v3 #1810 and
Enip feature 1495 v4 #1819 and
1. The enip-feature-1495-v4 branch contains support for the ENIP/CIP #1827 and
1. The enip-feature-1495-v6 branch contains support for the ENIP/CIP #2009 and
Enip feature 1495 v7 #2011 and
Adding SCADA EtherNet/IP and CIP protocol support #2012 and
Adding SCADA EtherNet/IP and CIP protocol support #2019 and
Adding SCADA EtherNet/IP and CIP protocol support #2030 and
Adding SCADA EtherNet/IP and CIP protocol support #2068 and
Adding SCADA EtherNet/IP and CIP protocol support #2107