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
[prod] | |
aws_secret_access_key = redacted | |
aws_access_key_id = redacted | |
[tf_temp] | |
[tf] | |
credential_process = sh -c 'mfa.sh arn:aws:iam::{account_id}:role/{role} arn:aws:iam::{account_id}:mfa/{mfa_entry} prod 2> $(tty)' |
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
with open("test.bin", mode='rb') as file: | |
encodedData = file.read() | |
offset = 0 | |
objects = [] | |
iteration = 0 | |
while offset < len(encodedData): | |
elementSize = encodedData[offset] | |
offset+=1 |
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
#compile with : g++ -o scan scan.cpp -lbluetooth | |
#include <stdio.h> | |
#include <unistd.h> | |
#include <sys/socket.h> | |
#include <bluetooth/bluetooth.h> | |
#include <bluetooth/rfcomm.h> | |
#include <cerrno> | |
int main(int argc, char **argv) | |
{ |
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
import requests | |
from bs4 import BeautifulSoup | |
s = requests.Session() | |
r = s.get("https://www.kickstarter.com") | |
soup = BeautifulSoup(r.text, 'html.parser') | |
xcsrf = soup.find("meta", {"name": "csrf-token"})["content"] | |
query = """ | |
query GetEndedToLive($slug: String!) { |
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
import requests | |
params = { | |
"text": "", | |
"objectIds": "", | |
"time": "", | |
"geometry": "", | |
"geometryType": "esriGeometryEnvelope", | |
"inSR": "", | |
"spatialRel": "esriSpatialRelIntersects", |
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
var app = require('express')(), | |
passport = require('passport'), | |
GitHubStrategy = require('passport-github').Strategy, | |
mongoose = require('mongoose'), | |
github = require('octonode'), | |
bodyParser = require('body-parser'), | |
session = require('express-session'); | |
var config = { | |
clientID: 'YOUR_CLIENT_ID', |
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
= Introduction to AsciiDoc | |
Doc Writer <doc@example.com> | |
A preface about https://asciidoc.org[AsciiDoc]. | |
== First Section | |
* item 1 | |
* item 2 |
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
import requests | |
import json | |
r = requests.get("https://steamcommunity.com/market/appfilters/730") | |
tags = json.loads(r.text)["facets"]["730_ItemSet"]["tags"] | |
winter_offensive_tag = [ | |
t[0] | |
for t in tags.items() | |
if t[1]["localized_name"] == "The Winter Offensive Collection" |
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
<template> | |
<div :id="editorId" class="editor"> | |
</div> | |
</template> | |
<script> | |
import * as ace from 'brace'; | |
import 'brace/mode/yaml'; | |
import 'brace/theme/monokai'; | |
export default { |
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
mongodump --host [HOST] --username [USER] \ | |
--password [PASSWORD] --db rfp --authenticationDatabase admin \ | |
--readPreference secondary --ssl --sslCAFile rds-combined-ca-bundle.pem --sslAllowInvalidCertificates | |
mongorestore --uri="mongodb://<target_username>:<target_password>@<target_host>/?authSource=admin&replicaSet=rs0" \ | |
--ssl --sslCAFile rds-combined-ca-bundle.pem --sslAllowInvalidCertificates \ | |
--numInsertionWorkersPerCollection 64 dump |