!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/Xslt/   drwxr-xr-x
Free 3.82 GB of 27.03 GB (14.13%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     Group.py (3.25 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
########################################################################
# $Header: /var/local/cvsroot/4Suite/Ft/Server/Server/Xslt/Group.py,v 1.11 2005/04/06 23:05:46 jkloth Exp $
"""
XSLT and XPath extensions supporting the 4SS group API

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

from Ft.Xml.XPath import Conversions
from Ft.Xml.Xslt import XsltElement, AttributeInfo, ContentInfo
from Ns import SCORE_NS
import FtssXsltBase

def GetMemberPaths(context, group):
    """
    Returns, as a node-set of 'path' elements, the full paths to all
    user resources that are members of the specified group
    """
    repo = context.processor._repository
    res= repo.fetchResource(Conversions.StringValue(group))


    processor = context.processor
    processor.pushResultTree(context.currentInstruction.baseUri)
    try:
        for path in res.getMemberPaths():
            processor.writers[-1].startElement('path')
            processor.writers[-1].text(path)
            processor.writers[-1].endElement('path')
    finally:
        rtf = processor.popResult()
    return rtf.childNodes


class AddMemberElement(XsltElement):
    """
    Adds a user or group to the specified group
    """

    content = ContentInfo.Empty

    legalAttrs = {
        'path' : AttributeInfo.UriReferenceAvt(
            required=1, description=('The path of the group to which to add'
                                     ' this member.')),
        'member-path' : AttributeInfo.UriReferenceAvt(
            required=1, description=('The path of the new member (user or'
                                     ' group) to add to this group.')),
        }

    def instantiate(self, context, processor):
        context.setProcessState(self)
        repo = context.processor._repository

        path = self._path.evaluate(context)
        memberPath = self._member_path.evaluate(context)

        base = FtssXsltBase.FetchBaseObject(processor, path)
        newMember = repo.fetchResource(memberPath)
        base.addMember(newMember)
        return


class RemoveMemberElement(XsltElement):
    """
    Removes a user or group from the specified group
    """

    content = ContentInfo.Empty

    legalAttrs = {
        'path' : AttributeInfo.UriReferenceAvt(
            required=1, description=('The path of the group to which to'
                                     ' remove this member.')),
        'member-path' : AttributeInfo.UriReferenceAvt(
            required=1, description=('The path of the member (user or group)'
                                     ' to remove from this group.')),
        }

    def instantiate(self, context, processor):
        context.setProcessState(self)
        repo = context.processor._repository

        path = self._path.evaluate(context)
        memberPath = self._member_path.evaluate(context)

        base = FtssXsltBase.FetchBaseObject(processor, path)
        oldMember = repo.fetchResource(memberPath)
        base.removeMember(oldMember)
        return


ExtFunctions = {
    (SCORE_NS, 'get-member-paths'): GetMemberPaths,
}

ExtElements = {
    (SCORE_NS, 'add-member'): AddMemberElement,
    (SCORE_NS, 'remove-member'): RemoveMemberElement,
}


:: 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.0035 ]--