Skip to content

Instantly share code, notes, and snippets.

@csm10495
csm10495 / locked_cookie_test.py
Last active May 7, 2024 14:56
POC that fetches cookies from a locked cookies file on Windows with Chromium based browsers
@jagrosh
jagrosh / Github Webhook Tutorial.md
Last active May 7, 2024 14:54
Simple Github -> Discord webhook

Step 1 - Make a Discord Webhook

  1. Find the Discord channel in which you would like to send commits and other updates

  2. In the settings for that channel, find the Webhooks option and create a new webhook. Note: Do NOT give this URL out to the public. Anyone or service can post messages to this channel, without even needing to be in the server. Keep it safe! WebhookDiscord

Step 2 - Set up the webhook on Github

  1. Navigate to your repository on Github, and open the Settings Settings
@ahmeti
ahmeti / only-number.directive.md
Last active May 7, 2024 14:54
Angular 5 - Only Number Input, Only Number Decimal
@jamesfreeman959
jamesfreeman959 / keepawake.ps1
Last active May 7, 2024 14:52
A very simple PowerShell script to keep a Windows PC awake and make lync think the user is active on the keyboard
# Useful references:
#
# https://superuser.com/questions/992511/emulate-a-keyboard-button-via-the-command-line
# https://ss64.com/vb/sendkeys.html
# https://social.technet.microsoft.com/Forums/windowsserver/en-US/96b339e2-e9da-4802-a66d-be619aeb21ac/execute-function-one-time-in-every-10-mins-in-windows-powershell?forum=winserverpowershell
# https://learn-powershell.net/2013/02/08/powershell-and-events-object-events/
#
# Future enhancements - use events rather than an infinite loop
$wsh = New-Object -ComObject WScript.Shell
while (1) {
1. hiltvm (applicable in top-level)
@dagger.hilt.android.lifecycle.HiltViewModel
class $NAME$ @javax.inject.Inject constructor(
$PARAM$
) : androidx.lifecycle.ViewModel() {
$END$
}
2. vmstatefunc (applicable in class)
private val _$NAME$ = androidx.compose.runtime.mutableStateOf<$TYPE$>($INITIAL_VALUE$)
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/ PropertyList-1.0.dtd">
<key>com.apple.springboard.debugapplications
<true/>
<key>run-unsigned-code
<true/>
<key>get-task-allow
<true/>
<key>task_for_pid-allow
@avoiney
avoiney / .env
Created July 28, 2021 06:47
Directus under non root path with nginx
DIRECTUS_KEY=<...>
DIRECTUS_SECRET=<...>
DIRECTUS_DB_DATABASE=<...>
DIRECTUS_DB_USER=<...>
DIRECTUS_DB_PASSWORD=<...>
DIRECTUS_CACHE_ENABLED=true
DIRECTUS_CACHE_STORE=redis
DIRECTUS_ADMIN_EMAIL=<...>
DIRECTUS_ADMIN_PASSWORD=<...>
DIRECTUS_PUBLIC_URL=https://<server_name>/directus/ # server_name is the one used in nginx. Note the slash at the end.
@HarmJ0y
HarmJ0y / PowerView-3.0-tricks.ps1
Last active May 7, 2024 14:48
PowerView-3.0 tips and tricks
# PowerView's last major overhaul is detailed here: http://www.harmj0y.net/blog/powershell/make-powerview-great-again/
# tricks for the 'old' PowerView are at https://gist.github.com/HarmJ0y/3328d954607d71362e3c
# the most up-to-date version of PowerView will always be in the dev branch of PowerSploit:
# https://github.com/PowerShellMafia/PowerSploit/blob/dev/Recon/PowerView.ps1
# New function naming schema:
# Verbs:
# Get : retrieve full raw data sets
# Find : ‘find’ specific data entries in a data set
@0xjac
0xjac / private_fork.md
Last active May 7, 2024 14:47
Create a private fork of a public repository

The repository for the assignment is public and Github does not allow the creation of private forks for public repositories.

The correct way of creating a private frok by duplicating the repo is documented here.

For this assignment the commands are:

  1. Create a bare clone of the repository. (This is temporary and will be removed so just do it wherever.)

git clone --bare git@github.com:usi-systems/easytrace.git

@viercc
viercc / sequenceA-eq-distribute.md
Last active May 7, 2024 14:46
sequenceA == distribute?

https://twitter.com/lotz84_/status/1787796266484908211

lotz @lotz84_

これを書いていて Vector n a 同士の sequenceA が distribute のように振る舞うのが気になった👀 一般に Traversable の distribute が Distributive の sequenceA に一致することが則を使って言えないだろうか?🤔 QuickCheck で少し探してみたけど反例はなさそう

大枠