Skip to content

Instantly share code, notes, and snippets.

@Manouchehri
Manouchehri / isolate.sh
Created September 18, 2021 22:43 — forked from cynecx/isolate.sh
wireguard & netns (crappy)
#!/usr/bin/env bash
set -e -o pipefail
shopt -s extglob
export LC_ALL=C
CONTAINER=""
INTER_GATEWAY="192.168.30.0/24"
INTER_IP_HOST="192.168.30.1/32"
INTER_IP_CONT="192.168.30.2/32"
Aug 18 08:05:12 raspberrypi upslog[868]: 20210818 080512 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 08:05:13 raspberrypi upslog[868]: 20210818 080513 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 08:05:14 raspberrypi upslog[868]: 20210818 080514 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 08:05:15 raspberrypi upslog[868]: 20210818 080515 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 08:05:16 raspberrypi upslog[868]: 20210818 080516 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 08:05:17 raspberrypi upslog[868]: 20210818 080517 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 08:05:18 raspberrypi upslog[868]: 20210818 080518 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 08:05:19 raspberrypi upslog[868]: 20210818 080519 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 08:05:20 raspberrypi upslog[868]: 20210818 080520 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 08:05:21 raspberrypi upslog[868]: 20210818 080521 0 0.0 0 [FSD OB DISCHRG LB] NA NA
Aug 18 06:22:59 raspberrypi upslog[868]: 20210818 062259 1 0.0 4 [FSD OB DISCHRG LB] NA NA
Aug 18 06:23:00 raspberrypi upslog[868]: 20210818 062300 1 0.0 4 [FSD OB DISCHRG LB] NA NA
Aug 18 06:23:01 raspberrypi upslog[868]: 20210818 062301 1 0.0 4 [FSD OB DISCHRG LB] NA NA
Aug 18 06:23:02 raspberrypi upslog[868]: 20210818 062302 1 0.0 4 [FSD OB DISCHRG LB] NA NA
Aug 18 06:23:03 raspberrypi upslog[868]: 20210818 062303 1 0.0 4 [FSD OB DISCHRG LB] NA NA
Aug 18 06:23:04 raspberrypi upslog[868]: 20210818 062304 1 0.0 4 [FSD OB DISCHRG LB] NA NA
Aug 18 06:23:05 raspberrypi upslog[868]: 20210818 062305 1 0.0 4 [FSD OB DISCHRG LB] NA NA
Aug 18 06:23:06 raspberrypi upslog[868]: 20210818 062306 0 0.0 4 [FSD OB DISCHRG LB] NA NA
Aug 18 06:23:07 raspberrypi upslog[868]: 20210818 062307 0 0.0 4 [FSD OB DISCHRG LB] NA NA
Aug 18 06:23:08 raspberrypi upslog[868]: 20210818 062308 0 0.0 4 [FSD OB DISCHRG LB] NA NA
pi@raspberrypi:~ $ upsc logic
Init SSL without certificate database
battery.charge: 0
battery.charge.low: 10
battery.charge.warning: 20
battery.mfr.date: CPS
battery.runtime: 0
battery.runtime.low: 300
battery.type: PbAcid
battery.voltage: 11.6
pi@raspberrypi:~ $ upsc logic
Init SSL without certificate database
battery.charge: 0
battery.charge.low: 10
battery.charge.warning: 20
battery.mfr.date: CPS
battery.runtime: 0
battery.runtime.low: 300
battery.type: PbAcid
battery.voltage: 11.9
pi@raspberrypi:~ $ upsc logic
Init SSL without certificate database
battery.charge: 1
battery.charge.low: 10
battery.charge.warning: 20
battery.mfr.date: CPS
battery.runtime: 171
battery.runtime.low: 300
battery.type: PbAcid
battery.voltage: 12.3
From a4a400549761cba03af4a6a14caeb3785255a1e3 Mon Sep 17 00:00:00 2001
From: Joey Jiao <[email protected]>
Date: Sun, 27 Oct 2019 13:39:43 +0800
Subject: [PATCH] AFL: Enable AFL by global paths
Change-Id: Iede00c60802f7b4856cde6d3b3c27201a68f3e5f
---
android/config.go | 21 +++++++++++++++++++++
android/variable.go | 4 ++++
cc/builder.go | 11 +++++++++++
@Manouchehri
Manouchehri / 1.js
Created April 21, 2021 21:07 — forked from getify/1.js
demonstrating how to use "nodegit" to modify and read from a local bare git repo
/*
NOTE: This code assumes a bare git repo in ./bare-git/,
which should have at least one text file in its root,
named "greetings.txt".
This code updates the contents of a "greetings.txt"
file, and creates a new file called "greetings-XXX.txt"
(with XXX being a random number). It then creates a new
commit for these changes. Finally, it reads and dumps
the new current contents of the repo, file by file.
/**
* A C/C++ preprocessor `#define` directive. For example:
* ```
* #define dave_awesome_level 1337
* ```
*/
class PreprocessorDefine extends PreprocessorDirective, @ppd_define {
override string toString() {
result = "#define " + this.getHead()
Apr 11 06:21:20 ups upslog[960]: 20210411 062120 100 118.0 66 [OL] NA NA
Apr 11 06:21:21 ups upslog[960]: 20210411 062121 100 118.0 66 [OL] NA NA
Apr 11 06:21:22 ups upslog[960]: 20210411 062122 100 118.0 66 [OL] NA NA
Apr 11 06:21:23 ups upslog[960]: 20210411 062123 100 118.0 66 [OL] NA NA
Apr 11 06:21:24 ups upslog[960]: 20210411 062124 100 118.0 66 [OL] NA NA
Apr 11 06:21:25 ups upslog[960]: 20210411 062125 100 118.0 66 [OL] NA NA
Apr 11 06:21:26 ups upslog[960]: 20210411 062126 100 0.0 66 [OL] NA NA
Apr 11 06:21:27 ups upslog[960]: 20210411 062127 100 0.0 66 [OL DISCHRG] NA NA
Apr 11 06:21:28 ups upslog[960]: 20210411 062128 100 119.0 61 [OL DISCHRG] NA NA
Apr 11 06:21:29 ups upslog[960]: 20210411 062129 100 119.0 61 [OL DISCHRG] NA NA