Skip to content

Instantly share code, notes, and snippets.

@abstraction
abstraction / google-dorks
Created February 3, 2020 19:27 — forked from stevenswafford/google-dorks
Listing of a number of useful Google dorks.
" _ _ "
" _ /|| . . ||\ _ "
" ( } \||D ' ' ' C||/ { % "
" | /\__,=_[_] ' . . ' [_]_=,__/\ |"
" |_\_ |----| |----| _/_|"
" | |/ | | | | \| |"
" | /_ | | | | _\ |"
It is all fun and games until someone gets hacked!
@abstraction
abstraction / multi_channel_attribution.sql
Created February 10, 2020 20:13 — forked from markrittman/multi_channel_attribution.sql
Multi-Channel Attribution Standard SQL query for Google BigQuery sourcing session data from Segment and attributed value from operational system
WITH session_attributiON AS
(SELECT *,
CASE WHEN session_id = LAST_VALUE(session_id)
OVER (partitiON by user_id order by session_start_tstamp ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING) THEN 1
ELSE 0
END AS LAST_click_attrib_pct,
CASE WHEN session_id = FIRST_VALUE(session_id)
OVER (partitiON by user_id order by session_start_tstamp ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING) THEN 1
ELSE 0
END AS first_click_attrib_pct,
# arrayDataTypesCheck - check input array data types for every element
# Chuck Norris API
# Loop through nested objects
# Mixin - Object.assign
# Promises (in the dark), thank you Pat Benatar
# Reduce - Using reduce to filter
# Regex - Common
# Rest Operator
# Show more or less, pure JS
# Spread Operator (Okay, Okay, let's keep the juvenile humor down to a minimum).
[
{
"title": "I am a mediocre developer",
"author": "Nikita Sobolev",
"date": "Mar 13 '18",
"tags": [
"#meta",
"#career",
"#beginners",
"#productivity"
@abstraction
abstraction / 1 - myXHR (pre-ES6).js
Created February 11, 2020 09:02
#XMLHttpRequest #AJAX
// ***** myXHR Library - pre-ES6 version ******
var myXHR = (function() {
function myXHR() {}
myXHR.prototype.get = function(url) {
var xhr = new XMLHttpRequest();
xhr.open("GET", url, true);
// old way, replaced by onload
@abstraction
abstraction / Clean-Js-Code.md
Created February 11, 2020 09:02 — forked from prashant1k99/Clean-Js-Code.md
Clean Code Concept for Javascript
@abstraction
abstraction / detect-js-framework.js
Created February 16, 2020 10:51 — forked from rambabusaravanan/detect-js-framework.js
Detect JS Framework used in a Website
// Pase these lines into website's console ( Ctrl/Cmd + Shift + I )
if(!!window.React ||
!!document.querySelector('[data-reactroot], [data-reactid]'))
console.log('React.js');
if(!!window.angular ||
!!document.querySelector('.ng-binding, [ng-app], [data-ng-app], [ng-controller], [data-ng-controller], [ng-repeat], [data-ng-repeat]') ||
!!document.querySelector('script[src*="angular.js"], script[src*="angular.min.js"]'))
console.log('Angular.js');
@abstraction
abstraction / UltimatePiHoleVPN.md
Created February 16, 2020 16:13 — forked from HarvsG/UltimatePiHoleVPN.md
Reminder on how I set up a kickass VPN server with PiHole and encrypted DNS

Initial setup

This is more of a note-to self, but please feel more than free to replicate it.

  1. Follow this PiHole guide:
    • But in the first command replace wget https://git.io/vpn -O openvpn-install.sh with wget https://raw.githubusercontent.com/Angristan/OpenVPN-install/master/openvpn-install.sh -O openvpn-install.sh
    • Stick with the default options unless you know better (or the guide does in the case of tun0 vs eth0)
      • Depending on your privacy concerns and the development status of FTLDNS you may want to opt out of the DNS logging options.
    • Make sure to configure iptables to reload on restart by doing sudo bash -c "iptables-save > /etc/iptables.conf" and then adding iptables-restore < /etc/iptables.conf to /etc/rc.local
  • If doing ho
@abstraction
abstraction / vpn.md
Created February 16, 2020 16:13 — forked from joepie91/vpn.md
Don't use VPN services.

Don't use VPN services.

No, seriously, don't. You're probably reading this because you've asked what VPN service to use, and this is the answer.

Note: The content in this post does not apply to using VPN for their intended purpose; that is, as a virtual private (internal) network. It only applies to using it as a glorified proxy, which is what every third-party "VPN provider" does.

A Russian translation of this article can be found here, contributed by Timur Demin. There's also this article about VPN services, which is honestly better written (and has more cat pictures!) than my article.

Why not?

@abstraction
abstraction / SourceCodeSearchEngines.md
Created February 18, 2020 19:18 — forked from phillipalexander/SourceCodeSearchEngines.md
Source Code Search Engines You Can Use For Programming Projects

Source Code Search Engines

NOTE: This list is almost entirely copy/pasted from THIS awesome article. I've made my own personal edits (adding some additional content) which is why I keep it here.

Every day meanpath crawls over 200 million websites capturing the visible text, HTML source code, CSS and Javascript. This information is used by many companies to monitor the growth of web facing technology.