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


Viewing file:     prep_nvram.c (2.57 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
/*
 * BK Id: SCCS/s.prep_nvram.c 1.12 09/08/01 15:47:42 paulus
 */
/*
 *  linux/arch/ppc/kernel/prep_nvram.c
 *
 *  Copyright (C) 1998  Corey Minyard
 *
 */
#include <linux/init.h>
#include <linux/delay.h>
#include <linux/slab.h>
#include <linux/ioport.h>

#include <asm/sections.h>
#include <asm/segment.h>
#include <asm/io.h>
#include <asm/processor.h>
#include <asm/machdep.h>
#include <asm/prep_nvram.h>

static char nvramData[MAX_PREP_NVRAM];
static NVRAM_MAP *nvram=(NVRAM_MAP *)&nvramData[0];

unsigned char __prep prep_nvram_read_val(int addr)
{
    outb(addr, PREP_NVRAM_AS0);
    outb(addr>>8, PREP_NVRAM_AS1);
    return inb(PREP_NVRAM_DATA);
}
  
void __prep prep_nvram_write_val(int           addr,
              unsigned char val)
{
    outb(addr, PREP_NVRAM_AS0);
    outb(addr>>8, PREP_NVRAM_AS1);
       outb(val, PREP_NVRAM_DATA);
}
  
void __init init_prep_nvram(void)
{
    unsigned char *nvp;
    int  i;
    int  nvramSize;

    /*
     * The following could fail if the NvRAM were corrupt but
     * we expect the boot firmware to have checked its checksum
     * before boot
     */
    nvp = (char *) &nvram->Header;
    for (i=0; i<sizeof(HEADER); i++)
    {
        *nvp = ppc_md.nvram_read_val(i);
        nvp++;
    }
    
    /*
     * The PReP NvRAM may be any size so read in the header to
     * determine how much we must read in order to get the complete
     * GE area
     */
    nvramSize=(int)nvram->Header.GEAddress+nvram->Header.GELength;
    if(nvramSize>MAX_PREP_NVRAM)
    {
        /*
         * NvRAM is too large
         */
        nvram->Header.GELength=0;
        return;
    }

    /*
     * Read the remainder of the PReP NvRAM
     */
    nvp = (char *) &nvram->GEArea[0];
    for (i=sizeof(HEADER); i<nvramSize; i++)
    {
        *nvp = ppc_md.nvram_read_val(i);
        nvp++;
    }
}

__prep
char __prep *prep_nvram_get_var(const char *name)
{
    char *cp;
    int  namelen;

    namelen = strlen(name);
    cp = prep_nvram_first_var();
    while (cp != NULL) {
        if ((strncmp(name, cp, namelen) == 0)
            && (cp[namelen] == '='))
        {
            return cp+namelen+1;
        }
        cp = prep_nvram_next_var(cp);
    }

    return NULL;
}

__prep
char __prep *prep_nvram_first_var(void)
{
        if (nvram->Header.GELength == 0) {
        return NULL;
    } else {
        return (((char *)nvram)
            + ((unsigned int) nvram->Header.GEAddress));
    }
}

__prep
char __prep *prep_nvram_next_var(char *name)
{
    char *cp;


    cp = name;
    while (((cp - ((char *) nvram->GEArea)) < nvram->Header.GELength)
           && (*cp != '\0'))
    {
        cp++;
    }

    /* Skip over any null characters. */
    while (((cp - ((char *) nvram->GEArea)) < nvram->Header.GELength)
           && (*cp == '\0'))
    {
        cp++;
    }

    if ((cp - ((char *) nvram->GEArea)) < nvram->Header.GELength) {
        return cp;
    } else {
        return NULL;
    }
}




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