Skip to content

Instantly share code, notes, and snippets.

View jhadeepakkumar14's full-sized avatar

Deepak Kumar Jha jhadeepakkumar14

View GitHub Profile
(?i)((access_key|access_token|admin_pass|admin_user|algolia_admin_key|algolia_api_key|alias_pass|alicloud_access_key|amazon_secret_access_key|amazonaws|ansible_vault_password|aos_key|api_key|api_key_secret|api_key_sid|api_secret|api.googlemaps AIza|apidocs|apikey|apiSecret|app_debug|app_id|app_key|app_log_level|app_secret|appkey|appkeysecret|application_key|appsecret|appspot|auth_token|authorizationToken|authsecret|aws_access|aws_access_key_id|aws_bucket|aws_key|aws_secret|aws_secret_key|aws_token|AWSSecretKey|b2_app_key|bashrc password|bintray_apikey|bintray_gpg_password|bintray_key|bintraykey|bluemix_api_key|bluemix_pass|browserstack_access_key|bucket_password|bucketeer_aws_access_key_id|bucketeer_aws_secret_access_key|built_branch_deploy_key|bx_password|cache_driver|cache_s3_secret_key|cattle_access_key|cattle_secret_key|certificate_password|ci_deploy_password|client_secret|client_zpk_secret_key|clojars_password|cloud_api_key|cloud_watch_aws_access_key|cloudant_password|cloudflare_api_key|cloudflare_auth_k
@jhadeepakkumar14
jhadeepakkumar14 / proc_net_tcp_decode
Created July 1, 2023 13:49 — forked from jkstill/proc_net_tcp_decode
decode entries in /proc/net/tcp
Decoding the data in /proc/net/tcp:
Linux 5.x /proc/net/tcp
Linux 6.x /proc/PID/net/tcp
Given a socket:
$ ls -l /proc/24784/fd/11
lrwx------ 1 jkstill dba 64 Dec 4 16:22 /proc/24784/fd/11 -> socket:[15907701]
@jhadeepakkumar14
jhadeepakkumar14 / GoogleDorking.md
Created May 11, 2023 07:01 — 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"
@jhadeepakkumar14
jhadeepakkumar14 / fix-libv8-mac.txt
Created April 11, 2020 18:38 — forked from fernandoaleman/fix-libv8-mac.txt
Fixing libv8 and therubyracer on Mac
brew tap homebrew/versions
brew install v8-315
gem install libv8 -v '3.16.14.13' -- --with-system-v8
gem install therubyracer -- --with-v8-dir=/usr/local/opt/v8-315
bundle install
@jhadeepakkumar14
jhadeepakkumar14 / handling_multiple_github_accounts.md
Created September 3, 2019 18:18 — forked from Jonalogy/handling_multiple_github_accounts.md
Handling Multiple Github Accounts on MacOS

Handling Multiple Github Accounts on MacOS

The only way I've succeeded so far is to employ SSH.

Assuming you are new to this like me, first I'd like to share with you that your Mac has a SSH config file in a .ssh directory. The config file is where you draw relations of your SSH keys to each GitHub (or Bitbucket) account, and all your SSH keys generated are saved into .ssh directory by default. You can navigate to it by running cd ~/.ssh within your terminal, open the config file with any editor, and it should look something like this:

Host *
 AddKeysToAgent yes

> UseKeyChain yes

@jhadeepakkumar14
jhadeepakkumar14 / terminal-git-branch-name.md
Created November 17, 2018 09:28 — forked from joseluisq/terminal-git-branch-name.md
Add Git Branch Name to Terminal Prompt (Mac)

Add Git Branch Name to Terminal Prompt (Mac)

image

Open ~/.bash_profile in your favorite editor and add the following content to the bottom.

# Git branch in prompt.

parse_git_branch() {
@jhadeepakkumar14
jhadeepakkumar14 / postgres-cheatsheet.md
Created April 12, 2018 17:02 — forked from Kartones/postgres-cheatsheet.md
PostgreSQL command line cheatsheet

PSQL

Magic words:

psql -U postgres

Some interesting flags (to see all, use -h):

  • -E: will describe the underlaying queries of the \ commands (cool for learning!)
  • -l: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)
@jhadeepakkumar14
jhadeepakkumar14 / ImageUploadComponent.jsx
Created April 6, 2018 06:00 — forked from hartzis/ImageUploadComponent.jsx
React Image Uploading Component with Image Preview
class ImageUpload extends Component {
constructor(props) {
super(props);
this.state = {
file: '',
imagePreviewUrl: ''
};
this._handleImageChange = this._handleImageChange.bind(this);
this._handleSubmit = this._handleSubmit.bind(this);
}
@jhadeepakkumar14
jhadeepakkumar14 / users.sql
Created April 2, 2018 18:15 — forked from rosswd/users.sql
Managing users in MySQL
-- start mysql daemon
mysql.server start
-- connect as root
mysql -u root -p
-- create a new limited user
-- [field] = placeholder for your situation
CREATE USER '[username]'@'localhost' IDENTIFIED BY '[password]';
GRANT SELECT, INSERT, UPDATE, ALTER ON *.* TO '[username]'@'localhost';
@jhadeepakkumar14
jhadeepakkumar14 / cloudSettings
Last active July 15, 2021 12:31 — forked from rosswd/apps.md
2017 MacOS Apps
{"lastUpload":"2021-07-15T12:31:41.248Z","extensionVersion":"v3.4.3"}