Sha256: 5c4ef71b433c652cc46bec6d064ebf9b3b11b2a1a1dd71924d40149bd954476f

Contents?: true

Size: 573 Bytes

Versions: 25

Compression:

Stored size: 573 Bytes

Contents

#!/usr/bin/env ruby

$:.unshift(File.join(File.dirname(__FILE__), '..', '..'))

require 'test/unit'
require 'rex/exploitation/egghunter'

class Rex::Exploitation::Egghunter::UnitTest < Test::Unit::TestCase

	Klass = Rex::Exploitation::Egghunter

	def test_egghunter
		payload = "\xcc" * 1023

		r = Klass.new('bogus')
		assert_nil(r.generate(payload))

		r = Klass.new('win')
		assert_nil(r.generate(payload))

		r = Klass.new('win', ARCH_X86)
		assert_not_nil(r.generate(payload))
		assert_not_nil(r.generate(payload)[0])
		assert_not_nil(r.generate(payload)[1])
	end

end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
librex-0.0.65 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.63 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.54 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.53 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.52 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.51 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.50 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.49 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.48 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.47 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.46 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.44 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.43 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.42 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.41 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.40 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.39 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.38 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.37 lib/rex/exploitation/egghunter.rb.ut.rb
librex-0.0.36 lib/rex/exploitation/egghunter.rb.ut.rb