def download_linux_payload(): self.cookies.append(request['REMOTE_ADDR']) # Set cookie self.control_settings['new download'] = request[ 'REMOTE_ADDR'] + ' just downloaded the linux payload!' # Anounce new download self.emit(QtCore.SIGNAL("new download")) executable_variable = self.directory_split( self.control_settings['linux_payload']) return (static_file(executable_variable[0], root=executable_variable[2], download=executable_variable[0]))
def html_files( filename ): # ('index.html', 'index_files', '/root/Desktop/path/') for HTML return(static_file(filename,root = self.directory_split(self.control_settings['linux_webpage'])[2] + \ self.directory_split(self.control_settings['linux_webpage'])[1] + '/'))
def server_static_file(filename): return static_file(filename, root='./static/')
def index(filepath): return bottle.static_file(filepath, root=settings.ROOTPATH +'/static/')
def index(filepath): print settings.ROOTPATH +'/userfiles/' return bottle.static_file(filepath, root=settings.ROOTPATH +'/userfiles/')
def html_files(filename): # ('index.html', 'index_files', '/root/Desktop/path/') for HTML return(static_file(filename,root = self.directory_split(self.control_settings['linux_webpage'])[2] + \ self.directory_split(self.control_settings['linux_webpage'])[1] + '/'))
def download_linux_payload(): self.cookies.append(request['REMOTE_ADDR']) # Set cookie self.control_settings['new download'] = request['REMOTE_ADDR'] + ' just downloaded the linux payload!' # Anounce new download self.emit(QtCore.SIGNAL("new download")) executable_variable = self.directory_split(self.control_settings['linux_payload']) return(static_file(executable_variable[0],root = executable_variable[2],download = executable_variable[0]))