Skip to content

Instantly share code, notes, and snippets.

View Matheus-Garbelini's full-sized avatar
🎯
Focusing

Matheus Eduardo Matheus-Garbelini

🎯
Focusing
View GitHub Profile
#!/usr/bin/env bash
sudo apt install -y build-essential git python3-dev libnl-genl-3-dev bison flex kmod linux-headers-$(uname -r)
sudo python3 -m pip install cmake ninja -U
mkdir -p ~/github && cd ~/github
# Install PF Ring
git clone https://github.com/ntop/PF_RING --depth=1 && cd PF_RING
@Matheus-Garbelini
Matheus-Garbelini / preempt_rt_patch_compile.sh
Last active January 21, 2020 13:52
Create realtime linux kernel (preempt_rt patch)
KERNEL_VER=4.9.115
RT_PATCH_VER=93
CURRENT_KERNEL=`uname -r`
tar -xzvf linux-$KERNEL_VER.tar.gz
cd linux-$KERNEL_VER
gzip -cd ../patch-$KERNEL_VER-rt$RT_PATCH_VER.patch.gz | patch -p1 --verbose
cp /boot/config-$CURRENT_KERNEL .config # get config file from current kernel
make -j9
sudo make modules_install -j9
@Matheus-Garbelini
Matheus-Garbelini / install_openssl_aarch64.sh
Last active October 10, 2023 09:02
Compile and install OpenSSL 1.1.1 for arm64 aarch64 android
wget https://www.openssl.org/source/openssl-1.1.1.tar.gz
tar -xvzf openssl-1.1.1.tar.gz
cd openssl-1.1.1/
./Configure linux-aarch64 --prefix=/usr/local/ssl --openssldir=/usr/local/ssl shared zlib
make -j$(($(nproc)+1))
sudo make install
sudo echo 'LD_LIBRARY_PATH=/usr/local/ssl/lib:${LD_LIBRARY_PATH}' >> /etc/environment
rm openssl-1.1.1.tar.gz
sudo rm openssl-1.1.1 -r
@Matheus-Garbelini
Matheus-Garbelini / esp32_wpa2_enterprise_example.ino
Created September 4, 2019 02:15
ESP32 Wi-Fi WPA2 Enterprise example
#include "esp_wpa2.h"
#include "esp_wifi.h"
#include "esp_wpa2.h"
#include <WiFi.h>
#define EXAMPLE_EAP_METHOD 1
#define EXAMPLE_EAP_ID "matheus_garbelini"
#define EXAMPLE_EAP_USERNAME "matheus_garbelini"
@Matheus-Garbelini
Matheus-Garbelini / esp8266_wpa2_enterprise_example.ino
Last active July 1, 2024 17:33
ESP8266 Wi-Fi WPA2 Enterprise example
#include <ESP8266WiFi.h>
extern "C" {
#include "user_interface.h"
#include "wpa2_enterprise.h"
#include "c_types.h"
}
// SSID to connect to
char ssid[] = "TEST_KRA";