Permalink
Switch branches/tags
Nothing to show
Commits on Nov 15, 2017
  1. Update for hex.pm

    msantos committed Nov 15, 2017
Commits on Aug 30, 2017
  1. Bump version to 1.0.0

    msantos committed Aug 30, 2017
Commits on Aug 29, 2017
  1. tests: fix large filter test

    msantos committed Aug 29, 2017
Commits on Aug 24, 2017
  1. tests: large filters

    msantos committed Aug 24, 2017
Commits on Aug 23, 2017
  1. compile/2: add limit option

    msantos committed Aug 23, 2017
    By default, limit filter length to an arbitrary value of 8192 bytes.
    
    Using very large filters with pcap 1.7.4 can result in a segmentation
    fault:
    
        epcap_compile:compile(string:copies("ip and ", 50000) ++ "ip").
    
    The most likely cause is a stack overflow. pcap_compile() in pcap 1.8.1
    is thread-safe. Presumably this means memory is allocated on the heap so
    as a consequence, the stack overflow may be fixed. I haven't debugged
    this further yet.
    
    The limit can be disabled by using a value of -1 as the limit option.
    
    Some notes:
    
        % {ok, _}
        epcap_compile:compile(string:copies("ip or ", 50000) ++ "ip").
    
        % segfault
        epcap_compile:compile(string:copies("ip or ", 60000) ++ "ip").
    
        % {error, "out of memory"}
        epcap_compile:compile(string:copies("tcp and ", 50000) ++ "ip").
    
        # shell
        ulimit -s
        8192
    
        (seq 1 50000 | while read l; do printf "ip and "; done; echo "ip") > filter
    
        # works
        sudo tcpdump -d -F filter
    
        ulimit -s 1024
        sudo tcpdump -d -F filter
        Segmentation fault (core dumped)
Commits on Aug 13, 2017
  1. unload/load: add error checking

    msantos committed Aug 13, 2017
Commits on Aug 1, 2017
  1. Add a lock around pcap_compile(3PCAP)

    msantos committed Aug 1, 2017
    Versions of pcap_compile before 1.8.1 are not thread-safe:
    
        the-tcpdump-group/libpcap#569
Commits on Dec 13, 2016
  1. makefile: add target for elvis

    msantos committed Dec 13, 2016
Commits on Nov 23, 2016
  1. makefile: add target for typer

    msantos committed Nov 23, 2016
Commits on Nov 22, 2016
Commits on Nov 4, 2016
Commits on Nov 3, 2016
  1. Add elvis style conventions

    msantos committed Nov 3, 2016
Commits on Oct 15, 2016
  1. Add dialyzer warnings

    msantos committed Oct 15, 2016
Commits on Oct 7, 2016
  1. Suppress compiler warning

    msantos committed Oct 7, 2016
Commits on Aug 13, 2016
  1. Update gitignore for rebar3

    msantos committed Aug 13, 2016
Commits on Jul 30, 2016
  1. Switch to rebar3

    msantos committed Jul 30, 2016
Commits on Mar 13, 2016
  1. Use common test

    msantos committed Mar 13, 2016
Commits on Feb 12, 2016
  1. spec: tuple accepted as netmask

    msantos committed Feb 12, 2016
Commits on Mar 25, 2015
Commits on Jan 9, 2015
  1. Clean up gitignore

    msantos committed Jan 9, 2015
Commits on Jan 8, 2015
  1. Update gitignore

    msantos committed Jan 8, 2015
Commits on Jan 6, 2015
  1. Copyright heartbeat

    msantos committed Jan 6, 2015
  2. Compile on Solaris

    msantos committed Jan 6, 2015
Commits on Aug 10, 2014
  1. Bump version

    msantos committed Aug 10, 2014
Commits on Aug 9, 2014
  1. Add typespecs

    msantos committed Aug 9, 2014
  2. Copyright heartbeat

    msantos committed Aug 9, 2014
Commits on Sep 19, 2013
  1. Remove trailing whitespace

    msantos committed Sep 19, 2013
Commits on Apr 19, 2013
  1. Copyright heartbeat

    msantos committed Apr 19, 2013
  2. Update rebar URL

    msantos committed Apr 19, 2013
Commits on Aug 5, 2012
  1. Clean up examples, README

    msantos committed Aug 5, 2012
Commits on Jun 29, 2012
  1. Add a BSD example

    msantos committed Jun 29, 2012
    And some other minor formatting.
Commits on May 3, 2012
  1. Add an example of filtering an inet socket

    msantos committed May 3, 2012
    Filter responses to a TCP socket on Linux. Bizarrely, when the
    connection is sniffed, the GET request is sent 5 times. Each time a
    response is returned but dropped by the filter before it gets to the
    socket.
Commits on May 2, 2012
  1. Add a simple test

    msantos committed May 2, 2012
  2. Correct lib path for OTP app

    msantos committed May 2, 2012