Skip to content

Instantly share code, notes, and snippets.

@e-cite
e-cite / yubikey-ssh-authentication.md
Last active July 29, 2025 08:49
Yubikey SSH authentication

Authenticate to OpenSSH-Server with either public key or with YubiKey OTP + password

When you have access to your private key file, use it for quick login. When you are on the go, use your Yubikey OTP and your publickey or .

Tutorial: https://developers.yubico.com/yubico-pam/YubiKey_and_SSH_via_PAM.html

  1. Install yubico pam module:
    sudo apt-get install libpam-yubico
    
@e-cite
e-cite / IAMRole-VMOperator.json
Created December 6, 2020 13:32
Azure IAM Role "VM operator" (Only start and stop VM)
{
"Name": "VM Operator",
"IsCustom": true,
"Description": "Can start, restart and stop (deallocate) virtual machines.",
"Actions": [
"Microsoft.Compute/*/read",
"Microsoft.Compute/virtualMachines/start/action",
"Microsoft.Compute/virtualMachines/restart/action",
"Microsoft.Compute/virtualMachines/deallocate/action"
],
@e-cite
e-cite / kvm-installation.md
Last active October 4, 2025 21:13
Debian KVM installation tutorial

Debian KVM installation tutorial

https://wiki.debian.org/KVM

  1. Update system, install KVM (server without graphical tools) and additional tools
    sudo apt-get update && sudo apt-get dist-upgrade
    sudo apt-get install --no-install-recommends qemu-system libvirt-clients libvirt-daemon-system
    sudo apt-get install qemu-utils dnsmasq-base bridge-utils iptables netcat-openbsd
    sudo apt-get install ovmf  # For UEFI-Support in VMs (Aber aufgrund eines Bugs sind mit UEFI-VMs keine Snapshots möglich!)
    sudo apt-get install qemu-system-modules-spice  # Falls oben mit --no-install-recommends installiert wurde, muss ab Debian Trixie dieses Paket mit installiert werden, damit spice-Grafikausgabe möglich ist.
    
@e-cite
e-cite / docker-installation.md
Last active May 22, 2024 11:47
Debian Docker installation tutorial

Debian Docker installation tutorial

https://docs.docker.com/engine/install/debian/

  1. Remove old docker, update and install requirements
    sudo apt-get remove docker docker-engine docker.io containerd runc
    sudo apt-get update
    sudo apt-get install \
        apt-transport-https \
        ca-certificates \
        curl \
    
@e-cite
e-cite / wiki_industrielle-bussysteme.md
Created July 7, 2021 12:49
Wiki: Industrielle Bussysteme

Bussysteme

Verbindungstechniken

Um dezentrale Feldgeräte (Sensoren und Aktoren) anzusteuern gibt es verschiedene Verbindungstechniken:

  • Konventionelle Verdrahtung
    • Direkte Verdrahtung von der SPS zu jedem Bauelement im Feld
    • Eine Leitung je Feldgerät erfordert einen hohen Ressourcenbedarf
    • Unflexibel bei Änderungen
    • Herausforderungen bei Analogsignalen (Spannungsabfall proportional zur Leitungslänge)
  • Dezentrale Peripherie
  • Serielles Bussystem zwischen Zentraleinheit (SPS) und mehreren Remote-IO-Einheiten
@e-cite
e-cite / wiki_industrial-ethernet.md
Created July 7, 2021 16:25
Wiki: Industrial Ethernet

Industrial Ethernet

Grundlagen

Industrial Ethernet dient dazu, den vorhandenen Ethernet-Standard um die Anforderungen aus der Prozessdatenkommunikation zu erweitern.

Es sind insbesondere folgende Anforderungen zu berücksichtigen:

  • Industrielle Umgebungsbedingungen (Temperaturbereiche; Beständigkeit gegen Öl, Säuren, etc.; Vibrationen; EMV)
  • Schutzarten (IPxx)
  • Hutschienenmontage
  • Spannungsversorgung, typ. 24 V DC
  • Topologien (Häufig Ring, eher selten Stern bzw. Baum)
@e-cite
e-cite / wiki_industrielle-netzwerk-protokolle.md
Created July 7, 2021 16:30
Wiki: Industrielle Netzwerk-Protokolle
@e-cite
e-cite / debian-vm-settings.md
Last active May 6, 2023 18:10
Debian VM settings
  • Locales
  • Timezone
  • Hostname
  • Domainname
  • apt-get install open-vm-tools open-vm-tools-desktop terminator wipe virt-manager ssh-askpass dnsutils auto-apt-proxy
  • apt-get install firmware-linux-nonfree xserver-xorg-input-synaptics
  • Mac Book Pro: add non-free to packet sources
  • Install VS Code
  • Einstellungen / Session and Startup / Application Autostart / Activate SSH Key Agent (GNOME Keyring: SSH Agent)
  • Einstellungen / Erscheinungsbild / Schriften / DPI-Wert auf 96
@e-cite
e-cite / LGT92-v1.6.4_decoder_TTN_ecite.js
Last active January 9, 2022 17:05
Dragino TTN Decoders
// From: https://www.dragino.com/downloads/index.php?dir=LGT_92/Decoder/
// But roll, pitch and altitude are wrong due to <<24>>16.
// Better: <<8
//The function is :
function Decoder(bytes, port) {
// Decode an uplink message from a buffer
// (array) of bytes to an object of fields.
var latitude;//gps latitude,units: °
@e-cite
e-cite / words.md
Created April 12, 2022 18:43
Mnemonic Encoding Word List

Mnemonic Encoding Word List

http://web.archive.org/web/20090918202746/http://tothink.com/mnemonic/wordlist.html

  • The wordlist contains 1626 words.
  • All words are between 4 and 7 letters long.
  • No word in the list is a prefix of another word (e.g. visit, visitor).
  • Five letter prefixes of words are sufficient to be unique.
  • The words should be usable by people all over the world. The list is far from perfect in that respect. It is heavily biased towards western culture and English in particular. The international vocabulary is simply not big enough. One can argue that even words like "hotel" or "radio" are not truly international. You will find many English words in the list but I have tried to limit them to words that are part of a beginner's vocabulary or words that have close relatives in other european languages. In some cases a word has a different meaning in another language or is pronounced very differently but for the purpose of the encoding it is still ok - I assume that when the encoding is