Package core :: Package controllers :: Package extrusionScanning :: Package server :: Module extrusionServer
[hide private]

Module extrusionServer



extrusionServer.py

Copyright 2006 Andres Riancho

This file is part of w3af, w3af.sourceforge.net .

w3af is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation version 2 of the License.

w3af is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with w3af; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA

Classes [hide private]
  extrusionServer
This class defines a simple server that listens on the current interface for connections made from the extrusionClient.
Variables [hide private]
  ARPHDR_ETHER = 1
  ARPHDR_LOOPBACK = 772
  ARPHDR_METRICOM = 23
  ARPHDR_PPP = 512
  ARPHDR_TUN = 65534
  ARPTIMEOUT = 120
  BASE_VERSION = '1.1.1'
  BIG_ENDIAN = True
  BIOCIMMEDIATE = -2147204496
  DARWIN = True
  DEFAULT_CONFIG_FILE = None
  DHCPOptions = {0: 'pad', 1: <Field ().subnet_mask>, 2: 'time_z...
  DHCPRevOptions = {'Finger_server': (73, <Field ().Finger_serve...
  DHCPTypes = {1: 'discover', 2: 'offer', 3: 'request', 4: 'decl...
  DNET = 0
  ETHER_ANY = '\x00\x00\x00\x00\x00\x00'
  ETHER_BROADCAST = '\xff\xff\xff\xff\xff\xff'
  ETHER_TYPES = </etc/ethertypes/ >
  ETH_P_ALL = 3
  ETH_P_ARP = 2054
  ETH_P_IP = 2048
  FREEBSD = True
  GNUPLOT = 0
  HG_NODE = '$Node$'
  IFF_BROADCAST = 2
  IFF_DEBUG = 4
  IFF_LOOPBACK = 8
  IFF_NOARP = 128
  IFF_NOTRAILERS = 32
  IFF_POINTOPOINT = 16
  IFF_PROMISC = 256
  IFF_RUNNING = 64
  IFF_UP = 1
  IP_PROTOS = </etc/protocols/ pim ip ax_25 esp tcp ah ipv6_opts...
  IP_country_kdb = <scapy.IPCountryKnowledgeBase instance at 0x9...
  ISAKMPAttributeTypes = {'Authentication': (3, {'DSS': 2, 'ECDS...
  ISAKMPTransformNum = {1: ('Encryption', {1: 'DES-CBC', 2: 'IDE...
  ISAKMPTransformTypes = {'Authentication': (3, {'DSS': 2, 'ECDS...
  ISAKMP_exchange_type = ['None', 'base', 'identity prot.', 'aut...
  ISAKMP_payload_type = ['None', 'SA', 'Proposal', 'Transform', ...
  ISAKMP_payload_type_overload = {<class 'scapy.ISAKMP_payload_T...
  L3Types = {3: <class 'scapy.IP'>, 2048: <class 'scapy.IP'>, 20...
  LINUX = True
  LLNumTypes = {<class 'scapy.Ether'>: 1, <class 'scapy.CookedLi...
  LLTypes = {1: <function Ether_Dot3_Dispatcher at 0x95e709c>, 1...
  MANUFDB = </usr/share/wireshark/wireshark/manuf/ 00:06:A2 00:2...
  MTU = 1600
  OPENBSD = True
  PACKET_ADD_MEMBERSHIP = 1
  PACKET_DROP_MEMBERSHIP = 2
  PACKET_MR_ALLMULTI = 2
  PACKET_MR_MULTICAST = 0
  PACKET_MR_PROMISC = 1
  PACKET_RECV_OUTPUT = 3
  PACKET_RX_RING = 5
  PACKET_STATISTICS = 6
  PCAP = 0
  PYX = 0
  REVISION = '$Revision$'
  RTF_REJECT = 512
  RTF_UP = 1
  SIOCGIFADDR = 35093
  SIOCGIFCONF = 35090
  SIOCGIFCOUNT = 35128
  SIOCGIFFLAGS = 35091
  SIOCGIFHWADDR = 35111
  SIOCGIFINDEX = 35123
  SIOCGIFNAME = 35088
  SIOCGIFNETMASK = 35099
  SIOCSIFFLAGS = 35092
  SIOCSIFLINK = 35089
  SNMP_error = {0: 'no_error', 1: 'too_big', 2: 'no_such_name', ...
  SNMP_trap_types = {0: 'cold_start', 1: 'warm_start', 2: 'link_...
  SOLARIS = True
  SOL_PACKET = 263
  SOL_SOCKET = 1
  SO_ATTACH_FILTER = 26
  TCPDUMP = 1
  TCPOptions = ({0: ('EOL', None), 1: ('NOP', None), 2: ('MSS', ...
  TCP_SERVICES = </etc/services-tcp/ kpop noclog svn cmip_man z3...
  TFTP_Error_Codes = {0: 'Not defined', 1: 'File not found', 2: ...
  TFTP_operations = {1: 'RRQ', 2: 'WRQ', 3: 'DATA', 4: 'ACK', 5:...
  UDP_SERVICES = </etc/services-udp/ noclog cmip_man z3950 rootd...
  VERSION = 'v1.1.1 / -'
  X86_64 = True
  arp_cache = {}
  capability_list = ['res8', 'res9', 'short-slot', 'res11', 'res...
  conf = Version = v1.1.1 ...
  console_handler = <logging.StreamHandler instance at 0x92dbc4c>
  country_loc_kdb = <scapy.CountryLocKnowledgeBase instance at 0...
  dhcpmagic = 'c\x82Sc'
  dnsclasses = {1: 'IN', 2: 'CS', 3: 'CH', 4: 'HS', 255: 'ANY'}
  dnsqtypes = {0: 'ANY', 1: 'A', 2: 'NS', 3: 'MD', 4: 'MD', 5: '...
  dnstypes = {0: 'ANY', 1: 'A', 2: 'NS', 3: 'MD', 4: 'MD', 5: 'C...
  icmptypes = {0: 'echo-reply', 3: 'dest-unreach', 4: 'source-qu...
  last = None
  log_interactive = <logging.Logger instance at 0x92e1b8c>
  log_loading = <logging.Logger instance at 0x92e1cac>
  log_runtime = <logging.Logger instance at 0x92e138c>
  log_scapy = <logging.Logger instance at 0x92dbc2c>
  nmap_kdb = <scapy.NmapKnowledgeBase instance at 0x95eeccc>
  ntp_basetime = 2208988800
  p0f_kdb = <scapy.p0fKnowledgeBase instance at 0x95eeb8c>
  plst = []
  queso_kdb = <scapy.QuesoKnowledgeBase instance at 0x95eecac>
  re_extract_hexcap = re.compile(r'^(0x[0-9a-fA-F]{2,}[ :\t]|(0x...
  reason_code = {0: 'reserved', 1: 'unspec', 2: 'auth-expired', ...
  skinny_messages = {0: 'KeepAliveMessage', 1: 'RegisterMessage'...
  status_code = {0: 'success', 1: 'failure', 10: 'cannot-support...
  user_commands = [<function sr at 0x95e7ae4>, <function sr1 at ...
Variables Details [hide private]

DHCPOptions

Value:
{0: 'pad',
 1: <Field ().subnet_mask>,
 2: 'time_zone',
 3: <Field ().router>,
 4: <Field ().time_server>,
 5: <Field ().IEN_name_server>,
 6: <Field ().name_server>,
 7: <Field ().log_server>,
...

DHCPRevOptions

Value:
{'Finger_server': (73, <Field ().Finger_server>),
 'IEN_name_server': (5, <Field ().IEN_name_server>),
 'IRC_server': (74, <Field ().IRC_server>),
 'NIS_domain': (40, None),
 'NIS_server': (41, <Field ().NIS_server>),
 'NISplus_domain': (64, None),
 'NISplus_server': (65, <Field ().NISplus_server>),
 'NNTP_server': (71, <Field ().NNTP_server>),
...

DHCPTypes

Value:
{1: 'discover',
 2: 'offer',
 3: 'request',
 4: 'decline',
 5: 'ack',
 6: 'nak',
 7: 'release',
 8: 'inform',
...

IP_PROTOS

Value:
</etc/protocols/ pim ip ax_25 esp tcp ah ipv6_opts xtp ipv6_route igmp\
 igp ddp etherip xns_idp ipv6_frag vrrp gre ipcomp encap ipv6 iso_tp4 \
sctp ipencap rsvp udp ggp hmp idpr_cmtp fc skip st icmp pup isis rdp l\
2tp ipv6_icmp udplite egp ipip ipv6_nonxt eigrp idrp rspf ospf vmtp>

IP_country_kdb

Value:
<scapy.IPCountryKnowledgeBase instance at 0x95eecec>

ISAKMPAttributeTypes

Value:
{'Authentication': (3,
                    {'DSS': 2,
                     'ECDSA Sig': 8,
                     'ElGamal Encryption': 6,
                     'ElGamal Encryption Revised': 7,
                     'HybridInitDSS': 64223,
                     'HybridInitRSA': 64221,
                     'HybridRespDSS': 64224,
...

ISAKMPTransformNum

Value:
{1: ('Encryption',
     {1: 'DES-CBC',
      2: 'IDEA-CBC',
      3: 'Blowfish-CBC',
      4: 'RC5-R16-B64-CBC',
      5: '3DES-CBC',
      6: 'CAST-CBC',
      7: 'AES-CBC',
...

ISAKMPTransformTypes

Value:
{'Authentication': (3,
                    {'DSS': 2,
                     'ECDSA Sig': 8,
                     'ElGamal Encryption': 6,
                     'ElGamal Encryption Revised': 7,
                     'HybridInitDSS': 64223,
                     'HybridInitRSA': 64221,
                     'HybridRespDSS': 64224,
...

ISAKMP_exchange_type

Value:
['None', 'base', 'identity prot.', 'auth only', 'aggressive', 'info']

ISAKMP_payload_type

Value:
['None',
 'SA',
 'Proposal',
 'Transform',
 'KE',
 'ID',
 'CERT',
 'CR',
...

ISAKMP_payload_type_overload

Value:
{<class 'scapy.ISAKMP_payload_Transform'>: {'next_payload': 3},
 <class 'scapy.ISAKMP_payload_Proposal'>: {'next_payload': 2},
 <class 'scapy.ISAKMP_payload_VendorID'>: {'next_payload': 13},
 <class 'scapy.ISAKMP_payload_SA'>: {'next_payload': 1},
 <class 'scapy.ISAKMP_payload_Nonce'>: {'next_payload': 10},
 <class 'scapy.ISAKMP_payload_KE'>: {'next_payload': 4},
 <class 'scapy.ISAKMP_payload_ID'>: {'next_payload': 5},
 <class 'scapy.ISAKMP_payload_Hash'>: {'next_payload': 8}}

L3Types

Value:
{3: <class 'scapy.IP'>,
 2048: <class 'scapy.IP'>,
 2054: <class 'scapy.ARP'>}

LLNumTypes

Value:
{<class 'scapy.Ether'>: 1,
 <class 'scapy.CookedLinux'>: 144,
 <class 'scapy.RadioTap'>: 127,
 <class 'scapy.IP'>: 101,
 <class 'scapy.Dot11'>: 105,
 <class 'scapy.PrismHeader'>: 802,
 <class 'scapy.IrLAPHead'>: 783}

LLTypes

Value:
{1: <function Ether_Dot3_Dispatcher at 0x95e709c>,
 12: <class 'scapy.IP'>,
 23: <function Ether_Dot3_Dispatcher at 0x95e709c>,
 101: <class 'scapy.IP'>,
 105: <class 'scapy.Dot11'>,
 113: <class 'scapy.CookedLinux'>,
 119: <class 'scapy.PrismHeader'>,
 127: <class 'scapy.RadioTap'>,
...

MANUFDB

Value:
</usr/share/wireshark/wireshark/manuf/ 00:06:A2 00:20:A7 00:06:A5 00:2\
0:A6 00:05:46 00:20:A9 00:05:45 00:10:57 00:05:44 00:12:5B 00:10:55 00\
:0C:49 00:0C:48 00:0C:45 00:0C:44 00:0C:47 00:0C:46 00:0C:41 00:0C:40 \
00:0C:43 00:0C:42 00:40:93 00:40:92 00:40:91 00:40:90 00:40:97 00:10:5\
0 00:40:95 00:40:94 00:40:99 00:40:98 47:54:43 00:C0:89 00:C0:88 00:40\
:9C 00:40:9B 00:40:9A 00:C0:8D 00:C0:8C 00:40:9F 00:40:9E 00:40:9D 08:\
00:08 08:00:09 00:0C:4E 00:0C:4D 00:0C:4F 00:0C:4A 00:0C:4C 00:0C:4B 0\
0:05:07 08:00:0D 00:90:DC 02:E6:D3 00:C0:BE 00:09:6E 00:09:6D 00:09:6F\
...

SNMP_error

Value:
{0: 'no_error',
 1: 'too_big',
 2: 'no_such_name',
 3: 'bad_value',
 4: 'read_only',
 5: 'generic_error',
 6: 'no_access',
 7: 'wrong_type',
...

SNMP_trap_types

Value:
{0: 'cold_start',
 1: 'warm_start',
 2: 'link_down',
 3: 'link_up',
 4: 'auth_failure',
 5: 'egp_neigh_loss',
 6: 'enterprise_specific'}

TCPOptions

Value:
({0: ('EOL', None),
  1: ('NOP', None),
  2: ('MSS', '!H'),
  3: ('WScale', '!B'),
  4: ('SAckOK', None),
  5: ('SAck', '!'),
  8: ('Timestamp', '!II'),
  14: ('AltChkSum', '!BH'),
...

TCP_SERVICES

Value:
</etc/services-tcp/ kpop noclog svn cmip_man z3950 rootd ndtp gds_db f\
tps bacula_fd bgpsim isisd mysql bpdbm xdmcp rtcm_sc104 knetd systat m\
mcc enbd_cstatd daap radmin_port hylafax distmp3 hostmon snmp_trap isa\
kmp dict ldap enbd_sstatd kshell tempo imaps pawserv afs3_errors x11_6\
 fax smux spamd krb_prop tproxy auth zebrasrv pop3 pop2 silc x11_5 ssh\
 krbupdate afmbackup saft afbackup zope nntps loc_srv qotd msnp remote\
fs submission afs3_rmtsys prospero afs3_bos sysrqd webmin munin datame\
trics supfiledbg rfe kazaa ospf6d cvspserver venus imap2 imap3 afs3_fi\
...

TFTP_Error_Codes

Value:
{0: 'Not defined',
 1: 'File not found',
 2: 'Access violation',
 3: 'Disk full or allocation exceeded',
 4: 'Illegal TFTP operation',
 5: 'Unknown transfer ID',
 6: 'File already exists',
 7: 'No such user',
...

TFTP_operations

Value:
{1: 'RRQ', 2: 'WRQ', 3: 'DATA', 4: 'ACK', 5: 'ERROR', 6: 'OACK'}

UDP_SERVICES

Value:
</etc/services-udp/ noclog cmip_man z3950 rootd gds_db afs3_rmtsys bac\
ula_fd mysql bpdbm xdmcp rtcm_sc104 x11_5 zephyr_hm daap radmin_port s\
nmp_trap isakmp dict ldap ircs imaps pawserv afs3_errors x11_6 smux po\
p3 pop2 silc ssh afmbackup saft afbackup nntps loc_srv msnp isdnlog su\
bmission mandelspawn prospero afs3_bos sysrqd datametrics rfe kazaa cv\
spserver venus imap2 imap3 afs3_fileserver gnutella_svc domain smsqp l\
2f afs3_vlserver nut proofd rplay sge_execd syslog omirr asp radius ke\
rmit sunrpc zserv ingreslock rsync imsp at_zis icpv2 daytime netwall k\
...

capability_list

Value:
['res8',
 'res9',
 'short-slot',
 'res11',
 'res12',
 'DSSS-OFDM',
 'res14',
 'res15',
...

conf

Value:
Version    = v1.1.1 / -
ASN1_default_codec = <ASN1Codec BER[1]>
AS_resolver = <scapy.AS_resolver_multi instance at 0x95eec6c>
BTsocket   = <class scapy.BluetoothL2CAPSocket at 0x953fc8c>
IPCountry_base = 'GeoIPCountry4Scapy.gz'
L2listen   = <class scapy.L2ListenSocket at 0x953fb3c>
L2socket   = <class scapy.L2Socket at 0x953fadc>
L3socket   = <class scapy.L3PacketSocket at 0x953faac>
...

country_loc_kdb

Value:
<scapy.CountryLocKnowledgeBase instance at 0x95eed0c>

dnsqtypes

Value:
{0: 'ANY',
 1: 'A',
 2: 'NS',
 3: 'MD',
 4: 'MD',
 5: 'CNAME',
 6: 'SOA',
 7: 'MB',
...

dnstypes

Value:
{0: 'ANY',
 1: 'A',
 2: 'NS',
 3: 'MD',
 4: 'MD',
 5: 'CNAME',
 6: 'SOA',
 7: 'MB',
...

icmptypes

Value:
{0: 'echo-reply',
 3: 'dest-unreach',
 4: 'source-quench',
 5: 'redirect',
 8: 'echo-request',
 9: 'router-advertisement',
 10: 'router-solicitation',
 11: 'time-exceeded',
...

re_extract_hexcap

Value:
re.compile(r'^(0x[0-9a-fA-F]{2,}[ :\t]|(0x)?[0-9a-fA-F]{2,}:|(0x)?[0-9\
a-fA-F]{3,}[: \t]|) *(([0-9a-fA-F]{2} {,2}){,16})')

reason_code

Value:
{0: 'reserved',
 1: 'unspec',
 2: 'auth-expired',
 3: 'deauth-ST-leaving',
 4: 'inactivity',
 5: 'AP-full',
 6: 'class2-from-nonauth',
 7: 'class3-from-nonass',
...

skinny_messages

Value:
{0: 'KeepAliveMessage',
 1: 'RegisterMessage',
 2: 'IpPortMessage',
 3: 'KeypadButtonMessage',
 4: 'EnblocCallMessage',
 5: 'StimulusMessage',
 6: 'OffHookMessage',
 7: 'OnHookMessage',
...

status_code

Value:
{0: 'success',
 1: 'failure',
 10: 'cannot-support-all-cap',
 11: 'inexist-asso',
 12: 'asso-denied',
 13: 'algo-unsupported',
 14: 'bad-seq-num',
 15: 'challenge-failure',
...

user_commands

Value:
[<function sr at 0x95e7ae4>,
 <function sr1 at 0x95e7b1c>,
 <function srp at 0x95e7b54>,
 <function srp1 at 0x95e7b8c>,
 <function srloop at 0x95e7c6c>,
 <function srploop at 0x95e7ca4>,
 <function sniff at 0x95e887c>,
 <function p0f at 0x95e848c>,
...