miscellaneous-tricks.md (1190B)
1 --- 2 title: "Miscellaneous & Tricks" 3 section: "Cheatsheets" 4 sectionSlug: "cheatsheets" 5 sourcePath: "docs/cheatsheets/miscellaneous-tricks.md" 6 sourceUrl: "https://github.com/swisskyrepo/InternalAllTheThings/blob/203bb0c0b290/docs/cheatsheets/miscellaneous-tricks.md" 7 sha: "203bb0c0b290" 8 isIndex: false 9 --- 10 11 # Miscellaneous & Tricks 12 13 All the tricks that couldn't be classified somewhere else. 14 15 ## Send Messages to Other Users 16 17 * Windows 18 19 ```powershell 20 PS C:\> msg Swissky /SERVER:CRASHLAB "Stop rebooting the XXXX service !" 21 PS C:\> msg * /V /W /SERVER:CRASHLAB "Hello all !" 22 ``` 23 24 * Linux 25 26 ```powershell 27 wall "Stop messing with the XXX service !" 28 wall -n "System will go down for 2 hours maintenance at 13:00 PM" # "-n" only for root 29 who 30 write root pts/2 # press Ctrl+D after typing the message. 31 ``` 32 33 ## NetExec Credential Database 34 35 ```ps1 36 nxcdb (default) > workspace create test 37 nxcdb (test) > workspace default 38 nxcdb (test) > proto smb 39 nxcdb (test)(smb) > creds 40 nxcdb (test)(smb) > export creds csv /tmp/creds 41 ``` 42 43 NetExec workspaces 44 45 ```ps1 46 # get current workspace 47 poetry run nxcdb -gw 48 49 # create workspace 50 poetry run nxcdb -cw testing 51 52 # set workspace 53 poetry run nxcdb -sw testing 54 ```