XenevaOS
Loading...
Searching...
No Matches
Classes | Macros | Typedefs | Functions | Variables
posix.cpp File Reference
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <sys\utsname.h>
#include <sys\_keproc.h>
#include <sys\_ketime.h>
#include <sys\_kefile.h>
#include <pthread.h>
Include dependency graph for posix.cpp:

Classes

struct  PosixCommand
 
struct  racy_arg
 

Macros

#define POSIX_MAX_ARGS   16
 
#define KERNEL_BASE   0xFFFF000000000000UL
 
#define TEST_FD   1
 

Typedefs

typedef int(* posix_fn) (int argc, char **argv)
 

Functions

int exec_uname (const char *option)
 
int posix_uname (int argc, char **argv)
 posix_uname – posix uname command implementation
 
int posix_who (int argc, char **argv)
 
int posix_clear (int argc, char **argv)
 
int posix_sleep (int argc, char **argv)
 posix_sleep – posix sleep implementation
 
int kernel_exploit (int argc, char **argv)
 
int _term_handle_posix (char *cmd)
 

Variables

volatile int g_interrupted
 

Macro Definition Documentation

◆ KERNEL_BASE

#define KERNEL_BASE   0xFFFF000000000000UL

◆ POSIX_MAX_ARGS

#define POSIX_MAX_ARGS   16

◆ TEST_FD

#define TEST_FD   1

Typedef Documentation

◆ posix_fn

typedef int(* posix_fn) (int argc, char **argv)

BSD 2-Clause License

Copyright (c) 2022-2026, Manas Kamal Choudhury All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. NOTE: LLM Cluade Sonnet 5.5 Medium is used for implementing only posix commands for XEShell, please report an issue if any bug found

Function Documentation

◆ _term_handle_posix()

int _term_handle_posix ( char *  cmd)

@brief_term_handle_posix – handle posix commands

Parameters
cmd– pointer to shell's command buffer

◆ exec_uname()

int exec_uname ( const char *  option)

◆ kernel_exploit()

int kernel_exploit ( int  argc,
char **  argv 
)

◆ posix_clear()

int posix_clear ( int  argc,
char **  argv 
)

◆ posix_sleep()

int posix_sleep ( int  argc,
char **  argv 
)

posix_sleep – posix sleep implementation

◆ posix_uname()

int posix_uname ( int  argc,
char **  argv 
)

posix_uname – posix uname command implementation

◆ posix_who()

int posix_who ( int  argc,
char **  argv 
)

Variable Documentation

◆ g_interrupted

volatile int g_interrupted