fredw11 / pyrit

Automatically exported from code.google.com/p/pyrit
1 stars 0 forks source link

Pyrit does not see network cores, does not listen on tcp/19935 #292

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Install Pyrit on OSX 10.6.7 using this howto: 
http://console-cowboys.blogspot.com/2011/01/setting-up-pyrit-on-osx.html
2. Install Pyrit on Ubuntu 10.04 server
3. Configure either machine to be a server, and the other with a ~/.pyrit/hosts 
file pointing at the right IP of the server
4. make certain any firewalls on both machines are off
5. start one machine with 'pyrit server'
6. attempt to telnet from the other machine to the server on port 19935, 
observe telnet complaining the port is closed
7. run 'pyrit list_cores' on either machine, making sure the hosts file 
contains the IP of the server
8. observe server sit and wait for a client to connect

What is the expected output? What do you see instead?
I'd like to see the client successfully contact the server. I'd like the port 
to be open and listening. 

What version of the product are you using? On what operating system?
Pyrit 0.4.1-dev (svn r302) on ubuntu 10.04 server and osx 10.6.7

Please provide any additional information below.
It seems in both cases the server isnt even listening on a port. I cannot 
telnet to the port even from localhost.

Original issue reported on code.google.com by viss...@gmail.com on 6 Apr 2011 at 8:12

GoogleCodeExporter commented 8 years ago
I've been able to get the two pyrit installations to see eachother by changing 
the ~/.pyrit/config file to read like this:

bash-3.2# cat ~/.pyrit/config
default_storage = file://
rpc_announce = true
rpc_announce_broadcast = false
rpc_knownclients = 10.0.0.2
rpc_server = true

However when the client connects to the server, the server dies and throws this 
exception:

Serving 0 active clients; 0 PMKs/s; 0.0 TTS Traceback (most recent call last):
  File "/usr/local/bin/pyrit", line 6, in <module>
    pyrit_cli.Pyrit_CLI().initFromArgv()
  File "/usr/local/lib/python2.6/dist-packages/pyrit_cli.py", line 115, in initFromArgv
    func(self, **options)
  File "/usr/local/lib/python2.6/dist-packages/pyrit_cli.py", line 873, in serve
    server.addClient(addr)
  File "/usr/local/lib/python2.6/dist-packages/cpyrit/network.py", line 140, in addClient
    client = NetworkClient(srv_addr, self.enqueue, known_uuids)
  File "/usr/local/lib/python2.6/dist-packages/cpyrit/network.py", line 68, in __init__
    self.srv_uuid, self.uuid = self.server.register(";".join(known_uuids))
  File "/usr/lib/python2.6/xmlrpclib.py", line 1199, in __call__
    return self.__send(self.__name, args)
  File "/usr/lib/python2.6/xmlrpclib.py", line 1489, in __request
    verbose=self.__verbose
  File "/usr/lib/python2.6/xmlrpclib.py", line 1237, in request
    errcode, errmsg, headers = h.getreply()
  File "/usr/lib/python2.6/httplib.py", line 1064, in getreply
    response = self._conn.getresponse()
  File "/usr/lib/python2.6/httplib.py", line 990, in getresponse
    response.begin()
  File "/usr/lib/python2.6/httplib.py", line 391, in begin
    version, status, reason = self._read_status()
  File "/usr/lib/python2.6/httplib.py", line 349, in _read_status
    line = self.fp.readline()
  File "/usr/lib/python2.6/socket.py", line 427, in readline
    data = recv(1)
socket.error: [Errno 104] Connection reset by peer

Original comment by viss...@gmail.com on 6 Apr 2011 at 8:56

GoogleCodeExporter commented 8 years ago
this is a known issue and has not been fixed yet to my knowledge

Original comment by FagwaiCh...@aol.com on 16 Apr 2011 at 10:13

GoogleCodeExporter commented 8 years ago
Fixed it for ya! It's related to PAW2_Buffer error

Apply this patch with:

patch -p0 < pyrit_paw2bufferfix.patch

inside pyrit_svn branch. In one place cpyrit.py uses PAW2_Buffer constructor 
instead of .pack() method.

Tested it on ubuntu 13.04 and fixes the issue with pyrit serve. The error is on 
the running machine side, not on the serving one.

Original comment by kichadal...@gmail.com on 8 May 2013 at 6:49

Attachments: