text: import socket
  import sys
  
  # Create a TCP/IP socket
  sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
  
  # Bind the socket to the port
  server_address = '\0foobar'
  print >>sys.stderr, 'starting up on %s' % server_address.decode("utf-8")
  sock.bind(server_address)
  
  # Listen for incoming connections
  sock.listen(1)
  
  while True:
      # Wait for a connection
      print >>sys.stderr, 'waiting for a connection'
      connection, client_address = sock.accept()
  
      try:
          print >>sys.stderr, 'connection from', client_address
  
          # Receive the data in small chunks and retransmit it
          while True:
              data = connection.recv(1024)
              print >>sys.stderr, 'received "%s"' % data
              if data:
                  print >>sys.stderr, 'sending data back to the client'
                  connection.sendall(data)
              else:
                  print >>sys.stderr, 'no more data from', client_address
                  break
              
      finally:
          # Clean up the connection
          connection.close()
  