dmayer / idb

idb is a tool to simplify some common tasks for iOS pentesting and research
MIT License
942 stars 156 forks source link

Crash on Missing File #54

Closed moloch-- closed 9 years ago

moloch-- commented 9 years ago

Application moved a file, when accessed from idb it throws an uncaught exception:

[INFO] 2015-01-21 11:56:46 :: idb ::  Executing pbwatcher: /var/root/pbwatcher 1 
/Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/transport/packet_stream.rb:206:in `poll_next_packet': padding error, need 2402386361 block 16 (Net::SSH::Exception)
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/transport/packet_stream.rb:92:in `next_packet'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/transport/session.rb:183:in `block in poll_message'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/transport/session.rb:178:in `loop'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/transport/session.rb:178:in `poll_message'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/connection/session.rb:461:in `dispatch_incoming_packets'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/connection/session.rb:222:in `preprocess'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/connection/session.rb:206:in `process'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/connection/session.rb:170:in `block in loop'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/connection/session.rb:170:in `loop'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-ssh-2.9.2/lib/net/ssh/connection/session.rb:170:in `loop'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-sftp-2.1.2/lib/net/sftp/session.rb:802:in `loop'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-sftp-2.1.2/lib/net/sftp/request.rb:72:in `wait'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-sftp-2.1.2/lib/net/sftp/session.rb:842:in `wait_for'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-sftp-2.1.2/lib/net/sftp/session.rb:415:in `opendir!'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-sftp-2.1.2/lib/net/sftp/operations/dir.rb:31:in `foreach'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/net-sftp-2.1.2/lib/net/sftp/operations/dir.rb:44:in `entries'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/idb-2.5.6/lib/lib/ssh_operations.rb:80:in `list_dir_full'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/idb-2.5.6/lib/gui/fs_viewer_tab_widget.rb:160:in `populate_files'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/idb-2.5.6/lib/gui/fs_viewer_tab_widget.rb:62:in `block in initialize'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/qtbindings-4.8.6.0/lib/Qt/qtruby4.rb:2454:in `call'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/qtbindings-4.8.6.0/lib/Qt/qtruby4.rb:2454:in `invoke'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/qtbindings-4.8.6.0/lib/Qt/qtruby4.rb:479:in `qt_metacall'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/qtbindings-4.8.6.0/lib/Qt/qtruby4.rb:479:in `method_missing'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/qtbindings-4.8.6.0/lib/Qt/qtruby4.rb:479:in `exec'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/idb-2.5.6/lib/idb.rb:284:in `run'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/gems/idb-2.5.6/bin/idb:4:in `<top (required)>'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/bin/idb:23:in `load'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/bin/idb:23:in `<main>'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/bin/ruby_executable_hooks:15:in `eval'
    from /Users/moloch/.rvm/gems/ruby-2.1.5/bin/ruby_executable_hooks:15:in `<main>'
recv failed: Resource temporarily unavailable
send failed: Bad file descriptor
dmayer commented 9 years ago

Thanks for reporting.

I fixed this in 826cb0f6d0a789299620cf5157ae7bce9aa93efe which is also in gem version 2.5.7