Skip to content

Instantly share code, notes, and snippets.

View ferr0's full-sized avatar

Alexander ferr0

View GitHub Profile
@cristaloleg
cristaloleg / golangci.yaml
Created March 28, 2023 07:01
Go linters configuration, the right version.
# See: https://olegk.dev/go-linters-configuration-the-right-version
run:
# Depends on your hardware, my laptop can survive 8 threads.
concurrency: 8
# I really care about the result, so I'm fine to wait for it.
timeout: 30m
# Fail if the error was met.
@aliforever
aliforever / main.go
Created November 12, 2021 12:45
telegram-bot-api pagination example
package main
import (
"fmt"
"strconv"
"strings"
tgbotapi "github.com/go-telegram-bot-api/telegram-bot-api"
)
@oleksis
oleksis / Compile Mainline Kernel (5.15.0) from WSL2.md
Last active June 8, 2024 16:42
Steps for compile Mainline Kernel Linux using WSL2

Compile Mainline Kernel for WSL2

Steps for compile Kernel Linux 5.15.0

Actual Kernel

$ uname -a
Linux DESKTOP-ID 4.19.128-microsoft-standard #1 SMP Tue Jun 23 12:58:10 UTC 2020 x86_64 GNU/Linux

Work Dir linux

Tcpdump is a CLI tool to capture raw network packets. This is useful for various forms of network troubleshooting. This cheat sheet covers all the basic and advanced options for tcpdump.

Tcpdump cheat sheet

how-to-use-tcpdump

Tcpdump command is a famous network packet analyzing tool that is used to display TCP\IP & other network packets being transmitted over the network attached to the system on which tcpdump has been installed. Tcpdump uses libpcap library to capture the network packets & is available on almost all Linux/Unix flavors.

Capture ICMP Packets With Tcpdump

@maratori
maratori / .golangci.yml
Last active June 18, 2024 20:50
Golden config for golangci-lint
# This code is licensed under the terms of the MIT license https://opensource.org/license/mit
# Copyright (c) 2021 Marat Reymers
## Golden config for golangci-lint v1.59.1
#
# This is the best config for golangci-lint based on my experience and opinion.
# It is very strict, but not extremely strict.
# Feel free to adapt and change it for your needs.
run:

Awesome Go

Build Status Awesome Slack Widget Netlify Status

Sponsorships

Digital Ocean

We have no monthly cost, but we have employees working hard to maintain the Awesome Go, with money raised we can repay the effort of each person involved! All billing and distribution will be open to the entire community.

A cura

@UnknownDoggo
UnknownDoggo / nmap-snippets.md
Last active November 24, 2020 11:54
NMap Things! #nmap #cheat-sheet #scan

OCP 4.2/4.3 All-In-One (UPI mode)

This document assume reader is familiar with the OCP4x installation process.

Before Deployment

  • Setup the install-config.yaml to deploy a single master and no workers
    apiVersion: v1
    baseDomain: example.com
    
@coltenkrauter
coltenkrauter / fix-wsl2-dns-resolution
Last active June 13, 2024 12:53
Fix DNS resolution in WSL2
More recent resolution:
1. cd ~/../../etc (go to etc folder in WSL).
2. echo "[network]" | sudo tee wsl.conf (Create wsl.conf file and add the first line).
3. echo "generateResolvConf = false" | sudo tee -a wsl.conf (Append wsl.conf the next line).
4. wsl --terminate Debian (Terminate WSL in Windows cmd, in case is Ubuntu not Debian).
5. cd ~/../../etc (go to etc folder in WSL).
6. sudo rm -Rf resolv.conf (Delete the resolv.conf file).
7. In windows cmd, ps or terminal with the vpn connected do: Get-NetIPInterface or ipconfig /all for get the dns primary and
secondary.
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
https://www.wireshark.org/docs/dfref/ #Display Filter Reference
-----------------------------------------------------------1-----------------------------------------------1-------------------------------------------------------------------------
#Bing
Step-by-step instructions to decrypt TLS traffic from Chrome or Firefox in Wireshark:
https://wiki.wireshark.org/TLS.
How to decrypt TLS traffic in Wireshark
https://www.packetsafari.com/blog/2022/10/07/wireshark-decryption/