# set http proxy
export http_proxy=http://PROXYHOST:PROXYPORT
# set http proxy with user and password
export http_proxy=http://USERNAME:PASSWORD@PROXYHOST:PROXYPORT
# set http proxy with user and password (with special characters)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # List all possible power config GUIDs in Windows | |
| # Run: this-script.ps1 | Out-File powercfg.ps1 | |
| # Then edit and run powercfg.ps1 | |
| # (c) Pekka "raspi" Järvinen 2017 | |
| $powerSettingTable = Get-WmiObject -Namespace root\cimv2\power -Class Win32_PowerSetting | |
| $powerSettingInSubgroubTable = Get-WmiObject -Namespace root\cimv2\power -Class Win32_PowerSettingInSubgroup | |
| Get-WmiObject -Namespace root\cimv2\power -Class Win32_PowerSettingCapabilities | ForEach-Object { | |
| $tmp = $_.ManagedElement |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| from ripe.atlas.cousteau import ( | |
| AtlasResultsRequest | |
| ) | |
| import bz2 | |
| import json | |
| import requests | |
| import sys |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| sudo fdisk -lu /dev/sdb | |
| # Disk /dev/sdb: 14.9Gib, 1593153946 bytes, 31116288 sectors | |
| # Units: sectors of 1 * 512 = 512 bytes | |
| # Secor size (logical/physical): 512 bytes / 512 bytes | |
| # I/O size (minimum/optimal): 512 bytes / 512 bytes | |
| # Disklabel type: dos | |
| # Disk identifier: 0x9c4e41cd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # never use this if you have 32 GB hard drive | |
| # never use this if you mount 2 or more 32GB usb flash card in one time | |
| varvar=`blockdev --getsize64 /dev/sda` | |
| # 32GB == 30765219840 | |
| if [ $varvar -eq 30765219840 ]; then | |
| dd if=disk.img of=/dev/sda bs=4M conv=fsync status=progress | |
| fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # sources.list file for arm cross-development under amd64 | |
| #deb [arch=amd64] cdrom:[Ubuntu 14.04.3 LTS _Trusty Tahr_ - Beta amd64 (20150805)]/ trusty main restricted | |
| deb [arch=armhf] http://ports.ubuntu.com/ trusty main restricted universe multiverse | |
| deb [arch=armhf] http://ports.ubuntu.com/ trusty-security main restricted universe multiverse | |
| deb [arch=armhf] http://ports.ubuntu.com/ trusty-updates main restricted universe multiverse | |
| deb [arch=armhf] http://ports.ubuntu.com/ trusty-backports main restricted universe multiverse | |
| # See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to | |
| # newer versions of the distribution. |
Moved to git repository: https://github.com/denji/golang-tls
# Key considerations for algorithm "RSA" ≥ 2048-bit
openssl genrsa -out server.key 2048
# Key considerations for algorithm "ECDSA" ≥ secp384r1
# List ECDSA the supported curves (openssl ecparam -list_curves)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {"version":1,"resource":"file:///home/user/Documents/pi-v4/home/pi/.bashrc","entries":[{"id":"QPdZ","timestamp":1698983018205}]} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ## Prepare the system | |
| touch /etc/apt/sources.list.d/backports.list | |
| echo "deb http://deb.debian.org/debian buster-backports main" >> /etc/apt/sources.list.d/backports.list | |
| apt update && apt -y upgrade && apt install -y build-essential git checkinstall | |
| # Clone the Source | |
| git clone https://github.com/openssl/openssl.git | |
| # Compile, test and install manually | |
| cd openssl |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function FindProxyForURL(url, host) { | |
| var useSocks = ["imgur.com"]; | |
| for (var i= 0; i < useSocks.length; i++) { | |
| if (shExpMatch(host, useSocks[i])) { | |
| return "SOCKS localhost:9999"; | |
| } | |
| } | |
| return "DIRECT"; |