Skip to content

Instantly share code, notes, and snippets.

View realdimas's full-sized avatar

Dima Scherbakov realdimas

View GitHub Profile
@sm-Fifteen
sm-Fifteen / whats_a_yubikey.md
Last active May 7, 2024 22:40
"What the heck is a Yubikey and why did I buy one?": A user guide

"What the heck is a Yubikey and why did I buy one?": A user guide

(EDIT: Besides Reddit, I've also put this up on Github Gist)

So while looking for information on security keys before getting one myself, I got very confused reading about all the different modes and advertised features of Yubikeys and other similar dongles. The official documentation tends to be surprisingly convoluted at times, weirdly organized and oddly shy about a few of the limitations of these keys (which I'm making a point of putting front and center). Now that I have one, I decided to write down everything I figured out in order to help myself (and hopefully some other people reading this) make sense of all this.

Since I'm partly writing these notes for myself, there might be some back and forth between "exp

@vasiasan
vasiasan / publicGoogleGroupsMembersExport.js
Created May 28, 2019 09:29
Export from google groups by jquery
// Extracting google groups members at this site
// https://groups.google.com/forum/#!myforums
// execute in console the snippet
javascript: (function(e, s) {
e.src = s;
e.onload = function() {
var output = [];
jQuery.noConflict();
let groups = jQuery("a:contains(Manage members)")
groups.each (
@lizthegrey
lizthegrey / attributes.rb
Last active February 24, 2024 14:11
Hardening SSH with 2fa
default['sshd']['sshd_config']['AuthenticationMethods'] = 'publickey,keyboard-interactive:pam'
default['sshd']['sshd_config']['ChallengeResponseAuthentication'] = 'yes'
default['sshd']['sshd_config']['PasswordAuthentication'] = 'no'
@StevenACoffman
StevenACoffman / a node-problem-detector Readme.md
Last active March 14, 2024 16:58
Draino and Node-problem-detector

Our remedy system looks like:

  1. Detect permanent node problems and set Node Conditions using the Node Problem Detector.
  2. Configure Draino to cordon and drain nodes when they exhibit the NPD's KernelDeadlock condition, or a variant of KernelDeadlock we call VolumeTaskHung.
  3. Let the Cluster Autoscaler scale down underutilised nodes, including the nodes Draino has drained.

Note: Draino will log nothing, and export no metrics until it actually drains a node.

Once the Descheduler supports descheduling pods based on taints, Draino could be replaced by the Descheduler running in combination with the scheduler's TaintNodesByCondition functionality. See kubernetes-sigs/descheduler#131

@wyatt8740
wyatt8740 / banish-annoyances.sh
Created November 30, 2018 03:00
Hide annoying notification bubble from OS X Mojave preferences app icon
#! /bin/bash
# clear the notification badge on the settings app in OS X Mojave (or MacOS, whatever)
# until next update check. It was bothering me too much to be allowed to live.
# this was really annoying to find, so I'm putting it here for the future.
defaults write com.apple.systempreferences AttentionPrefBundleIDs 0
# the following may not be necessary:
sudo defaults write /Library/Preferences/com.apple.SoftwareUpdate.plist LastUpdatesAvailable 0
sudo defaults write /Library/Preferences/com.apple.SoftwareUpdate.plist LastRecommendedUpdatesAvailable 0
sudo defaults delete /Library/Preferences/com.apple.SoftwareUpdate.plist RecommendedUpdates
@oliveratgithub
oliveratgithub / autoexec.cfg
Last active September 11, 2021 09:23
ioQuake3 – custom high definition configurations for best visual quality (Quake 3, Quake III Arena). This config file is featured on https://swissmacuser.ch/how-you-want-to-run-quake-iii-arena-in-2018-with-high-definition-graphics-120-fps-on-5k-resolution/
seta r_mode "-1"
seta r_customwidth "5120"
seta r_customheight "2880"
seta cg_fov "115"
seta cg_gunCorrectFOV "1"
seta cl_renderer "opengl2"
seta r_allowSoftwareGL "0"
seta r_ignoreGLErrors "1"
seta r_smp "1"
seta r_displayrefresh "0"
@mi-lee
mi-lee / unlike-delete-hide-facebook-posts.js
Last active May 9, 2024 01:00
Bulk delete, unlike, hide, or remove Facebook actions (in Activity Feed) by year.
// DISCLAIMER: I'VE ONLY RUN THIS SCRIPT ON MY OWN ACCOUNT ONLY. PROCEED/USE WITH RISK! I MADE THIS SCRIPT IN 20 MINUTES SO BE WARNED!
// On the other hand, I've deleted 50,000 comments in a matter of minutes so it's been pretty damn handy
// 1. Go to Activity feed, like facebook.com/<username>/allactivity
// 2. Navigate to specific section of FB, like "Likes and Reactions" or "Comments",
// like https://www.facebook.com/<username>/allactivity?privacy_source=activity_log&log_filter=cluster_<clusterid>
// 3. Navigate to year that you want to batch delete. You may need to scroll a little bit to let it load
// 4. Once you enter this there's no going back!!
@a7ul
a7ul / jamf.md
Last active March 29, 2024 09:47
removing all restrictions on jamf managed macos device - Provided you have root access.

REMOVE JAMF RESTRICTIONS ON MAC

REMOVE ONLY RESTRICTIONS

sudo jamf removeMDMProfile removes all restrictions

sudo jamf manage brings back all restrictions and profiles

REMOVE ALL RESTRICTIONS AND DISABLE JAMF BINARIES WHILE KEEPING YOUR ACCESS TO VPN AND OTHER SERVICES

sudo jamf removeMDMProfile removes all restrictions

@bobrik
bobrik / README.md
Last active May 7, 2024 12:19
CFS hiccups