yum install wget make gcc net-snmp net-snmp-utils
cd /usr/local/src
wget http://downloads.sourceforge.net/project/snmptt/snmptt/snmptt_1.4/snmptt_1.4.tgz
tar xfz snmptt_*.tgz
snmp_*
cp -rv snmptt snmpttconvert snmpttconvertmib snmptthandler-embedded /usr/sbin/
This file contains 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/perl -w | |
# | |
# LED Wifi control script for MiLight, EasyBulb, iBulb, LinkUP, Kepsun | |
# ==================================================================== | |
# | |
# | |
# Copyright (C) 2013, Julian Pawlowski <julian.pawlowski@gmail.com> | |
# All rights reserved. | |
# | |
# License: Simplified BSD / FreeBSD License |
This file contains 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/sh | |
NAME='John Doe' | |
EMAIL='jdo@example.com' | |
export GNUPGHOME="$(mktemp -d)" | |
cat >$TMPDIR/gpg-gen.tmpl <<EOF | |
%echo Generating an OpenPGP key | |
Key-Type: eddsa | |
Key-Curve: ed25519 |
This file contains 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
<# | |
.SYNOPSIS | |
Dynamic Multi-Platform PowerShell Profile Loader | |
.DESCRIPTION | |
Safe this script named 'profile.ps1' in either $PROFILE.AllUsersAllHosts or | |
$PROFILE.CurrentUserAllHosts. | |
(see: https://docs.microsoft.com/powershell/module/microsoft.powershell.core/about/about_profiles#the-profile-variable) | |
It will automatically create a directory structure for every PS host | |
application, platform and PowerShell edition you use and replicate itself as |
Wer bei verschiedenen Reverse Proxy Aktivitäten auf seinem Uberspace mit Apache auf Grenzen stößt, kann HAproxy installieren.
Ähnlich wie Pound ist es DASein Swiss Army Knife für alle HTTP, HTTPS und TCP Aktivitäten. Man kann sehr granular auf Layer 3-7 beeinflussen, wie Daten an andere Server und Dienste weitergeschleust werden sollen.
Ich benötigte HAproxy, um eine Website von einem externen Server via TLS gesichert per Uberspace verfügbar zu machen, also ein recht simles Szenario.
This file contains 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
{ | |
"Condition statement": { | |
"prefix": "cond", | |
"body": [ | |
"${_} { ${0}; break }" | |
], | |
"description": "Switch condition statement" | |
}, | |
"Condition single quoted string statement": { |
This file contains 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 | |
# | |
# This Script creates the following files to be used for | |
# Zabbix SNMP and SNMP trap integration: | |
# | |
# /etc/snmp/snmp.conf | |
# /etc/snmp/snmptt.conf.VENDOR | |
# Symlink vendor specific MIB files from | |
# $MIBS_VENDORS to $MIBS | |
# |
echo "\$ModLoad imudp" > /etc/rsyslog.d/server.conf
echo "\$UDPServerRun 514" >> /etc/rsyslog.d/server.conf
echo "\$ModLoad imtcp" >> /etc/rsyslog.d/server.conf
echo "\$InputTCPServerRun 514" >> /etc/rsyslog.d/server.conf
echo "\$PreserveFQDN on" >> /etc/rsyslog.d/server.conf
yum -y install rsyslog-gnutls rsyslog-mysql rsyslog-crypto
This file contains 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 | |
# | |
# see https://stribika.github.io/2015/01/04/secure-secure-shell.html | |
SSHD_VERSION=`/usr/sbin/sshd -v 2>&1 | grep OpenSSH | cut -d " " -f1 | cut -d "_" -f2 | cut -d"." -f2 | cut -d"p" -f1` | |
cat /etc/ssh/sshd_config | grep -v "KexAlgorithms" | grep -v "Ciphers" | grep -v "MACs" | grep -v "github.com" > /etc/ssh/sshd_config.new | |
cat /etc/ssh/ssh_config | grep -v "KexAlgorithms" | grep -v "Ciphers" | grep -v "MACs" | grep -v "github.com" > /etc/ssh/ssh_config.new | |
if [ "${SSHD_VERSION}" != "0" ]; then | |
# better algorithms only available on newer OpenSSH versions | |
echo "KexAlgorithms curve25519-sha256@libssh.org,diffie-hellman-group-exchange-sha256" >> /etc/ssh/sshd_config.new |