Skip to content

Instantly share code, notes, and snippets.

View cryptrz's full-sized avatar

Franck Ridel cryptrz

View GitHub Profile
X5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*
# Add this at the end of /etc/bash_completion.d/apt-linux-mint
_apt_mint_file_completion()
{
local cur prev
COMPREPLY=()
_get_comp_words_by_ref -n : cur prev
# If the previous word is 'install' and the current word starts with ./ or /
if [[ "$prev" == "install" && ( "$cur" == ./* || "$cur" == /* ) ]]; then
@cryptrz
cryptrz / wordpress-reading-time.md
Created May 21, 2025 16:30
Estimates the reading time for a blog post
add_filter('the_content', function($content) {    if (is_single()) {
        $word_count = str_word_count(strip_tags(get_post_field('post_content', get_the_ID())));
        $reading_time = ceil($word_count / 200); 
        $content = 'Temps de lecture estimé : ' . $reading_time . ' minute(s).' . $content;
    }
    return $content;
});

i3 tweaks

Set up a wallpaper

Debian-based

sudo apt install nitrogen

Fedora-based

@cryptrz
cryptrz / Remove-SysmonOldLogs.ps1
Created April 23, 2025 06:46
Remove Sysmon logs older than 30 days
# Remove-SysmonOldLogs.ps1
$Folder = "C:\Sysmon"
$Days = 30
Get-ChildItem -Path $Folder -Recurse -File | Where-Object {
($_.LastWriteTime -lt (Get-Date).AddDays(-$Days))
} | Remove-Item -Force
@cryptrz
cryptrz / block-twitter-x.sh
Last active March 20, 2025 21:29
Block X formerly Twitter
# Add the content below in your /etc/hosts file on Linux and macOS or C:\Windows\System32\drivers\etc\hosts on Windows
# Block X/Twitter
127.0.0.1 twitter.com
127.0.0.1 *.twitter.com
127.0.0.1 www.twitter.com
127.0.0.1 mobile.twitter.com
127.0.0.1 m.twitter.com
127.0.0.1 api.twitter.com
127.0.0.1 ads.twitter.com
@cryptrz
cryptrz / gist:fdbfdce460ce93d88ff99d6bbb94e4c5
Created June 1, 2024 17:52
AWS Policy - AllowPublicRead
{
"Version": "2008-10-17",
"Statement": [
{
"Sid": "AllowPublicRead",
"Effect": "Allow",
"Principal": {
"AWS": "*"
},
"Action": "s3:GetObject",
@cryptrz
cryptrz / 2-digit-hex.yml
Created July 25, 2023 05:42
2 digit hex numbers
00
01
02
03
04
05
06
07
08
09
#########################################################
https://start.me/p/vjEPvb/thug-bounty # Pentest / Bug bounty bookmarks
https://start.me/p/QRQb0O/trouble-fake # OSINT bookmarks
#########################################################
https://github.com/Hack-with-Github/Awesome-Hacking
https://github.com/sehno/Bug-bounty/blob/master/bugbounty_checklist.md
https://github.com/shieldfy/API-Security-Checklist/blob/master/README.md
https://www.jhaddix.com/post/my-xmind-hunt-template-for-hakluke
https://github.com/Ignitetechnologies/Mindmap
#########################################################