- Install GPG4Win.
- Start up Kleopatra (a UI tool from 1) and make sure your YubiKey is loaded there.
- You can also add GPG4Win to Startup folder using a link with this Target:
This will only load the agent at Startup, and you won't be bothered by any UI or tray agent."C:\Program Files (x86)\GnuPG\bin\gpg-connect-agent.exe" /bye
- You can also add GPG4Win to Startup folder using a link with this Target:
- Download wsl2-ssh-pageant into your Windows
%userprofile%/.ssh
directory (Windows dir is important for performance).
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 | |
# Thanks to MattJ at: | |
# http://www.brassmill.net/2015/10/using-the-aws-cli-with-roles-security-token-service-and-mfa/ | |
# | |
# User must have 'iam:GetUser' permission on themselves that doesn't require MFA | |
[ -z $1 ] && echo "Please enter your MFA code" && exit 1 | |
user=$(aws iam get-user \ |
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
/* This script auto-generates a Google OAuth token from a Service Account key, | |
* and stores that token in accessToken variable in Postman. | |
* | |
* Prior to invoking it, please paste the contents of the key JSON | |
* into serviceAccountKey variable in a Postman environment. | |
* | |
* Then, paste the script into the "Pre-request Script" section | |
* of a Postman request or collection. | |
* | |
* The script will cache and reuse the token until it's within |
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
// ... other dependencies ... | |
import com.google.api.core.ApiService; | |
import com.google.common.util.concurrent.MoreExecutors; | |
import com.google.cloud.pubsub.v1.MessageReceiver; | |
import com.google.cloud.pubsub.v1.Subscriber; | |
import com.google.pubsub.v1.Subscription; | |
import org.springframework.stereotype.Service; |
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
// http://www.olark.com/spw/2011/08/you-can-list-a-directory-with-8-million-files-but-not-with-ls/ | |
#define _GNU_SOURCE | |
#include <dirent.h> /* Defines DT_* constants */ | |
#include <fcntl.h> | |
#include <stdio.h> | |
#include <string.h> | |
#include <unistd.h> | |
#include <stdlib.h> | |
#include <sys/stat.h> | |
#include <sys/syscall.h> |
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
{% set PROJECT = env['project'] %} | |
{% set REGION = properties['region'] | default('us-east1') %} | |
{% set PARENT = 'projects/' + PROJECT + '/locations/' + REGION %} | |
{% set PREFIX = env['deployment'] %} | |
{% set CLOUDRUN_TYPE_PROVIDER = PREFIX + '-provider' %} | |
{% set CLOUDRUN_SERVICE_TYPE = PROJECT + '/' + CLOUDRUN_TYPE_PROVIDER + ':projects.locations.services' %} |
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
// one can also use Google Cloud Firestore library, | |
// with a slight change in semantics | |
import { firestore } from 'firebase-admin'; | |
import { EventContext, runWith } from 'firebase-functions'; | |
import { promisify } from 'util'; | |
const eventCollection = 'function-events'; | |
enum EventStatus { | |
RUNNING = 'running', |
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 | |
set -euo pipefail | |
# define GCP project and GCS bucket backend for Terraform state | |
GCP_PROJECT="$1" | |
BACKEND_BUCKET="${2:-${GCP_PROJECT}-terraform}" | |
# create versioned bucket if it doesn't exist, skip otherwise | |
if gsutil mb -p "${GCP_PROJECT}" "gs://${BACKEND_BUCKET}" ; then |
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
import hashlib | |
import hmac | |
import os | |
from time import time | |
from flask import Request, abort | |
SLACK_SIGNING_SECRET = os.environ['SLACK_SIGNING_SECRET'] |
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
$ trufflehog filesystem --directory . --trace | |
DEBU[0000] running version dev | |
DEBU[0000] running version dev | |
DEBU[0000] running with up to 32 workers | |
DEBU[0000] loaded 2 decoders | |
DEBU[0000] loaded 694 detectors total, 694 with verification enabled. 0 with verification disabled | |
🐷🔑🐷 TruffleHog. Unearth your secrets. 🐷🔑🐷 | |
Found unverified result 🐷🔑❓ | |
Detector Type: AWS |
OlderNewer