All pastes #564360 Raw Edit

Miscellany

public text v1 · immutable
·published 2007-06-13 15:46 UTC
rendered paste body
#!/usr/bin/env python

# $Id$

import base64, time
import dsniff

class SVNSnarf(dsniff.Handler):
    def setup(self):
        self.subscribe('service', 'dns', self.recv_flow)

    def recv_flow(self, f):
        if f.state == dsniff.FLOW_START:
            print 'dns started'
        elif f.state == dsniff.FLOW_CLIENT_DATA:
            print 'dns data received'

if __name__ == '__main__':
    dsniff.main()