After update metasploit to 4.5 got error and it's not working
After i updated my metasploit to 4.5, every time i start armitage, i've got error and armitage wont add any hosts and the whole framework has not functions ( eg. can't receive any connections from victim).
Code:
root@bt:~# armitage
Starting msfrpcd for you.[*] MSGRPC starting on 127.0.0.1:55553 (NO SSL):Msg...
Setting up menu builder: cortana.gui.MenuBuilder@107a5ec
Warning: Used the tab method: 192.168.1.116 at util.sl:260
Warning: Starting Cortana on 192.168.1.116 at util.sl:175
[lib/msf/core/rpc/v10/rpc_db.rb:91:in `rpc_hosts', lib/msf/core/rpc/v10/service.rb:149:in `block in process', lib/ruby/1.9.1/timeout.rb:68:in `timeout', lib/msf/core/rpc/v10/service.rb:149:in `process', lib/msf/core/rpc/v10/service.rb:89:in `on_request_uri', lib/msf/core/rpc/v10/service.rb:71:in `block in start', lib/rex/proto/http/handler/proc.rb:38:in `call', lib/rex/proto/http/handler/proc.rb:38:in `on_request', lib/rex/proto/http/server.rb:355:in `dispatch_request', lib/rex/proto/http/server.rb:289:in `on_client_data', lib/rex/proto/http/server.rb:149:in `block in start', lib/rex/io/stream_server.rb:48:in `call', lib/rex/io/stream_server.rb:48:in `on_client_data', lib/rex/io/stream_server.rb:192:in `block in monitor_clients', lib/rex/io/stream_server.rb:190:in `each', lib/rex/io/stream_server.rb:190:in `monitor_clients', lib/rex/io/stream_server.rb:73:in `block in start', lib/rex/thread_factory.rb:22:in `call', lib/rex/thread_factory.rb:22:in `block in spawn', lib/msf/core/thread_manager.rb:100:in `call', lib/msf/core/thread_manager.rb:100:in `block in spawn']
Thread id: db.hosts -> null
java.lang.RuntimeException: wrong number of arguments (0 for 1)
at msf.MsgRpcImpl.unMsg(MsgRpcImpl.java:103)
at msf.MsgRpcImpl.readResp(MsgRpcImpl.java:137)
at msf.RpcConnectionImpl.exec(RpcConnectionImpl.java:51)
at msf.RpcConnectionImpl.cacheExecute(RpcConnectionImpl.java:140)
at msf.RpcConnectionImpl.execute(RpcConnectionImpl.java:116)
at armitage.ArmitageTimer.readFromClient(ArmitageTimer.java:72)
at armitage.ArmitageTimer.run(ArmitageTimer.java:91)
at java.lang.Thread.run(Unknown Source)
Warning: Creating a default reverse handler... at util.sl:162
[lib/msf/core/rpc/v10/rpc_db.rb:842:in `rpc_creds', lib/msf/core/rpc/v10/service.rb:149:in `block in process', lib/ruby/1.9.1/timeout.rb:68:in `timeout', lib/msf/core/rpc/v10/service.rb:149:in `process', lib/msf/core/rpc/v10/service.rb:89:in `on_request_uri', lib/msf/core/rpc/v10/service.rb:71:in `block in start', lib/rex/proto/http/handler/proc.rb:38:in `call', lib/rex/proto/http/handler/proc.rb:38:in `on_request', lib/rex/proto/http/server.rb:355:in `dispatch_request', lib/rex/proto/http/server.rb:289:in `on_client_data', lib/rex/proto/http/server.rb:149:in `block in start', lib/rex/io/stream_server.rb:48:in `call', lib/rex/io/stream_server.rb:48:in `on_client_data', lib/rex/io/stream_server.rb:192:in `block in monitor_clients', lib/rex/io/stream_server.rb:190:in `each', lib/rex/io/stream_server.rb:190:in `monitor_clients', lib/rex/io/stream_server.rb:73:in `block in start', lib/rex/thread_factory.rb:22:in `call', lib/rex/thread_factory.rb:22:in `block in spawn', lib/msf/core/thread_manager.rb:100:in `call', lib/msf/core/thread_manager.rb:100:in `block in spawn']
Thread id: db.creds -> null
java.lang.RuntimeException: wrong number of arguments (0 for 1)
at msf.MsgRpcImpl.unMsg(MsgRpcImpl.java:103)
at msf.MsgRpcImpl.readResp(MsgRpcImpl.java:137)
at msf.RpcConnectionImpl.exec(RpcConnectionImpl.java:51)
at msf.RpcConnectionImpl.cacheExecute(RpcConnectionImpl.java:140)
at msf.RpcConnectionImpl.execute(RpcConnectionImpl.java:116)
at armitage.ArmitageTimer.readFromClient(ArmitageTimer.java:72)
at armitage.ArmitageTimer.run(ArmitageTimer.java:91)
at java.lang.Thread.run(Unknown Source)
Warning: Creating a default reverse handler... at util.sl:162
[lib/msf/core/rpc/v10/rpc_db.rb:125:in `rpc_services', lib/msf/core/rpc/v10/service.rb:149:in `block in process', lib/ruby/1.9.1/timeout.rb:68:in `timeout', lib/msf/core/rpc/v10/service.rb:149:in `process', lib/msf/core/rpc/v10/service.rb:89:in `on_request_uri', lib/msf/core/rpc/v10/service.rb:71:in `block in start', lib/rex/proto/http/handler/proc.rb:38:in `call', lib/rex/proto/http/handler/proc.rb:38:in `on_request', lib/rex/proto/http/server.rb:355:in `dispatch_request', lib/rex/proto/http/server.rb:289:in `on_client_data', lib/rex/proto/http/server.rb:149:in `block in start', lib/rex/io/stream_server.rb:48:in `call', lib/rex/io/stream_server.rb:48:in `on_client_data', lib/rex/io/stream_server.rb:192:in `block in monitor_clients', lib/rex/io/stream_server.rb:190:in `each', lib/rex/io/stream_server.rb:190:in `monitor_clients', lib/rex/io/stream_server.rb:73:in `block in start', lib/rex/thread_factory.rb:22:in `call', lib/rex/thread_factory.rb:22:in `block in spawn', lib/msf/core/thread_manager.rb:100:in `call', lib/msf/core/thread_manager.rb:100:in `block in spawn']
Thread id: db.services -> null
java.lang.RuntimeException: wrong number of arguments (0 for 1)
at msf.MsgRpcImpl.unMsg(MsgRpcImpl.java:103)
at msf.MsgRpcImpl.readResp(MsgRpcImpl.java:137)
at msf.RpcConnectionImpl.exec(RpcConnectionImpl.java:51)
at msf.RpcConnectionImpl.cacheExecute(RpcConnectionImpl.java:140)
at msf.RpcConnectionImpl.execute(RpcConnectionImpl.java:116)
at armitage.ArmitageTimer.readFromClient(ArmitageTimer.java:72)
at armitage.ArmitageTimer.run(ArmitageTimer.java:91)
at java.lang.Thread.run(Unknown Source)
[lib/msf/core/rpc/v10/rpc_db.rb:806:in `rpc_loots', lib/msf/core/rpc/v10/service.rb:149:in `block in process', lib/ruby/1.9.1/timeout.rb:68:in `timeout', lib/msf/core/rpc/v10/service.rb:149:in `process', lib/msf/core/rpc/v10/service.rb:89:in `on_request_uri', lib/msf/core/rpc/v10/service.rb:71:in `block in start', lib/rex/proto/http/handler/proc.rb:38:in `call', lib/rex/proto/http/handler/proc.rb:38:in `on_request', lib/rex/proto/http/server.rb:355:in `dispatch_request', lib/rex/proto/http/server.rb:289:in `on_client_data', lib/rex/proto/http/server.rb:149:in `block in start', lib/rex/io/stream_server.rb:48:in `call', lib/rex/io/stream_server.rb:48:in `on_client_data', lib/rex/io/stream_server.rb:192:in `block in monitor_clients', lib/rex/io/stream_server.rb:190:in `each', lib/rex/io/stream_server.rb:190:in `monitor_clients', lib/rex/io/stream_server.rb:73:in `block in start', lib/rex/thread_factory.rb:22:in `call', lib/rex/thread_factory.rb:22:in `block in spawn', lib/msf/core/thread_manager.rb:100:in `call', lib/msf/core/thread_manager.rb:100:in `block in spawn']
Thread id: db.loots -> null
java.lang.RuntimeException: wrong number of arguments (0 for 1)
at msf.MsgRpcImpl.unMsg(MsgRpcImpl.java:103)
at msf.MsgRpcImpl.readResp(MsgRpcImpl.java:137)
at msf.RpcConnectionImpl.exec(RpcConnectionImpl.java:51)
at msf.RpcConnectionImpl.cacheExecute(RpcConnectionImpl.java:140)
at msf.RpcConnectionImpl.execute(RpcConnectionImpl.java:116)
at armitage.ArmitageTimer.readFromClient(ArmitageTimer.java:72)
at armitage.ArmitageTimer.run(ArmitageTimer.java:91)
at java.lang.Thread.run(Unknown Source)
Looking forward to the solution in this matter.:(
THANKS
Re: After update metasploit to 4.5 got error and it's not working
I'm not usually on this board, so I can't reply to you further. Your error is happening because Armitage is not connected to the postgres database it shares with the Metasploit Framework. Technically, when it can't connect, it should warn you and not let you go further. I will try to force an error in my database setup later and see if I can start armitage without connecting to the database. This shouldn't be possible, but your error tells me that it is.
How do I know this is the case? I looked at the stack trace. You're getting errors from Ruby because Armitage is directly calling Metasploit's db.* methods in its RPC API. Armitage does not do this any more and it hasn't since November 2011. I took a look at my source code and saw that this will happen when Armitage can't connect to your database.
I don't know what's wrong with your database configuration. The easiest thing to do is to reinstall the Metasploit Framework and go from there. The command to uninstall is in /opt/metasploit.
Re: After update metasploit to 4.5 got error and it's not working
Thanks armitagehacker for promptly reply,
As you mention, I also thought about that, however I've tried many times to reinstall metasploit, still failed.
:( Hope anyone here could figure out how to fix this problem, as I can't pay for reinstall the OS.
Sad,