Suricata 1.2.1 #198

Closed
GoogleCodeExporter opened this Issue Mar 24, 2015 · 14 comments

Comments

Projects
None yet
1 participant
@GoogleCodeExporter
http://www.openinfosecfoundation.org/index.php/component/content/article/144-sur
icata-12-available

https://redmine.openinfosecfoundation.org/projects/suricata/wiki/Upgrading_Suric
ata_11_to_Suricata_12

Original issue reported on code.google.com by doug.bu...@gmail.com on 19 Jan 2012 at 6:40

@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

# Downloaded and uncompressed:
wget http://www.openinfosecfoundation.org/download/suricata-1.2.tar.gz
tar zxvf suricata-1.2.tar.gz 
cd suricata-1.2

# Compiled and packaged:
./configure --enable-af-packet --disable-gccmarch-native
make
checkinstall

Original comment by doug.bu...@gmail.com on 19 Jan 2012 at 8:23

  • Changed state: Started
  • Added labels: ****
  • Removed labels: ****
# Downloaded and uncompressed:
wget http://www.openinfosecfoundation.org/download/suricata-1.2.tar.gz
tar zxvf suricata-1.2.tar.gz 
cd suricata-1.2

# Compiled and packaged:
./configure --enable-af-packet --disable-gccmarch-native
make
checkinstall

Original comment by doug.bu...@gmail.com on 19 Jan 2012 at 8:23

  • Changed state: Started
  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

[deleted comment]
[deleted comment]
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

Created securityonion-suricata-rules_20120119_i386.deb as follows:
cp rules/decoder-events.rules /etc/nsm/rules/
cp rules/http-events.rules /etc/nsm/rules/
cp rules/smtp-events.rules /etc/nsm/rules/
cp rules/stream-events.rules /etc/nsm/rules/
/usr/local/lib/ruby/gems/1.9.1/gems/fpm-0.3.11/bin/fpm -s dir -t deb -n 
securityonion-suricata-rules -v 20120119 /etc/nsm/rules/decoder-events.rules 
/etc/nsm/rules/http-events.rules /etc/nsm/rules/smtp-events.rules 
/etc/nsm/rules/stream-events.rules






Original comment by doug.bu...@gmail.com on 19 Jan 2012 at 8:36

  • Added labels: ****
  • Removed labels: ****
Created securityonion-suricata-rules_20120119_i386.deb as follows:
cp rules/decoder-events.rules /etc/nsm/rules/
cp rules/http-events.rules /etc/nsm/rules/
cp rules/smtp-events.rules /etc/nsm/rules/
cp rules/stream-events.rules /etc/nsm/rules/
/usr/local/lib/ruby/gems/1.9.1/gems/fpm-0.3.11/bin/fpm -s dir -t deb -n 
securityonion-suricata-rules -v 20120119 /etc/nsm/rules/decoder-events.rules 
/etc/nsm/rules/http-events.rules /etc/nsm/rules/smtp-events.rules 
/etc/nsm/rules/stream-events.rules






Original comment by doug.bu...@gmail.com on 19 Jan 2012 at 8:36

  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

# Put new suricata.yaml in place:
mv /etc/suricata/suricata.yaml /etc/suricata/suricata.yaml.1.1
cp suricata.yaml /etc/suricata/
cd /etc/suricata/

# manually updated suricata.yaml as follows:
default-rule-path: /etc/nsm/rules/
rule-files:
 - downloaded.rules
 - local.rules
 # - decoder-events.rules
 # - stream-events.rules

unified2-alert
filename: snort.unified2

# manually compared old and new suricata.yaml for any other changes

# Packaged:
/usr/local/lib/ruby/gems/1.9.1/gems/fpm-0.3.11/bin/fpm -s dir -t deb -n 
securityonion-suricata-config -v 20120119 /etc/suricata/

Original comment by doug.bu...@gmail.com on 19 Jan 2012 at 8:52

  • Added labels: ****
  • Removed labels: ****
# Put new suricata.yaml in place:
mv /etc/suricata/suricata.yaml /etc/suricata/suricata.yaml.1.1
cp suricata.yaml /etc/suricata/
cd /etc/suricata/

# manually updated suricata.yaml as follows:
default-rule-path: /etc/nsm/rules/
rule-files:
 - downloaded.rules
 - local.rules
 # - decoder-events.rules
 # - stream-events.rules

unified2-alert
filename: snort.unified2

# manually compared old and new suricata.yaml for any other changes

# Packaged:
/usr/local/lib/ruby/gems/1.9.1/gems/fpm-0.3.11/bin/fpm -s dir -t deb -n 
securityonion-suricata-config -v 20120119 /etc/suricata/

Original comment by doug.bu...@gmail.com on 19 Jan 2012 at 8:52

  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

Found bug in Suricata 1.2.  Reported to Victor.  He confirmed and fixed.  I 
confirmed the fix.  He's hoping to release Suricata 1.2.1 today.

Original comment by doug.bu...@gmail.com on 20 Jan 2012 at 1:28

  • Added labels: ****
  • Removed labels: ****
Found bug in Suricata 1.2.  Reported to Victor.  He confirmed and fixed.  I 
confirmed the fix.  He's hoping to release Suricata 1.2.1 today.

Original comment by doug.bu...@gmail.com on 20 Jan 2012 at 1:28

  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

# Downloaded and uncompressed:
wget http://www.openinfosecfoundation.org/download/suricata-1.2.1.tar.gz
tar zxvf suricata-1.2.1.tar.gz 
cd suricata-1.2.1

# Compiled and packaged:
./configure --enable-af-packet --disable-gccmarch-native
make
checkinstall

Original comment by doug.bu...@gmail.com on 20 Jan 2012 at 6:29

  • Added labels: ****
  • Removed labels: ****
# Downloaded and uncompressed:
wget http://www.openinfosecfoundation.org/download/suricata-1.2.1.tar.gz
tar zxvf suricata-1.2.1.tar.gz 
cd suricata-1.2.1

# Compiled and packaged:
./configure --enable-af-packet --disable-gccmarch-native
make
checkinstall

Original comment by doug.bu...@gmail.com on 20 Jan 2012 at 6:29

  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

pulledpork.conf.master needs:
local_rules=/etc/nsm/rules/local.rules,/etc/nsm/rules/decoder-events.rules,/etc/
nsm/rules/stream-events.rules,/etc/nsm/rules/http-events.rules,/etc/nsm/rules/sm
tp-events.rules

Re-package.

security-onion-upgrade.sh needs to:
sed -i 
's|local_rules=/etc/nsm/rules/local.rules,/etc/nsm/rules/decoder-events.rules,/e
tc/nsm/rules/stream-events.rules|local_rules=/etc/nsm/rules/local.rules,/etc/nsm
/rules/decoder-events.rules,/etc/nsm/rules/stream-events.rules,/etc/nsm/rules/ht
tp-events.rules,/etc/nsm/rules/smtp-events.rules|g' 
/etc/pulledpork/pulledpork.conf

Original comment by doug.bu...@gmail.com on 20 Jan 2012 at 8:46

  • Added labels: ****
  • Removed labels: ****
pulledpork.conf.master needs:
local_rules=/etc/nsm/rules/local.rules,/etc/nsm/rules/decoder-events.rules,/etc/
nsm/rules/stream-events.rules,/etc/nsm/rules/http-events.rules,/etc/nsm/rules/sm
tp-events.rules

Re-package.

security-onion-upgrade.sh needs to:
sed -i 
's|local_rules=/etc/nsm/rules/local.rules,/etc/nsm/rules/decoder-events.rules,/e
tc/nsm/rules/stream-events.rules|local_rules=/etc/nsm/rules/local.rules,/etc/nsm
/rules/decoder-events.rules,/etc/nsm/rules/stream-events.rules,/etc/nsm/rules/ht
tp-events.rules,/etc/nsm/rules/smtp-events.rules|g' 
/etc/pulledpork/pulledpork.conf

Original comment by doug.bu...@gmail.com on 20 Jan 2012 at 8:46

  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

[deleted comment]
[deleted comment]
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

Added http-events.rules and smtp-events.rules to suricata.yaml but left them 
commented out.  Re-packaged:
/usr/local/lib/ruby/gems/1.9.1/gems/fpm-0.3.11/bin/fpm -s dir -t deb -n 
securityonion-suricata-config -v 20120119 /etc/suricata/

Original comment by doug.bu...@gmail.com on 20 Jan 2012 at 10:06

  • Added labels: ****
  • Removed labels: ****
Added http-events.rules and smtp-events.rules to suricata.yaml but left them 
commented out.  Re-packaged:
/usr/local/lib/ruby/gems/1.9.1/gems/fpm-0.3.11/bin/fpm -s dir -t deb -n 
securityonion-suricata-config -v 20120119 /etc/suricata/

Original comment by doug.bu...@gmail.com on 20 Jan 2012 at 10:06

  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

[deleted comment]
[deleted comment]
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

Updated /etc/suricata/suricata.yaml and enabled threshold.conf, but it looks 
like the full path must be used.  Added the following to /usr/local/bin/setup:
sed -i "s|threshold-file: threshold.conf|threshold-file: 
/etc/nsm/$SENSORNAME/threshold.conf|g" /etc/nsm/"$SENSORNAME"/suricata.yaml

Packaged:
/usr/local/lib/ruby/gems/1.9.1/gems/fpm-0.3.11/bin/fpm -s dir -t deb -n 
securityonion-setup -v 20120119 /usr/local/bin/setup

