Skip to content

Instantly share code, notes, and snippets.

View dongri's full-sized avatar
🥃

Dongri Jin dongri

🥃
View GitHub Profile
This post links my 3Box profile to my Github account! Web3 social profiles by 3Box.
✅ did:3:bafyreib3fz5jyyy4bf5nusreac2xjdohfsgrpk67n7fqc6gcwhya2ppqoe ✅
Create your profile today to start building social connection and trust online at https://3Box.io/
@dongri
dongri / hello.sh
Last active June 14, 2020 21:06
hello github-japan.com
#!/bin/sh
base="https://github-japan.com";
paths=("/attempts.php" "/norepos.php" "/submit.php");
for path in "${paths[@]}"; do
for i in {0..1000}; do
username=$(cat /dev/urandom | tr -dc 'a-z' | fold -w 6 | head -n 1)
password=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 10 | head -n 1)
curl -XPOST -d "user=$username&pass=$password" $base$path;
# Run with elevated privileges
# If you have Connect Wise Control installed, remove it. IT organizations are likely to install it (or similar tool) if they feel the need for Netskope clients.
# RE: https://saputra.org/threads/remove-screenconnect-or-connectwise-control-from-windows-mac-linux.45/
function remove_cswincom() {
thumbprint=$(ls /Library/LaunchAgents/connectwisecontrol-* | head -1 | awk -F- '{print $2}')
# Stop the ConnectWiseControl Client service
launchctl unload /Library/LaunchAgents/connectwisecontrol-${thumbprint}-onlogin.plist
# Delete the service definitions
rm -f /Library/LaunchAgents/connectwisecontrol-${thumbprint}-*.plist
@dongri
dongri / uninstall-netskope.sh
Last active February 16, 2024 15:23
uninstall netskope
#!/bin/sh
sudo ps aux | grep Netskope | grep -v grep | awk '{ print "kill -9", $2 }' | sudo sh
echo '[✓] Kill Netskope Process'
sudo rm -rf /Applications/Remove\ Netskope\ Client.app
echo '[✓] Removed Remove Netskope Client.app'
sudo rm -rf /Library/Application\ Support/Netskope
echo '[✓] Removed Agent of Netskope Client.app'
@dongri
dongri / DongriToken.sol
Created March 5, 2018 23:04
DongriToken.sol
pragma solidity ^0.4.18;
/**
* @title SafeMath
* @dev Math operations with safety checks that throw on error
*/
library SafeMath {
/**
* @dev Multiplies two numbers, throws on overflow.

Keybase proof

I hereby claim:

  • I am dongri on github.
  • I am dongri (https://keybase.io/dongri) on keybase.
  • I have a public key whose fingerprint is BC04 6914 ACB9 FB83 6F4E 57AB 0DB2 4ED7 A499 7CE7

To claim this, I am signing this object:

@dongri
dongri / parse_yaml.sh
Created November 7, 2016 17:21 — forked from pkuczynski/parse_yaml.sh
Read YAML file from Bash script
#!/bin/sh
parse_yaml() {
local prefix=$2
local s='[[:space:]]*' w='[a-zA-Z0-9_]*' fs=$(echo @|tr @ '\034')
sed -ne "s|^\($s\)\($w\)$s:$s\"\(.*\)\"$s\$|\1$fs\2$fs\3|p" \
-e "s|^\($s\)\($w\)$s:$s\(.*\)$s\$|\1$fs\2$fs\3|p" $1 |
awk -F$fs '{
indent = length($1)/2;
vname[indent] = $2;
for (i in vname) {if (i > indent) {delete vname[i]}}
@dongri
dongri / .zshrc
Created October 14, 2016 02:11
fuck
alias fuck="osascript -e 'quit app \"slack\"'"
#!/bin/bash
## Copyright (C) 2015 Cerebral Gardens http://www.cerebralgardens.com/
##
## Permission is hereby granted, free of charge, to any person obtaining a copy of this
## software and associated documentation files (the "Software"), to deal in the Software
## without restriction, including without limitation the rights to use, copy, modify,
## merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
## permit persons to whom the Software is furnished to do so, subject to the following
## conditions:
set-window-option -g mode-mouse on
set-option -g mouse-select-pane on
set-option -g mouse-resize-pane on
set-option -g mouse-select-window on
set-option -g default-shell /bin/bash
bind-key j page-up
bind-key ; page-down
# Fix LSOpenURLsWithRole() error on OS X. Requires reattach-to-user-namespace