Files
metasploit-gs/lib/rex/post/process.rb
T

57 lines
878 B
Ruby
Raw Normal View History

2005-12-17 06:46:23 +00:00
#!/usr/bin/env ruby
2005-04-03 21:52:10 +00:00
module Rex
module Post
2005-11-15 05:22:13 +00:00
###
#
# This class performs basic process operations against a process running on a
# remote machine via the post-exploitation mechanisms. Refer to the Ruby
# documentation for expected behaviors.
#
###
2005-04-03 21:52:10 +00:00
class Process
def Process.getresuid
raise NotImplementedError
end
def Process.setresuid(a, b, c)
raise NotImplementedError
end
def Process.euid
getresuid()[1]
end
def Process.euid=(id)
setresuid(-1, id, -1)
end
def Process.uid
getresuid()[0]
end
def Process.uid=(id)
setresuid(id, -1, -1)
end
def Process.egid
getresgid()[1]
end
def Process.egid=(id)
setresgid(-1, id, -1)
end
def Process.gid
getresgid()[0]
end
def Process.gid=(id)
setresgid(id, -1, -1)
end
2005-04-03 23:14:33 +00:00
def Process.pid
2005-04-04 01:33:26 +00:00
raise NotImplementedError
2005-04-03 23:14:33 +00:00
end
def Process.ppid
2005-04-04 01:33:26 +00:00
raise NotImplementedError
2005-04-03 23:14:33 +00:00
end
2005-04-03 21:52:10 +00:00
end
2008-10-19 21:03:39 +00:00
end; end # Post/Rex