title: python error socket.error: [Errno 10013] Une tentative dÆaccÞs Ó un socket de maniÞre interd te par ses autorisations dÆaccÞs a ÚtÚ tentÚe
body: <p>i've make a sniff script but i've problem with socket i get like this <code>socket.error</code></p>
  
  <p>my code like this</p>
  
  <pre><code>import socket
  import os
  # host to listen on
  host = "192.168.1.1"
  # create a raw socket and bind it to the public interface
  if os.name == "nt":
      socket_protocol = socket.IPPROTO_IP
  else:
      socket_protocol = socket.IPPROTO_ICMP
  sniffer = socket.socket(socket.AF_INET, socket.SOCK_RAW, socket_protocol)
  
  sniffer.bind((host, 0))
  # we want the IP headers included in the capture
  sniffer.setsockopt(socket.IPPROTO_IP, socket.IP_HDRINCL, 1)
  # if we're using Windows, we need to send an IOCTL
  # to set up promiscuous mode
  if os.name == "nt":
      sniffer.ioctl(socket.SIO_RCVALL, socket.RCVALL_ON)
  # read in a single packet
  print sniffer.recvfrom(65565)
  # if we're using Windows, turn off promiscuous mode
  if os.name == "nt":
      sniffer.ioctl(socket.SIO_RCVALL, socket.RCVALL_OFF) 
  </code></pre>
  
  <p>and error </p>
  
  <p>e par ses autorisations dÆaccÞs a ÚtÚ tentÚe</p>
  
  <pre><code>c:\Users\noredine\Desktop\project0112deep&gt;sniff.py
  raceback (most recent call last):
   File "C:\Users\noredine\Desktop\backdoor\sniff.py", line 10, in &lt;module&gt;
     sniffer = socket.socket(socket.AF_INET, socket.SOCK_RAW, socket_protocol)
   File "C:\Python27\lib\socket.py", line 191, in __init__
     _sock = _realsocket(family, type, proto)
  ocket.error: [Errno 10013] Une tentative dÆaccÞs Ó un socket de maniÞre interdi
  e par ses autorisations dÆaccÞs a ÚtÚ tentÚe
  </code></pre>