Skip to content

Instantly share code, notes, and snippets.

@seleniumgists
seleniumgists / file.cpp
Created June 13, 2019 21:41
generated automatically from #selenium on seleniumhq slack
public static ExpectedCondition<Boolean> dropDownToFinishExpanding(WebElementFacade element) {
return new ExpectedCondition<Boolean>() {
@Override
public Boolean apply(WebDriver webDriver) {
element.waitUntilVisible();
int heightBefore = element.getSize().getHeight();
sleep(50);
int heightAfter = element.getSize().getHeight();
return (heightBefore == heightAfter && heightAfter > 0);
}
@NickCraver
NickCraver / Windows10-Setup.ps1
Last active July 5, 2024 17:09
(In Progress) PowerShell Script I use to customize my machines in the same way for privacy, search, UI, etc.
##################
# Privacy Settings
##################
# Privacy: Let apps use my advertising ID: Disable
Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo -Name Enabled -Type DWord -Value 0
# To Restore:
#Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo -Name Enabled -Type DWord -Value 1
# Privacy: SmartScreen Filter for Store Apps: Disable
Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AppHost -Name EnableWebContentEvaluation -Type DWord -Value 0
@binkybear
binkybear / gist:fa5dff0ebe263c94b1ec
Last active May 24, 2018 01:46
Passive Scanner (for Nethunter)
#!/bin/bash
#
# Passively scan for targets using tshark to capture pcap
# then parse out pcap for interesting activity/clients.
# Order: tshark (capture), p0f (fingerprint), dsniff (plaintext),
# tcptrace (parse ip src > ip dst)
#
# + Dependencies tshark, tcptrace, dsniff
#
# + To run and capture traffic for five minutes:
// XPath CheatSheet
// To test XPath in your Chrome Debugger: $x('/html/body')
// http://www.jittuu.com/2012/2/14/Testing-XPath-In-Chrome/
// 0. XPath Examples.
// More: http://xpath.alephzarro.com/content/cheatsheet.html
'//hr[@class="edge" and position()=1]' // every first hr of 'edge' class
@rtt
rtt / tinder-api-documentation.md
Last active June 21, 2024 04:19
Tinder API Documentation

Tinder API documentation

Note: this was written in April/May 2014 and the API may has definitely changed since. I have nothing to do with Tinder, nor its API, and I do not offer any support for anything you may build on top of this. Proceed with caution

http://rsty.org/

I've sniffed most of the Tinder API to see how it works. You can use this to create bots (etc) very trivially. Some example python bot code is here -> https://gist.github.com/rtt/5a2e0cfa638c938cca59 (horribly quick and dirty, you've been warned!)

@jonlabelle
jonlabelle / aspdotnet-razor-syntax-reference.md
Last active November 11, 2022 15:48
ASP.NET Razor Syntax Reference

ASP.NET Razor Syntax Reference

Code Block

@{
    int x = 123;
    string y = "because.";
}

Expression (Html Encoded)