Skip to content

Instantly share code, notes, and snippets.

View celsobessa's full-sized avatar

Celso Bessa celsobessa

View GitHub Profile

POSIX commands Cheatsheat

  • admin - create and administer SCCS files (DEVELOPMENT)
  • alias - define or display aliases
  • ar - create and maintain library archives
  • asa - interpret carriage-control characters
  • at - execute commands at a later time
  • awk - pattern scanning and processing language
  • basename - return non-directory portion of a pathname
  • batch - schedule commands to be executed in a batch queue
@celsobessa
celsobessa / nvmCommands.js
Created June 29, 2021 03:43 — forked from chranderson/nvmCommands.js
Useful NVM commands
// check version
node -v || node --version
// list installed versions of node (via nvm)
nvm ls
// install specific version of node
nvm install 6.9.2
// set default version of node
@celsobessa
celsobessa / google-dorks
Created June 27, 2021 01:10 — 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!
@celsobessa
celsobessa / GoogleDorking.md
Created June 27, 2021 00:47 — forked from sundowndev/GoogleDorking.md
Google dork cheatsheet

Google dork cheatsheet

Search filters

Filter Description Example
allintext Searches for occurrences of all the keywords given. allintext:"keyword"
intext Searches for the occurrences of keywords all at once or one at a time. intext:"keyword"
inurl Searches for a URL matching one of the keywords. inurl:"keyword"
allinurl Searches for a URL matching all the keywords in the query. allinurl:"keyword"
intitle Searches for occurrences of keywords in title all or one. intitle:"keyword"
@celsobessa
celsobessa / bandwidth.js
Last active June 25, 2021 14:58 — forked from debloper/bandwidth.js
Determine client's connection speed with JavaScript
// Let's initialize the primitives
var startTime, endTime, fileSize, result, unit = {kbps:1,kBps:8};
// Set up the AJAX to perform
var xhr = new XMLHttpRequest();
// Rig the call-back... THE important part
xhr.onreadystatechange = function () {
// we only need to know when the request has completed
@celsobessa
celsobessa / Links
Created June 5, 2021 20:41 — forked from lukecav/Links
Speed Up Your WordPress Site with These 3 Advanced Techniques Workshop - WordSesh 2021
@celsobessa
celsobessa / trap_focus.js
Created June 5, 2021 20:39 — forked from myogeshchavan97/trap_focus.js
Code for trapping focus inside modal
// add all the elements inside modal which you want to make focusable
const focusableElements =
'button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])';
const modal = document.querySelector('#exampleModal'); // select the modal by it's id
const firstFocusableElement = modal.querySelectorAll(focusableElements)[0]; // get first element to be focused inside modal
const focusableContent = modal.querySelectorAll(focusableElements);
const lastFocusableElement = focusableContent[focusableContent.length - 1]; // get last element to be focused inside modal
@celsobessa
celsobessa / 1. Refactoring - Original.js
Last active February 23, 2020 17:34 — forked from Integralist/1. Refactoring - Original.js
The importance of refactoring... (by Mark McDonnell ( https://gist.github.com/Integralist )
var isProxyBased = (/S40[\w]{3,5}Browser|Opera\sMini\//i).test(navigator.userAgent);
if (('querySelector' in document && 'localStorage' in window && 'addEventListener' in window && !isProxyBased) || (isIE > 6 && document.getElementById('js-holepunched'))) {
// do stuff
}
@celsobessa
celsobessa / GoogleHackMasterList.txt
Created January 27, 2020 15:37 — forked from cmartinbaughman/GoogleHackMasterList.txt
The definitive super list for "Google Hacking".
admin account info" filetype:log
!Host=*.* intext:enc_UserPassword=* ext:pcf
"# -FrontPage-" ext:pwd inurl:(service | authors | administrators | users) "# -FrontPage-" inurl:service.pwd
"AutoCreate=TRUE password=*"
"http://*:*@www” domainname
"index of/" "ws_ftp.ini" "parent directory"
"liveice configuration file" ext:cfg -site:sourceforge.net
"parent directory" +proftpdpasswd
Duclassified" -site:duware.com "DUware All Rights reserved"
duclassmate" -site:duware.com
@celsobessa
celsobessa / multiple_ssh_setting.md
Created November 2, 2019 23:40 — forked from jexchan/multiple_ssh_setting.md
Multiple SSH keys for different github accounts

Multiple SSH Keys settings for different github account

create different public key

create different ssh key according the article Mac Set-Up Git

$ ssh-keygen -t rsa -C "your_email@youremail.com"