Skip to content

Instantly share code, notes, and snippets.

View wildone's full-sized avatar

Max Barrass wildone

View GitHub Profile
wildone / gist:c6fbde582f9104d491012ea0380830bc
Created September 13, 2023 05:47
sample algorithm based on basic upload
from typedb.client import *
from loguru import logger as Logger
from posixpath import basename
import json
import copy
import os
import sys
import argparse
from datetime import datetime
gquery = "match $a isa log, has logName 'L1'; "
wildone / gist:d3aee880d1ffe4ca8b7378665f9c31f2
Created September 6, 2023 02:06
POST a JSON to a URL with insecure or invalid SSL certs using latest JDK 11 HttpClient
// Create a trust manager that does not validate certificate chains
TrustManager[] trustAllCerts = new TrustManager[]{
new X509TrustManager() {
public[] getAcceptedIssuers() {
return null;
public void checkClientTrusted([] certs, String authType) {
wildone /
Last active July 27, 2021 02:54
Setting up Windows 10 from scratch on UEFI motherboard

Setting up Windows 10 from scratch on UEFI

If you have a new motherboard that has UEFI and it detects your USB as a UEFI device and may give you issues installing.

So if you have issues you can follow these steps to move boot content from your USB to your new drive and then install will work.

1. Create bootable windows 10 disk

This will depend on which os you are using.

Windows 10 version 2004 - Installing Node.js on Windows Subsystem for Linux (WSL/WSL2)

UPDATE (Fall 2020): This gist is an updated version to the Windows 10 Fall Creators Update - Installing Node.js on Windows Subsystem for Linux (WSL) guide, I usually just keep here notes, configuration or short guides for personal use, it was nice to know it also helps other ppl, I hope this one too.

Windows updated windows subsystem for linux to version 2, as the F.A.Q stated you can still use WSL version 1 side by side with version 2. I'm not sure about existing WSL machines surviving the upgrade process, but as always backup and 🤞. NOTE: WSL version 1 is not replace/deprecated, and there ar

wildone / Add ssh-agent to your bash start
Last active November 14, 2020 03:05
Add ssh-agent to your bash start
Best way to use ssh keys is to add them to SSH Agent, this will will allow you use ssh without needing to specify pasword for your SSH key all the time.
To do this add these lines to you `.bash_profile` or `.profile`
if [ -z "$SSH_AUTH_SOCK" -a -x "$SSHAGENT" ]; then
trap "kill $SSH_AGENT_PID" 0
wildone / Powershell Do Sling Post
Last active June 19, 2020 11:48
Powershell Do Sling Post
function doSlingPost {
Param (
wildone / Powershell Export content using FileVault
Created June 15, 2020 12:20
Powershell Export content using FileVault
# Download and extract Filevault from run this in the extracted folder.
#equivalent of using localhost in docker container
Set-Variable -name SOURCE_HOST -value "localhost"
# TCP port SOURCE_CQ listens on
Set-Variable -name SOURCE_PORT -value "4502"
# AEM Admin user for SOURCE_HOST
Set-Variable -name SOURCE_AEM_USER -value "admin"
# AEM Admin password for SOURCE_HOST
Set-Variable -name SOURCE_AEM_PASSWORD -value "admin"
wildone / Powershell wait for URL
Last active June 15, 2020 12:19
Powershell wait for URL
function WaitForUrlContent {
Param (
wildone /
Last active June 13, 2020 14:12
setup kong api gateway and gui
wildone / squid.conf
Last active June 3, 2020 02:34
Basic SQUID proxy config for running Squid in Docker with Local and Docker LAN allowed
# Description:
# Basic SQUID proxy config for running Squid in Docker with Local and Docker LAN allowed
# Uage:
# docker run --name squid -d --restart=always --publish 3128:3128 --volume ${pwd}\squid.conf:/etc/squid/squid.conf sameersbn/squid
# TAG: acl
# Defining an Access List
acl SSL_ports port 443