!C99Shell v. 1.0 pre-release build #16!

Software: Apache/2.0.54 (Fedora). PHP/5.0.4 

uname -a: Linux mina-info.me 2.6.17-1.2142_FC4smp #1 SMP Tue Jul 11 22:57:02 EDT 2006 i686 

uid=48(apache) gid=48(apache) groups=48(apache)
context=system_u:system_r:httpd_sys_script_t
 

Safe-mode: OFF (not secure)

/usr/lib/python2.4/site-packages/Ft/Server/Server/Commands/   drwxr-xr-x
Free 3.76 GB of 27.03 GB (13.89%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     CommandUtil.py (2.82 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
########################################################################
# $Header: /var/local/cvsroot/4Suite/Ft/Server/Server/Commands/CommandUtil.py,v 1.8 2004/08/17 18:08:50 mbrown Exp $
"""
Functions used by various commands

Copyright 2003 Fourthought, Inc. (USA).
Detailed license and copyright information: http://4suite.org/COPYRIGHT
Project home, documentation, distributions: http://4suite.org/
"""

import os, sys, sha, getpass, posixpath

from Ft.Server.Server import SCore
from Ft.Server.Common import AclConstants, Schema
from Ft.Server.Server.Lib import ConfigFile, LogUtil

def GetRepository(options, cmdName):
    """
    Given a dictionary of parsed command-line options (see FancyGetOpt),
    reads a repo config file (which may be identified by the 'config-file'
    key in the options dict, and defaults to the value of the environment
    variable FTSERVER_CONFIG_FILE), obtaining the config file's contents
    as a dictionary returned by Ft.Server.Server.Lib.ConfigFile.Read(),
    and creating a properties dictionary that is the value of just one of
    the keys from the original dictionary (the key is either the 'core-id'
    option, the value of environment variable FTSS_CORE_ID, or 'Core').
    If a username and password hash were not found in the options dict,
    prompts for them. Uses username and password hash to obtain a repo
    access object from the local repository (via SCore.GetRepository()).
    Checks ACL in the repo to see if the command with the given name can
    be run by the user, raising an exception if it can't or if the name
    doesn't correspond to a command in the repo. Returns a tuple of:
    username, password hash, config file properties dictionary, repo
    access object.

    Used by pretty much every '4ss' and '4ss_manager' command.
    """
    coreId = options.get('core-id',os.environ.get('FTSS_CORE_ID', 'Core'))
    properties = ConfigFile.Read(options.get('config-file'))
    properties = properties[coreId]

    userName = None

    if options.has_key('username'):
        userName = options['username']

    #Nope, ask for it
    if not userName:
        sys.stderr.write('4SS Manager Name: ')
        sys.stderr.flush()
        userName = raw_input()

    passwdHash = None
    if options.has_key('password'):
        passwdHash = sha.new(options['password']).hexdigest()

    if passwdHash is None:
        passwdHash = sha.new(getpass.getpass("Password for %s: " % userName)).hexdigest()

    repo = SCore.GetRepository(userName, passwdHash, LogUtil.NullLogger(),
                               properties, verify=1)

    #Verify that the command can be run
    #verifyCommand(repo,cmdName)
    cmd = repo.getCommand(cmdName)
    if cmd is None:
        raise ValueError("Unknown Command: %s" % cmdName)
    cmd.verifyAcl(AclConstants.EXECUTE_ACCESS,0)
    return userName,passwdHash,properties,repo



:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 1.0 pre-release build #16 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0038 ]--