diff options
| author | Root THC | 2026-02-24 12:42:47 +0000 |
|---|---|---|
| committer | Root THC | 2026-02-24 12:42:47 +0000 |
| commit | c9cbeced5b3f2bdd7407e29c0811e65954132540 (patch) | |
| tree | aefc355416b561111819de159ccbd86c3004cf88 /other/shellkit/README | |
| parent | 073fe4bf9fca6bf40cef2886d75df832ef4b6fca (diff) | |
initial
Diffstat (limited to 'other/shellkit/README')
| -rw-r--r-- | other/shellkit/README | 187 |
1 files changed, 187 insertions, 0 deletions
diff --git a/other/shellkit/README b/other/shellkit/README new file mode 100644 index 0000000..1c8b252 --- /dev/null +++ b/other/shellkit/README | |||
| @@ -0,0 +1,187 @@ | |||
| 1 | |||
| 2 | TEAM TESO shellkit - your complete shellcode toolkit | ||
| 3 | ==================================================== | ||
| 4 | preliminary README file | ||
| 5 | |||
| 6 | |||
| 7 | Conditions and rules to be obeyed by the shellcodes | ||
| 8 | =================================================== | ||
| 9 | |||
| 10 | To construct generic shellcodes one has to state the exact details and | ||
| 11 | requirements of each shellcode. The list below is what every shellcode within | ||
| 12 | the shellkit has to obey. | ||
| 13 | |||
| 14 | Conditions the shellcode encounters: | ||
| 15 | |||
| 16 | - Shellcode memory itself is writeable | ||
| 17 | - No register being properly set except the stack pointer | ||
| 18 | |||
| 19 | Requirements to the shellcode: | ||
| 20 | |||
| 21 | - Do not contain NUL (0x00), line-termination (0x0a, 0x0d) and | ||
| 22 | format-directive (0x25 = '%') bytes | ||
| 23 | - Do not expect to be terminated by a NUL ('\0') character | ||
| 24 | - Working on heap and stack (i.e. any writeable and executeable memory) | ||
| 25 | |||
| 26 | Suggestions (i.e. should be ...): | ||
| 27 | |||
| 28 | - Well tested on most common systems to be expected on the | ||
| 29 | architecture the shellcode runs on (i.e Solaris 2.[5678] on sparc, | ||
| 30 | IRIX 5.3, 6.[2345] on mips) | ||
| 31 | - Optimized for (in order of importance): stability, size | ||
| 32 | |||
| 33 | |||
| 34 | Types of shellcodes to create | ||
| 35 | ============================= | ||
| 36 | |||
| 37 | This is a UNIX listing, since most shellcodes are not doable on Windows, so | ||
| 38 | this listing is for Unix derivates only. For the "configureable" values of the | ||
| 39 | shellcodes there are setup functions to set the values within the shellcode. | ||
| 40 | |||
| 41 | The listing is split into three different categories: chainables, local and | ||
| 42 | remote. The chainable codes work as stubs to prepend other shellcodes with. | ||
| 43 | This is done change certain settings in the environment, such as getting rid of | ||
| 44 | chroot, certain uid's and the like. The local shellcodes are for use in locally | ||
| 45 | exploitable vulnerabilities, while the remote shellcodes are designed to assist | ||
| 46 | you with remote exploitation over the network. | ||
| 47 | |||
| 48 | |||
| 49 | Chainables (6 codes) | ||
| 50 | -------------------- | ||
| 51 | Chainable shellcodes should not influence the processing of the following | ||
| 52 | shellcode in violation to the condition above. | ||
| 53 | |||
| 54 | - chrootbreak, which breaks out of a chroot environment if possible on that | ||
| 55 | architecture (using the best and most promising method) | ||
| 56 | - read(fd, behind-myself, len), which reads len bytes from fd behind itself | ||
| 57 | and executes them. on certain architectures special considerations for | ||
| 58 | cache problems have to be obeyed | ||
| 59 | - setreuid(?,?), which sets the (e)uid to a configureable value | ||
| 60 | - setgid(?), which sets the gid to a configurable value | ||
| 61 | - spset, which sets the stackpointer before the shellcode | ||
| 62 | |||
| 63 | - nop shellcode (see below for description) | ||
| 64 | |||
| 65 | The "nop shellcode" is actually a function that will create a variadic amount | ||
| 66 | of nop space which is not just one opcode but a mix. This is done to evade IDS | ||
| 67 | systems. The generated nop-code should behave the same way a normal chainable | ||
| 68 | shellcode would (i.e. not violating the conditions of the shellcode). | ||
| 69 | |||
| 70 | |||
| 71 | Local (2 codes) | ||
| 72 | --------------- | ||
| 73 | - chmod/chown/exit, which chowns and chmods a pathname of your choice, then | ||
| 74 | exits | ||
| 75 | - execve-sh, which executes a /bin/sh | ||
| 76 | - exit, which will just exit with an undetermined exit code | ||
| 77 | |||
| 78 | |||
| 79 | Remote (2 codes) | ||
| 80 | ---------------- | ||
| 81 | - portshell-sh, which listens on a defineable port and executes a /bin/sh | ||
| 82 | once a connection is experienced | ||
| 83 | - connect-sh, which connects to a defineable ip and port and executes a | ||
| 84 | /bin/sh once it is connected | ||
| 85 | |||
| 86 | |||
| 87 | Architectures | ||
| 88 | ============= | ||
| 89 | |||
| 90 | arch os person(s) | ||
| 91 | ------- --------------- ----------------------------------------- | ||
| 92 | HPPA HP-UX caddis | ||
| 93 | MIPS IRIX scut | ||
| 94 | RS6000 AIX edi | ||
| 95 | SPARC Solaris caddis, skyper | ||
| 96 | x86 Solaris plasmoid | ||
| 97 | x86 Windows NT halvar | ||
| 98 | x86 Linux lorian, smiler | ||
| 99 | x86 *BSD dvorak, smiler | ||
| 100 | ------- --------------- ----------------------------------------- | ||
| 101 | |||
| 102 | |||
| 103 | Developing | ||
| 104 | ========== | ||
| 105 | |||
| 106 | Please include all custom build utilities, Makefiles (!) and maybe specific | ||
| 107 | README files in the appropiate directory, so other people can join the fun or | ||
| 108 | modify the codes at source level. | ||
| 109 | |||
| 110 | |||
| 111 | Testing | ||
| 112 | ======= | ||
| 113 | |||
| 114 | The shellcodes have to be tested thoroughly and on as much different systems as | ||
| 115 | possible. | ||
| 116 | |||
| 117 | |||
| 118 | Naming | ||
| 119 | ====== | ||
| 120 | |||
| 121 | Code Strings | ||
| 122 | |||
| 123 | <arch>-<os>-<code> | ||
| 124 | |||
| 125 | arch is one of: | ||
| 126 | |||
| 127 | hppa | ||
| 128 | mips | ||
| 129 | rs6000 | ||
| 130 | sparc | ||
| 131 | x86 | ||
| 132 | |||
| 133 | os is one of: | ||
| 134 | |||
| 135 | aix | ||
| 136 | bsd | ||
| 137 | hpux | ||
| 138 | irix | ||
| 139 | linux | ||
| 140 | solaris | ||
| 141 | windowsnt | ||
| 142 | |||
| 143 | code is one of: | ||
| 144 | |||
| 145 | chmod | ||
| 146 | chroot | ||
| 147 | connectsh | ||
| 148 | execvesh | ||
| 149 | exit | ||
| 150 | portshellsh | ||
| 151 | read | ||
| 152 | setreuid | ||
| 153 | setgid | ||
| 154 | spset | ||
| 155 | |||
| 156 | Example: The portshell shellcode for the MIPS architecture under the IRIX | ||
| 157 | operating system would be identified with "mips-irix-portshellsh" | ||
| 158 | |||
| 159 | |||
| 160 | Additional information | ||
| 161 | ====================== | ||
| 162 | |||
| 163 | Please use the included 'splocoder' utility to dump important system | ||
| 164 | information of the various architectures. There will be a documentation of what | ||
| 165 | the fields mean and how they can be used. Soon. | ||
| 166 | |||
| 167 | |||
| 168 | Credits | ||
| 169 | ======= | ||
| 170 | |||
| 171 | This shellcode toolkit is the result of the hard work of numerous persons, here | ||
| 172 | is a list of the persons involved. | ||
| 173 | |||
| 174 | XXX/TODO: update, add missing persons | ||
| 175 | |||
| 176 | acpizer - splocoder | ||
| 177 | lorian - x86 linux/bsd codes | ||
| 178 | palmers - x86 linux codes | ||
| 179 | scut - mips irix, hppa hpux codes, framework and docs | ||
| 180 | smiler - x86 bsd codes | ||
| 181 | stealth - x86 bsd codes | ||
| 182 | |||
| 183 | |||
| 184 | == | ||
| 185 | vi:fo=tcrq:tw=79: | ||
| 186 | |||
| 187 | |||
