what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

sup Remote Command Execution

sup Remote Command Execution
Posted Oct 29, 2013
Authored by joernchen

sup versions prior to 0.14.1.1 and prior to 0.13.2.1 suffer from an arbitrary command execution vulnerability via a forged content type of an email attachment.

tags | exploit, arbitrary
SHA-256 | 7f25065280e73ca0e7c1a1f6429061cd9ee6353dfc98cf483575c0a5d76a0da5

sup Remote Command Execution

Change Mirror Download
Phenoelit Advisory <wir-haben-auch-mal-was-gefunden #0815 +-++->

[ Authors ]
joernchen <joernchen () phenoelit de>

Phenoelit Group (http://www.phenoelit.de)

[ Affected Products ]
sup <= 0.14.1 (on non Darwin systems)
sup <= 0.13.2 (on non Darwin systems)
http://supmua.org

[ Vendor communication ]
2013-10-28 Send vulnerability details to sup maintainer
2013-10-28 Maintainer proposes fix
2013-10-29 Sup 0.13.2.1 and 0.14.1.1 are released [1]
2013-10-29 Release of this advisory

[ Description ]

Observe in sup/lib/sup/message_chunks.rb:

def view_default! path
## please see note in write_to_disk on important usage
## of quotes to avoid remote command injection.
case RbConfig::CONFIG['arch']
when /darwin/
cmd = "open #{path}"
else
cmd = "/usr/bin/run-mailcap --action=view #{@content_type}:#{path}"
end
debug "running: #{cmd.inspect}"
BufferManager.shell_out(cmd)
$? == 0
end

Here @content_type is attacker controlled and not further
sanitized. By this a forged content type of an email
attachment can trigger a command injection.

[ Example ]
For convenience the email delivering this file serves as an
example. When viewing this attachment in a vulnerable version
of sup the content type being "text/'`id>/tmp/whatsup`'pwn"
will generate a file "whatsup" in the /tmp directory.

[ Solution ]
Upgrade to version 0.14.1.1 or 0.13.2.1

[ References ]
[0] https://github.com/sup-heliotrope/sup/blob/916a354db8eb851bff6ff2e3f2e08727d132a8dc/lib/sup/message_chunks.rb#L175
[1] http://rubyforge.org/pipermail/sup-talk/2013-October/004996.html

[ end of file ]
Login or Register to add favorites

File Archive:

August 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Aug 1st
    15 Files
  • 2
    Aug 2nd
    22 Files
  • 3
    Aug 3rd
    0 Files
  • 4
    Aug 4th
    0 Files
  • 5
    Aug 5th
    15 Files
  • 6
    Aug 6th
    11 Files
  • 7
    Aug 7th
    43 Files
  • 8
    Aug 8th
    42 Files
  • 9
    Aug 9th
    36 Files
  • 10
    Aug 10th
    0 Files
  • 11
    Aug 11th
    0 Files
  • 12
    Aug 12th
    0 Files
  • 13
    Aug 13th
    0 Files
  • 14
    Aug 14th
    0 Files
  • 15
    Aug 15th
    0 Files
  • 16
    Aug 16th
    0 Files
  • 17
    Aug 17th
    0 Files
  • 18
    Aug 18th
    0 Files
  • 19
    Aug 19th
    0 Files
  • 20
    Aug 20th
    0 Files
  • 21
    Aug 21st
    0 Files
  • 22
    Aug 22nd
    0 Files
  • 23
    Aug 23rd
    0 Files
  • 24
    Aug 24th
    0 Files
  • 25
    Aug 25th
    0 Files
  • 26
    Aug 26th
    0 Files
  • 27
    Aug 27th
    0 Files
  • 28
    Aug 28th
    0 Files
  • 29
    Aug 29th
    0 Files
  • 30
    Aug 30th
    0 Files
  • 31
    Aug 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close