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 bash | |
| # Installs NixOS on a Hetzner server, wiping the server. | |
| # | |
| # This is for a specific server configuration; adjust where needed. | |
| # | |
| # When the script is done, make sure to boot the server from HD, not rescue mode again. | |
| # Explanations: | |
| # |
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
| # To set this up, first get tailscale working in an isolated linux shell: | |
| # 1. sudo systemctl stop tailscaled.service | |
| # 2. tailscaled -port 9993 -state tailscale-luks-setup.state -tun userspace-networking -socket ./tailscaled.sock | |
| # 3. tailscale -socket ./tailscaled.sock up -hostname HOSTNAME-luks | |
| # 4. tailscale -socket ./tailscaled.sock down | |
| # 5. ctrl-c out of tailscaled | |
| # 6 sudo systemctl start tailscaled.service | |
| # | |
| # Then add the .state file to your machine secrets and pass its path as tailscaleStatePath. |
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 | |
| PROJECT=${1:-"$(gcloud config get-value project)"} | |
| REGION=${2:-"us-central1"} | |
| IMAGE="hub.docker.com/_/nginx" | |
| { | |
| gcloud services enable "run.googleapis.com" --project="${PROJECT}" | |
| gcloud auth configure-docker --quiet |
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
| SELECT 'true' AS CVE_2020_0601_patched, | |
| hotfix_id, | |
| description, | |
| caption, | |
| installed_by, | |
| installed_on | |
| FROM patches WHERE hotfix_id IN ( | |
| 'KB4534306', | |
| 'KB4534271', | |
| 'KB4534276', |
- Microsoft disclosed a vulnerability in their monthly Patch Tuesday referenced under CVE-2020-0601.
- The vulnerability was discovered by the U.S. National Security Agency, anounced today (2020-01-14) in their press conference, followed by a blog post and an official security advisory.
- The flaw is located in the "CRYPT32.DLL" file under the C:\Windows\System32\ directory.
- NSA description:
- NSA has discovered a critical vulnerability (CVE-2020-0601) affecting Microsoft Windows® cryptographic functionality.
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
| 1. Install oh-my-zsh | |
| sh -c "$(wget https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O -)" | |
| 2. Clone necessary plugins. | |
| git clone git://github.com/zsh-users/zsh-autosuggestions $ZSH_CUSTOM/plugins/zsh-autosuggestions | |
| git clone https://github.com/zsh-users/zsh-history-substring-search ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-history-substring-search | |
| git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting | |
| 3. Add plugins to ~/.zshrc as | |
| plugins = ( [plugins...] zsh-autosuggestions zsh-history-substring-search zsh-syntax-highlighting) |
All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.
Generally, all APIs that synchronously provide layout metrics will trigger forced reflow / layout. Read on for additional cases and details.
elem.offsetLeft,elem.offsetTop,elem.offsetWidth,elem.offsetHeight,elem.offsetParent
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
| See the bash script below. :) | |
| Tested on debian bookworm-slim (`docker pull debian:bookworm-slim`). | |
| ### Prerequisites | |
| ```bash | |
| apt update | |
| apt install -y build-essential wget bison | |
| ``` |
As configured in my dotfiles.
start new:
tmux
start new with session name:
NewerOlder