# Net/ssh: corrupted mac detected

**URL:** <https://www.ruby-forum.com/t/net-ssh-corrupted-mac-detected/51649>\
**Category:** Ruby\
**Created:** [January 5, 2006, 5:19am UTC](https://www.ruby-forum.com/t/net-ssh-corrupted-mac-detected/51649 "2006-01-05T05:19:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![itsme213](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/258eb7/32.png) [@itsme213](https://www.ruby-forum.com/u/itsme213)\
**Post date:** [January 5, 2006, 5:19am UTC](https://www.ruby-forum.com/t/net-ssh-corrupted-mac-detected/51649/1 "2006-01-05T05:19:14Z")

</div>

Never did quite get past this error when using net/ssh. Any suggestions?

[I did have the ISP upgrade their ssh some time ago, but they also migrated servers so I can’t be sure].

Any ideas? Thanks!

(this is from within a Net::SSH.start, when executing an unzip on the  
remote  
machine …)

unzip generated\_site.zip -d generated\_site…  
rake aborted!  
corrupted mac detected  
c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/transport/packet-stream.rb:182:in  
`get' c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/transport/packet-stream.rb:147:in`synchron  
ize’  
c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/transport/packet-stream.rb:147:in  
`get' c:/ruby/lib/ruby/gems/1.8/gems/needle-1.2.0/lib/needle/lifecycle/proxy.rb:60:in` **send** ’  
c:/ruby/lib/ruby/gems/1.8/gems/needle-1.2.0/lib/needle/lifecycle/proxy.rb:60:in  
`method_missing' c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/transport/session.rb:245:in`wait\_for\_messa  
ge’  
c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/transport/session.rb:240:in  
`loop' c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/transport/session.rb:240:in`wait\_for\_messa  
ge’  
c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/connection/driver.rb:148:in  
`process' c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/service/shell/shell.rb:124:in`consume\_conn  
ection’  
c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/service/shell/shell.rb:68:in  
`stdout?' c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/service/shell/sync.rb:65:in`send\_command’  
c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/service/shell/sync.rb:63:in  
`loop' c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh/service/shell/sync.rb:63:in`send\_command’  
C:/des/desktop/methods/cfr/source/rakefile.rb:192:in `ssh_cmd_echo' C:/des/desktop/methods/cfr/source/rakefile.rb:206 C:/des/desktop/methods/cfr/source/rakefile.rb:202:in`initialize’  
c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh.rb:47:in `new' c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.5/lib/net/ssh.rb:47:in`start’  
C:/des/desktop/methods/cfr/source/rakefile.rb:202  
C:/des/desktop/methods/cfr/source/rakefile.rb:200:in `call' c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/lib/rake.rb:227:in`execute’  
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/lib/rake.rb:227:in `each' c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/lib/rake.rb:227:in`execute’  
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/lib/rake.rb:197:in `invoke' c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/lib/rake.rb:190:in`synchronize’  
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/lib/rake.rb:190:in `invoke' c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/lib/rake.rb:1673:in`run’  
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/lib/rake.rb:1673:in `each' c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/lib/rake.rb:1673:in`run’  
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.6.99.2/bin/rake:7  
c:/ruby/bin/rake:18:in `load’  
c:/ruby/bin/rake:18

---

<div class="post-metadata">

**Author:** ![itsme213](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/258eb7/32.png) [@itsme213](https://www.ruby-forum.com/u/itsme213)\
**Post date:** [January 5, 2006, 5:31am UTC](https://www.ruby-forum.com/t/net-ssh-corrupted-mac-detected/51649/2 "2006-01-05T05:31:24Z")

</div>

A corrupted mac is very often caused by a bug in Net::SSH. Is this a  
script you can send me, that I can use to try to duplicate the error?

- Jamis

---

<div class="post-metadata">

**Author:** ![itsme213](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/258eb7/32.png) [@itsme213](https://www.ruby-forum.com/u/itsme213)\
**Post date:** [January 5, 2006, 10:05am UTC](https://www.ruby-forum.com/t/net-ssh-corrupted-mac-detected/51649/3 "2006-01-05T10:05:28Z")

</div>

On Thu, 05 Jan 2006 04:13:02 -0000, itsme213 [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> machine …)
> 
> unzip generated\_site.zip -d generated\_site…  
> rake aborted!  
> corrupted mac detected

[… snip …]

Either you’ve encountered a Bad Apple (sorry), or something else is  
wrong.

This probably doesn’t help, but I do recall something about a bug around  
this, but I can’t remember the specifics. I’d still do a bit of a  
security  
check to make sure no-one’s sitting between and injecting stuff, but it  
seems about right. The thing I’m referring to was ‘Corrupted MAC on  
input’, and Google seems to have some hits.

Sorry if that doesn’t help.
