Skip to content

Instantly share code, notes, and snippets.

View marvin-marvin's full-sized avatar
⌨️
https://gist.github.com/marvin-marvin

Marvin marvin-marvin

⌨️
https://gist.github.com/marvin-marvin
View GitHub Profile
#
# WARNING: heavily refactored in 0.9.0 release. Please review and
# customize settings for your setup.
#
# Changes: in most of the cases you should not modify this
# file, but provide customizations in jail.local file,
# or separate .conf files under jail.d/ directory, e.g.:
#
# HOW TO ACTIVATE JAILS:
#
@marvin-marvin
marvin-marvin / ntp.conf
Last active July 21, 2020 19:18
ntp.conf
# For more information about this file, see the man pages
# ntp.conf(5), ntp_acc(5), ntp_auth(5), ntp_clock(5), ntp_misc(5), ntp_mon(5).
driftfile /var/lib/ntp/drift
# Permit time synchronization with our time source, but do not
# permit the source to query or modify the service on this system.
restrict default nomodify notrap nopeer noquery
# Permit all access over the loopback interface. This could
@marvin-marvin
marvin-marvin / selinux_config.txt
Last active May 5, 2019 08:38
selinux config
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of three two values:
# targeted - Targeted processes are protected,
# minimum - Modification of targeted policy. Only selected processes are protected.
@marvin-marvin
marvin-marvin / sshd_config.txt
Last active January 21, 2021 18:58
sshd config
# $OpenBSD: sshd_config,v 1.93 2014/01/10 05:59:19 djm Exp $
# This is the sshd server system-wide configuration file. See
# sshd_config(5) for more information.
# This sshd was compiled with PATH=/usr/local/bin:/usr/bin
# The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented. Uncommented options override the
@marvin-marvin
marvin-marvin / ufw.conf
Last active May 5, 2019 11:44
ufw ssh fail2ban config
[Definition]
actionstart =
actionstop =
actioncheck =
actionban = ufw insert 1 deny from <ip> to any app OpenSSH
actionunban = ufw delete deny from <ip> to any app OpenSSH
@marvin-marvin
marvin-marvin / yum-cron.conf
Last active May 5, 2019 08:38
yum cron config
[commands]
# What kind of update to use:
# default = yum upgrade
# security = yum --security upgrade
# security-severity:Critical = yum --sec-severity=Critical upgrade
# minimal = yum --bugfix update-minimal
# minimal-security = yum --security update-minimal
# minimal-security-severity:Critical = --sec-severity=Critical update-minimal
update_cmd = security
@marvin-marvin
marvin-marvin / crontab.txt
Last active September 12, 2021 11:04
crontab
##### Crontab
#####
# don't forget to ln -s wget to path
#####
# ENV
SHELL=/bin/bash
PATH=/sbin:/bin:/usr/sbin:/usr/bin
MAILTO=root
@marvin-marvin
marvin-marvin / git_cheatsheet.txt
Last active July 22, 2020 11:15
git cheatsheet
# set repo in folder
git remote add origin https://github.com/marvinmarvink/bash-acc.git
git remote add origin git@github.com:marvin-marvin/bash-keys.git
# modify, push to github
git add FILE or git add -A
git commit -m "bash bamm"
git push
# Options for ntpdate
OPTIONS="-p 2"
# Set to 'yes' to sync hw clock after successful ntpdate
SYNC_HWCLOCK=yes
@marvin-marvin
marvin-marvin / cipher_check.sh
Last active July 26, 2019 10:46
ssl cipher check
###
# please test against the LB endpoint and a node
#syntax: ./cipher_check.sh <s3-endpoint>:443
#syntax: ./cipher_check.sh <node>:443
###
#!/usr/bin/env bash
# OpenSSL requires the port number.