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

Software: Apache/2.2.3 (CentOS). PHP/5.1.6 

uname -a: Linux mx-ll-110-164-51-230.static.3bb.co.th 2.6.18-194.el5PAE #1 SMP Fri Apr 2 15:37:44
EDT 2010 i686
 

uid=48(apache) gid=48(apache) groups=48(apache) 

Safe-mode: OFF (not secure)

/usr/lib/openoffice.org/basis3.1/share/Scripts/javascript/Highlight/   drwxr-xr-x
Free 51.89 GB of 127.8 GB (40.6%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     ButtonPressHandler.js (3.81 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
//this script acts as a handler for the buttons in the Highlight dialog
importClass(Packages.com.sun.star.uno.UnoRuntime);
importClass(Packages.com.sun.star.uno.Type);
importClass(Packages.com.sun.star.uno.AnyConverter);

importClass(Packages.com.sun.star.awt.XButton);
importClass(Packages.com.sun.star.awt.XControl);
importClass(Packages.com.sun.star.awt.ActionEvent);
importClass(Packages.com.sun.star.awt.XControlModel);
importClass(Packages.com.sun.star.awt.XControlContainer);
importClass(Packages.com.sun.star.awt.XDialog);
importClass(Packages.com.sun.star.awt.XTextComponent);

importClass(Packages.com.sun.star.util.XReplaceable);
importClass(Packages.com.sun.star.util.XReplaceDescriptor);
importClass(Packages.com.sun.star.util.XPropertyReplace);

importClass(Packages.com.sun.star.beans.XPropertySet);
importClass(Packages.com.sun.star.beans.PropertyValue);

// Scripting Framework DialogFactory class
importClass(Packages.com.sun.star.script.framework.browse.DialogFactory);

// Get the ActionEvent object from the ARGUMENTS list
event = ARGUMENTS[0];

// Each argument is of type Any so we must use the AnyConverter class to
// convert it into the interface or primitive type we expect
button = AnyConverter.toObject(new Type(XButton), event.Source);

// We can now query for the model of the button and get its properties
control = UnoRuntime.queryInterface(XControl, button);
cmodel = control.getModel();
pset = UnoRuntime.queryInterface(XPropertySet, cmodel);

if (pset.getPropertyValue("Label").equals("Exit"))
{
    // We can get the XDialog in which this control appears by calling
    // getContext() on the XControl interface
    xDialog = UnoRuntime.queryInterface(
        XDialog, control.getContext());
    
    // Close the dialog
    xDialog.endExecute();
}
else
{
    // We can get the list of controls for this dialog by calling
    // getContext() on the XControl interface of the button
    controls = UnoRuntime.queryInterface(
        XControlContainer, control.getContext());

    // Now get the text field control from the list
    textField =
        UnoRuntime.queryInterface(
            XTextComponent, controls.getControl("HighlightTextField"));

    searchKey = textField.getText();

    // highlight the text in red
    red = java.awt.Color.red.getRGB();

    replaceable =
        UnoRuntime.queryInterface(XReplaceable, XSCRIPTCONTEXT.getDocument()); 

    descriptor = replaceable.createReplaceDescriptor();

    // Gets a XPropertyReplace object for altering the properties
    // of the replaced text
    xPropertyReplace = UnoRuntime.queryInterface(XPropertyReplace, descriptor);

    // Sets the replaced text property fontweight value to Bold
    wv = new PropertyValue("CharWeight", -1,
        new java.lang.Float(Packages.com.sun.star.awt.FontWeight.BOLD),
            Packages.com.sun.star.beans.PropertyState.DIRECT_VALUE);

    // Sets the replaced text property color value to RGB parameter
    cv = new PropertyValue("CharColor", -1,
        new java.lang.Integer(red),
            Packages.com.sun.star.beans.PropertyState.DIRECT_VALUE);

    // Apply the properties
    props = new Array;
    props[0] = cv;
    props[1] = wv;

    try {
        xPropertyReplace.setReplaceAttributes(props);

        // Only matches whole words and case sensitive
        descriptor.setPropertyValue(
            "SearchCaseSensitive", new java.lang.Boolean(true));
        descriptor.setPropertyValue("SearchWords", new java.lang.Boolean(true));

        // Replaces all instances of searchKey with new Text properties
        // and gets the number of instances of the searchKey 
        descriptor.setSearchString(searchKey); 
        descriptor.setReplaceString(searchKey); 
        replaceable.replaceAll(descriptor);
    }
    catch (e) {
        java.lang.System.err.println("Error setting up search properties"
            + e.getMessage());
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Shadow's tricks :D ::

Useful Commands
 
Warning. Kernel may be alerted using higher levels
Kernel Info:

:: Preddy's tricks :D ::

Php Safe-Mode Bypass (Read Files)

File:

eg: /etc/passwd

Php Safe-Mode Bypass (List Directories):

Dir:

eg: /etc/

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

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

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

--[ c999shell v. 1.0 pre-release build #16 Modded by Shadow & Preddy | RootShell Security Group | r57 c99 shell | Generation time: 0.0103 ]--