Original comment by doug.bu...@gmail.com on 22 Jan 2012 at 3:48

  • Added labels: ****
  • Removed labels: ****
Updated /etc/suricata/suricata.yaml and enabled threshold.conf, but it looks 
like the full path must be used.  Added the following to /usr/local/bin/setup:
sed -i "s|threshold-file: threshold.conf|threshold-file: 
/etc/nsm/$SENSORNAME/threshold.conf|g" /etc/nsm/"$SENSORNAME"/suricata.yaml

Packaged:
/usr/local/lib/ruby/gems/1.9.1/gems/fpm-0.3.11/bin/fpm -s dir -t deb -n 
securityonion-setup -v 20120119 /usr/local/bin/setup

Original comment by doug.bu...@gmail.com on 22 Jan 2012 at 3:48

  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

Original comment by doug.bu...@gmail.com on 22 Jan 2012 at 5:23

  • Changed title: Suricata 1.2.1
  • Added labels: ****
  • Removed labels: ****

Original comment by doug.bu...@gmail.com on 22 Jan 2012 at 5:23

  • Changed title: Suricata 1.2.1
  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

Added the following to security-onion-upgrade.sh:


sed -i 's| |=|g' $CONF
source $CONF
if [ "$VERSION" = "20120116" ]; then
        NEW="20120119"
        echo "**********************************************"   | $LOGGER
        echo "* Upgrading from $VERSION to $NEW."               | $LOGGER
        echo "**********************************************"   | $LOGGER
        DIR="/nsm/backup/$NEW"
        mkdir -p $DIR                                           | $LOGGER
        cd $DIR

    echo "* Disabling Snorby DB fix cronjob due to performance issues with large/busy DBs" | $LOG
GER
    FILE=securityonion-snorby-db-fix_"$NEW"_i386.deb
    wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
    dpkg -i $FILE                       | $LOGGER

    echo "* Installing new Setup script"            | $LOGGER
    FILE=securityonion-setup_"$NEW"_i386.deb
    wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
    dpkg -i $FILE                       | $LOGGER

    echo "* Installing new Suricata"                        | $LOGGER
        FILE=securityonion-suricata_"$NEW"-1_i386.deb
        wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
        dpkg -i $FILE                                           | $LOGGER

        echo "* Installing new Suricata config"                 | $LOGGER
        FILE=securityonion-suricata-config_"$NEW"_i386.deb
        wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
        dpkg -i $FILE                                           | $LOGGER

        echo "* Installing new Suricata-specific rules"         | $LOGGER
        FILE=securityonion-suricata-rules_"$NEW"_i386.deb
        wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
        dpkg -i $FILE                                           | $LOGGER

    apt-get -y remove securityonion-pulledpork-update
        echo "* Installing new PulledPork config"            | $LOGGER
        FILE=securityonion-pulledpork_"$NEW"_i386.deb
        wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
        dpkg -i $FILE                                           | $LOGGER

    cp /etc/crontab .
    sed -i '/pulledpork_update.sh/d' /etc/crontab
    service cron restart                    | $LOGGER

        echo "* Copying suricata.yaml to sensor directories"    | $LOGGER
        grep -v "^#" /etc/nsm/sensortab |awk '{print $1}' |while read SENSOR
        do
                mkdir -p $DIR/"$SENSOR"/
                cp /etc/nsm/"$SENSOR"/suricata.yaml $DIR/"$SENSOR"/
                cp /etc/suricata/suricata.yaml /etc/nsm/"$SENSOR"/
        sed -i "s|threshold-file: threshold.conf|threshold-file: /etc/nsm/$SENSOR/threshold.c
onf|g" /etc/nsm/"$SENSOR"/suricata.yaml
        done

    FILE=/etc/pulledpork/pulledpork.conf
    if [ -f $FILE ]
    then
        sed -i 's|local_rules=/etc/nsm/rules/local.rules,/etc/nsm/rules/decoder-events.rules,
/etc/nsm/rules/stream-events.rules|local_rules=/etc/nsm/rules/local.rules,/etc/n
sm/rules/decoder-even
ts.rules,/etc/nsm/rules/stream-events.rules,/etc/nsm/rules/http-events.rules,/et
c/nsm/rules/smtp-even
ts.rules|g' $FILE
        sed -i 's|rule_url=http://rules.emergingthreats.net|rule_url=https://rules.emergingth
reatspro.com|g' $FILE
        sed -i 's|distro=FreeBSD-8.0|distro=Ubuntu-10-4|g' $FILE
        /usr/local/bin/pulledpork_update.sh
    fi

        sed -i "s|VERSION=$VERSION|VERSION=$NEW|g" $CONF        | $LOGGER
        echo "* Upgrade to $NEW complete."                      | $LOGGER
        echo 
