~ubuntu-branches/ubuntu/raring/suricata/raring

« back to all changes in this revision

Viewing changes to src/detect-sid.c

  • Committer: Package Import Robot
  • Author(s): Pierre Chifflier
  • Date: 2012-12-14 00:02:51 UTC
  • mfrom: (1.1.18)
  • Revision ID: package-import@ubuntu.com-20121214000251-3326bvmr1x6ofsy5
Tags: 1.4-1
* Imported Upstream version 1.4
* Enable Jansson and LuaJIT support, and add libjansson-dev libluajit-5.1-dev
  to build-deps
* Add python to recommends, for the suricatasc script
* Create /var/run/suricata directory when starting daemon

Show diffs side-by-side

added added

removed removed

Lines of Context:
32
32
 
33
33
void DetectSidRegister (void) {
34
34
    sigmatch_table[DETECT_SID].name = "sid";
 
35
    sigmatch_table[DETECT_SID].desc = "set rule id";
 
36
    sigmatch_table[DETECT_SID].url = "https://redmine.openinfosecfoundation.org/projects/suricata/wiki/Meta-settings#Sid-signature-id";
35
37
    sigmatch_table[DETECT_SID].Match = NULL;
36
38
    sigmatch_table[DETECT_SID].Setup = DetectSidSetup;
37
39
    sigmatch_table[DETECT_SID].Free = NULL;
46
48
    /* strip "'s */
47
49
    if (sidstr[0] == '\"' && sidstr[strlen(sidstr)-1] == '\"') {
48
50
        str = SCStrdup(sidstr+1);
49
 
        if (str == NULL)
 
51
        if (unlikely(str == NULL))
50
52
            return -1;
51
53
 
52
54
        str[strlen(sidstr)-2] = '\0';