Skip to content

Instantly share code, notes, and snippets.

View ChlodAlejandro's full-sized avatar
🐢
adoring this turtle

Chlod Aidan Alejandro ChlodAlejandro

🐢
adoring this turtle
View GitHub Profile
@Mrfiregem
Mrfiregem / meme-text.sh
Last active October 7, 2023 04:14
A bash script to add meme text to a video file using ffmpeg
#!/usr/bin/env bash
# Initialize variables to customize output
: "${FFILE:="${HOME}/.fonts/i/impact.ttf"}" # Let user choose font file
: "${FSIZE:=72}" # Let user choose font size in px
: "${BSIZE:=5}" # Let user choose stroke size in px
: "${OFFSET:='(h*0.05)'}" # Let user choose text offset in px
# TTEXT - Text to display at the top of the image
# BTEXT - Text to display at the bottom of the image
# Exit value index:
@pm-hwks
pm-hwks / netcat.sh
Created August 21, 2019 07:03
[Netcat network test] Netcat commands to test bandwidth between 2 linux servers #netcat #perf-test #linux #network
## Netcat server command
nc -l <unused port # > /dev/null
eg:
nc -l 1122 > /dev/null
## Netcat Client command
dd if=/dev/zero bs=9100004096 count=1 | nc <netcat server> <netcat port>
eg:
dd if=/dev/zero bs=9100004096 count=1 | nc 10.0.1.251 1122
@siwalikm
siwalikm / aes-256-cbc.js
Last active July 23, 2024 02:26
AES-256-CBC implementation in nodeJS with built-in Crypto library
'use strict';
const crypto = require('crypto');
const ENC_KEY = "bf3c199c2470cb477d907b1e0917c17b"; // set random encryption key
const IV = "5183666c72eec9e4"; // set random initialisation vector
// ENC_KEY and IV can be generated as crypto.randomBytes(32).toString('hex');
const phrase = "who let the dogs out";
var encrypt = ((val) => {
@KK4TEE
KK4TEE / first.ks
Last active September 18, 2023 05:30
This program for the Kerbal Space Program mod kOS launches a ship from the KSC and flies it into orbit
//first.ks
// This program launches a ship from the KSC and flies it into orbit
//Set the ship to a known configuration
SAS off.
RCS on.
lights on.
lock throttle to 0. //Throttle is a decimal from 0.0 to 1.0
gear off.
@CarlEkerot
CarlEkerot / FileClient.java
Created May 14, 2012 10:43
Simple java file transfer
package client;
import java.io.DataOutputStream;
import java.io.FileInputStream;
import java.io.IOException;
import java.net.Socket;
public class FileClient {
private Socket s;