fi

Original comment by doug.bu...@gmail.com on 22 Jan 2012 at 5:37

  • Added labels: ****
  • Removed labels: ****
Added the following to security-onion-upgrade.sh:


sed -i 's| |=|g' $CONF
source $CONF
if [ "$VERSION" = "20120116" ]; then
        NEW="20120119"
        echo "**********************************************"   | $LOGGER
        echo "* Upgrading from $VERSION to $NEW."               | $LOGGER
        echo "**********************************************"   | $LOGGER
        DIR="/nsm/backup/$NEW"
        mkdir -p $DIR                                           | $LOGGER
        cd $DIR

    echo "* Disabling Snorby DB fix cronjob due to performance issues with large/busy DBs" | $LOG
GER
    FILE=securityonion-snorby-db-fix_"$NEW"_i386.deb
    wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
    dpkg -i $FILE                       | $LOGGER

    echo "* Installing new Setup script"            | $LOGGER
    FILE=securityonion-setup_"$NEW"_i386.deb
    wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
    dpkg -i $FILE                       | $LOGGER

    echo "* Installing new Suricata"                        | $LOGGER
        FILE=securityonion-suricata_"$NEW"-1_i386.deb
        wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
        dpkg -i $FILE                                           | $LOGGER

        echo "* Installing new Suricata config"                 | $LOGGER
        FILE=securityonion-suricata-config_"$NEW"_i386.deb
        wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
        dpkg -i $FILE                                           | $LOGGER

        echo "* Installing new Suricata-specific rules"         | $LOGGER
        FILE=securityonion-suricata-rules_"$NEW"_i386.deb
        wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
        dpkg -i $FILE                                           | $LOGGER

    apt-get -y remove securityonion-pulledpork-update
        echo "* Installing new PulledPork config"            | $LOGGER
        FILE=securityonion-pulledpork_"$NEW"_i386.deb
        wget -q http://sourceforge.net/projects/security-onion/files/$NEW/$FILE -O $FILE | $LOGGER
        dpkg -i $FILE                                           | $LOGGER

    cp /etc/crontab .
    sed -i '/pulledpork_update.sh/d' /etc/crontab
    service cron restart                    | $LOGGER

        echo "* Copying suricata.yaml to sensor directories"    | $LOGGER
        grep -v "^#" /etc/nsm/sensortab |awk '{print $1}' |while read SENSOR
        do
                mkdir -p $DIR/"$SENSOR"/
                cp /etc/nsm/"$SENSOR"/suricata.yaml $DIR/"$SENSOR"/
                cp /etc/suricata/suricata.yaml /etc/nsm/"$SENSOR"/
        sed -i "s|threshold-file: threshold.conf|threshold-file: /etc/nsm/$SENSOR/threshold.c
onf|g" /etc/nsm/"$SENSOR"/suricata.yaml
        done

    FILE=/etc/pulledpork/pulledpork.conf
    if [ -f $FILE ]
    then
        sed -i 's|local_rules=/etc/nsm/rules/local.rules,/etc/nsm/rules/decoder-events.rules,
/etc/nsm/rules/stream-events.rules|local_rules=/etc/nsm/rules/local.rules,/etc/n
sm/rules/decoder-even
ts.rules,/etc/nsm/rules/stream-events.rules,/etc/nsm/rules/http-events.rules,/et
c/nsm/rules/smtp-even
ts.rules|g' $FILE
        sed -i 's|rule_url=http://rules.emergingthreats.net|rule_url=https://rules.emergingth
reatspro.com|g' $FILE
        sed -i 's|distro=FreeBSD-8.0|distro=Ubuntu-10-4|g' $FILE
        /usr/local/bin/pulledpork_update.sh
    fi

        sed -i "s|VERSION=$VERSION|VERSION=$NEW|g" $CONF        | $LOGGER
        echo "* Upgrade to $NEW complete."                      | $LOGGER
        echo 
fi

Original comment by doug.bu...@gmail.com on 22 Jan 2012 at 5:37

  • Added labels: ****
  • Removed labels: ****
@GoogleCodeExporter

This comment has been minimized.

Show comment
Hide comment
@GoogleCodeExporter

GoogleCodeExporter Mar 24, 2015

Published:
http://securityonion.blogspot.com/2012/01/security-onion-20120119-now-available.
html

Original comment by doug.bu...@gmail.com on 22 Jan 2012 at 5:38

  • Changed state: Verified
  • Added labels: ****
  • Removed labels: ****
Published:
http://securityonion.blogspot.com/2012/01/security-onion-20120119-now-available.
html

Original comment by doug.bu...@gmail.com on 22 Jan 2012 at 5:38

  • Changed state: Verified
  • Added labels: ****
  • Removed labels: ****
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment