stuff
git-svn-id: file:///home/svn/incoming/trunk@2555 4d416f70-5f16-0410-b530-b9f4589650daunstable
parent
44e809d111
commit
27d8c03107
|
@ -0,0 +1,30 @@
|
|||
#!/usr/bin/ruby
|
||||
|
||||
require 'socket'
|
||||
|
||||
module Rex
|
||||
module IO
|
||||
|
||||
###
|
||||
#
|
||||
# DatagramAbstraction
|
||||
# -------------------
|
||||
#
|
||||
# This class provides an abstraction to a datagram based
|
||||
# connection through the use of a datagram socketpair.
|
||||
#
|
||||
###
|
||||
module DatagramAbstraction
|
||||
|
||||
# Creates a streaming socket pair
|
||||
def initialize_abstraction
|
||||
self.lsock, self.rsock = ::Socket.pair(::Socket::AF_UNIX,
|
||||
::Socket::SOCK_DGRAM, 0)
|
||||
end
|
||||
|
||||
attr_reader :lsock, :rsock
|
||||
protected
|
||||
attr_writer :lsock, :rsock
|
||||
end
|
||||
|
||||
end; end
|
Loading…
Reference in New Issue