Sha256: b48e409b9d189f7d2c3943379659bc6f691d77466df82acd08bb3a226118460c

Contents?: true

Size: 639 Bytes

Versions: 43

Compression:

Stored size: 639 Bytes

Contents

#!/usr/bin/env ruby

# $Id: image_source.rb 5401 2008-02-09 04:35:21Z ramon $

module Rex
module ImageSource
class ImageSource

	#
	# Um, just some abstract class stuff I guess, this is the interface
	# that any image sources should subscribe to...
	#

	def subsource(offset, len)
		raise "do something"
	end

	def size
		raise "do something"
	end

	def file_offset
		raise "do something"
	end

	def close
		raise "do something"
	end

	def read_asciiz(offset)
		# FIXME, make me better
		string = ''
		loop do
			char = read(offset, 1)
			break if char == "\x00"
			offset += 1
			string << char
		end
		return string
	end
		

end

end
end

Version data entries

43 entries across 43 versions & 1 rubygems

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