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

Software: Apache/2.0.54 (Unix) mod_perl/1.99_09 Perl/v5.8.0 mod_ssl/2.0.54 OpenSSL/0.9.7l DAV/2 FrontPage/5.0.2.2635 PHP/4.4.0 mod_gzip/2.0.26.1a 

uname -a: Linux snow.he.net 4.4.276-v2-mono-1 #1 SMP Wed Jul 21 11:21:17 PDT 2021 i686 

uid=99(nobody) gid=98(nobody) groups=98(nobody) 

Safe-mode: OFF (not secure)

/usr/src/linux-2.4.18-xfs-1.1/net/sunrpc/   drwxr-xr-x
Free 318.34 GB of 458.09 GB (69.49%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     sysctl.c (2.84 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
/*
 * linux/net/sunrpc/sysctl.c
 *
 * Sysctl interface to sunrpc module. This is for debugging only now.
 *
 * I would prefer to register the sunrpc table below sys/net, but that's
 * impossible at the moment.
 */

#include <linux/config.h>
#include <linux/version.h>
#include <linux/types.h>
#include <linux/linkage.h>
#include <linux/ctype.h>
#include <linux/fs.h>
#include <linux/sysctl.h>
#define __NO_VERSION__
#include <linux/module.h>

#include <asm/uaccess.h>
#include <linux/sunrpc/types.h>
#include <linux/sunrpc/sched.h>
#include <linux/sunrpc/stats.h>

/*
 * Declare the debug flags here
 */
unsigned int    rpc_debug;
unsigned int    nfs_debug;
unsigned int    nfsd_debug;
unsigned int    nlm_debug;

#ifdef RPC_DEBUG

static struct ctl_table_header *sunrpc_table_header;
static ctl_table        sunrpc_table[];

void
rpc_register_sysctl(void)
{
    if (!sunrpc_table_header) {
        sunrpc_table_header = register_sysctl_table(sunrpc_table, 1);
#ifdef CONFIG_PROC_FS
        if (sunrpc_table[0].de)
            sunrpc_table[0].de->owner = THIS_MODULE;
#endif
    }
            
}

void
rpc_unregister_sysctl(void)
{
    if (sunrpc_table_header) {
        unregister_sysctl_table(sunrpc_table_header);
        sunrpc_table_header = NULL;
    }
}

static int
proc_dodebug(ctl_table *table, int write, struct file *file,
                void *buffer, size_t *lenp)
{
    char        tmpbuf[20], *p, c;
    unsigned int    value;
    size_t        left, len;

    if ((file->f_pos && !write) || !*lenp) {
        *lenp = 0;
        return 0;
    }

    left = *lenp;

    if (write) {
        if (!access_ok(VERIFY_READ, buffer, left))
            return -EFAULT;
        p = (char *) buffer;
        while (left && __get_user(c, p) >= 0 && isspace(c))
            left--, p++;
        if (!left)
            goto done;

        if (left > sizeof(tmpbuf) - 1)
            return -EINVAL;
        copy_from_user(tmpbuf, p, left);
        tmpbuf[left] = '\0';

        for (p = tmpbuf, value = 0; '0' <= *p && *p <= '9'; p++, left--)
            value = 10 * value + (*p - '0');
        if (*p && !isspace(*p))
            return -EINVAL;
        while (left && isspace(*p))
            left--, p++;
        *(unsigned int *) table->data = value;
        /* Display the RPC tasks on writing to rpc_debug */
        if (table->ctl_name == CTL_RPCDEBUG) {
            rpc_show_tasks();
        }
    } else {
        if (!access_ok(VERIFY_WRITE, buffer, left))
            return -EFAULT;
        len = sprintf(tmpbuf, "%d", *(unsigned int *) table->data);
        if (len > left)
            len = left;
        copy_to_user(buffer, tmpbuf, len);
        if ((left -= len) > 0) {
            put_user('\n', (char *)buffer + len);
            left--;
        }
    }

done:
    *lenp -= left;
    file->f_pos += *lenp;
    return 0;
}

#define DIRENTRY(nam1, nam2, child)    \
    {CTL_##nam1, #nam2, NULL, 0, 0555, child }
#define DBGENTRY(nam1, nam2)    \
    {CTL_##nam1##DEBUG, #nam2 "_debug", &nam2##_debug, sizeof(int),\
     0644, NULL, &proc_dodebug}

static ctl_table        debug_table[] = {
    DBGENTRY(RPC,  rpc),
    DBGENTRY(NFS,  nfs),
    DBGENTRY(NFSD, nfsd),
    DBGENTRY(NLM,  nlm),
    {0}
};

static ctl_table        sunrpc_table[] = {
    DIRENTRY(SUNRPC, sunrpc, debug_table),
    {0}
};

#endif

:: 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 #13 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0083 ]--