Skip to content

Instantly share code, notes, and snippets.

View teebow1e's full-sized avatar
💖
learning something..

Trung Tran teebow1e

💖
learning something..
View GitHub Profile
@teebow1e
teebow1e / docker-compose.yml
Last active July 24, 2024 18:27
[Project I - SoICT] Docker Compose file for jenkins + sonarqube
version: '3.6'
services:
jenkins:
restart: on-failure
container_name: jenkins
image: jenkins/jenkins:latest
volumes:
- ./jenkins/data:/var/jenkins_home
- ./jenkins/docker-certs:/certs/client
ports:
@teebow1e
teebow1e / script.sh
Created June 20, 2024 17:36
simulate a webserver writing log to a file
#!/bin/bash
SOURCE_FILE="access_log_1000.log"
TARGET_FILE="/mnt/c/Users/teebow1e/IdeaProjects/project1-soict/webserver.log"
#TARGET_FILE="target.log"
CHUNK_SIZE=5
while true; do
chunk=$(head -n "$CHUNK_SIZE" "$SOURCE_FILE")
if [ -n "$chunk" ]; then
@teebow1e
teebow1e / icmp.sh
Last active July 12, 2024 02:49
[Redteam Operation] listen for icmp connection (useful when test RCE)
#!/bin/bash
sudo tcpdump -ni tun0 icmp
# tun0 can be changed with your internet-facing interface
@teebow1e
teebow1e / print.py
Created July 26, 2024 16:59
Cool brute-forcing effect print python
for i in range(1,3000000):
print(f"\r{i}", end="")
@teebow1e
teebow1e / content.md
Created August 8, 2024 16:01
[Golang] Profiling

Cấu hình pprof

  1. Thêm đoạn code sau vào chương trình:
import (
    _ "net/http/pprof"
)

func main() {
    go func() {
 log.Println(http.ListenAndServe("localhost:6060", nil))
@teebow1e
teebow1e / .gitignore
Created August 8, 2024 18:35 — forked from x3rAx/.gitignore
Gitignore with .gitkeep
# +----------------------------+
# | IDE files |
# +----------------------------+
/.idea
# +----------------------------+
# | Vagrant |
# +----------------------------+
/.vagrant
@teebow1e
teebow1e / content.md
Last active August 11, 2024 07:50
[Windows] Setup new Windows machine checklist
@teebow1e
teebow1e / tea.js
Last active August 14, 2024 07:27 — forked from vicmortelmans/gist:1393077
[JavaScript] TEA encryption
// use (16 chars of) 'password' to encrypt 'plaintext'
function encrypt(plaintext, password) {
var v = new Array(2), k = new Array(4), s = "", i;
plaintext = escape(plaintext); // use escape() so only have single-byte chars to encode
// build key directly from 1st 16 chars of password
for (var i=0; i<4; i++) k[i] = Str4ToLong(password.slice(i*4,(i+1)*4));
@teebow1e
teebow1e / content.md
Last active August 28, 2024 16:42
Malware Analysis

Malware Analysis from Attacks

Các repository/nơi tổng hợp link download malware

Các nguồn report/phân tích về các cuộc tấn công (APT)