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
function eventSearch(searchQuery="*", searchEvent=false){ | |
var out=Array.from( | |
document.querySelectorAll(searchQuery) | |
); | |
out=out.map(function(element){ | |
const events=getEventListeners(element); | |
if(Object.keys(events).length!==0&&(!searchEvent||Object.keys(events).includes(searchEvent))){ | |
var itemQuery=element.nodeName; | |
if( | |
typeof element.id=="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
// EXECUTE: help | pipetest "dest.txt" | find "HELP" | |
#include <iostream> | |
using namespace std; | |
int main(int argc, char *argv[]){ | |
char tmpBuff=0; | |
while(argc-->0){ | |
cout<<"\t"<<(argv++)<<endl; | |
} | |
while(cin.good()){ | |
if(cin.get(tmpBuff))cout.put(tmpBuff); |
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
#include <iostream> | |
using namespace std; | |
template<typename V> void varPrint(char *name, V x, int len){ | |
V xT[len], *xX=xT; | |
cout | |
<<name |
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
/* | |
usefull in new study groups if your uniwersity email is based on "[email protected]" pattern, go to: | |
https://classroom.google.com/r/{ id of your classroom }/sort-last-name | |
inspect in devtools in browser one name of student, should be <span class="y4ihN YVvGBb">.... | |
paste code it into console | |
*/ | |
const CSS_SELECTOR_TARGET=prompt("insert css selector of all name fields", "span.y4ihN.YVvGBb"); | |
const COLEDGE_MAIL_POSTFIX=prompt("insert students emails postfix", "@edu.your-colledge.pl"); | |
console.log( | |
Array.from( |
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
#przerobka exploita 44374.py z exploit-db.com | |
# Exploit Title: osCommerce 2.3.4.1 Remote Code Execution | |
# Date: 29.0.3.2018 | |
# Exploit Author: Simon Scannell - https://scannell-infosec.net <[email protected]> | |
# Version: 2.3.4.1, 2.3.4 - Other versions have not been tested but are likely to be vulnerable | |
# Tested on: Linux, Windows | |
# If an Admin has not removed the /install/ directory as advised from an osCommerce installation, it is possible | |
# for an unauthenticated attacker to reinstall the page. The installation of osCommerce does not check if the page |
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
if [ $(cat "$1" |grep "print " -c) == 0 ]; | |
then | |
python2 "$1"; | |
else | |
python3 "$1"; | |
fi |
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
rem Sett Sarverott @ 2017 | |
rem image-renamer.bat [from-directory-path] [to-directory-path] [extension-without-dot] | |
rem ### | |
rem example of use: START /w /b .\image-renamer.bat E:\path\from\camera-files-with-long-names E:\path\to\camera-files-with-long-names jpg | |
dir /b "%1" >".\_picture-list.txt" | |
set picturecounter=1 | |
pause | |
:g |
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
int randomSound, delayPeriod; | |
void setup() { | |
} | |
void loop() { | |
delayPeriod=random(1,10); | |
for(int pin=0;pin<6;pin++){ | |
randomSound=random(20,1000); | |
noTone(pin); |
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 result=[]; | |
document.querySelectorAll(".table-container table tr").forEach(function(x){ | |
var currentRow=[]; | |
x.childNodes.forEach(function(y){ | |
if(y.nodeType==1){ | |
currentRow.push(y.innerText) | |
} | |
}) | |
result.push(currentRow); | |
}); |
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
/* | |
Simple dimmer controlled with buttons | |
Sarverott @ 2023 | |
https://gist.github.com/Sarverott/3b352c6c3fe1c3d13f3faf642cc3b23c | |
this project ingredients: | |
- digispark board { | |
ATtiny85 :: [ Flash memory = 8kb ; frequency = 16MHz ] | |
Board operational voltage = 5V |