Skip to content

Instantly share code, notes, and snippets.

View shalzz's full-sized avatar
🦀

Shaleen Jain shalzz

🦀
View GitHub Profile
@shalzz
shalzz / FileRename.bat
Last active September 6, 2018 05:45
[File Rename Script] #windows
@ECHO OFF
FOR /l %%n IN (159,1,179) DO (
FOR /D %%d IN (*%%n*) DO (
FOR /L %%a IN (1,1,30) DO (
rename "%%d\*[%%a].jpg" "%%a.jpg"
)
)
)
echo DONE!!!
@pause
@shalzz
shalzz / proxy.pac
Last active September 6, 2018 05:46
[PAC file for UPESNET at UPES] Proxy Automatic Configuration script which automatically sets the proxy required for the network "UPESNET" (Wi-Fi at University of Petroleum and Energy Studies). #windows
/*
* Copyright (C) 2013
* Shaleen Jain
* shalzz@outlook.com
*
* PAC File for UPESNET
*/
function FindProxyForURL(url, host) {
if(isResolvable("proxy.ddn.upes.ac.in"))
@shalzz
shalzz / wifi-hotspot.bat
Last active March 11, 2021 21:06
[Windows Wifi Hotspot] Batch file for creating Wifi Hotspot using Microsoft Hosted Network Virtual Adapter #windows
@echo off
REM Copyright (C) 2013
REM Shaleen Jain
REM shalzz@outlook.com
REM
REM Batch file for creating Wifi Hotspot
if _%1_==_payload_ goto :payload
:getadmin
echo %~nx0: elevating self
@shalzz
shalzz / MySSLSocketFactory.java
Last active May 8, 2020 03:25
[MySSLSocketFactory] Complete implementation of MySSLSocketFactory which provides an alternative to the default Apache Http Client SSLSocketFactory Implementation and fixes all SSL Certificate and Socket related problems on both Apache Http Client and URLConnection.
import java.io.BufferedInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.net.Socket;
import java.net.UnknownHostException;
import java.security.KeyManagementException;
import java.security.KeyStore;
import java.security.KeyStoreException;
import java.security.NoSuchAlgorithmException;
import java.security.UnrecoverableKeyException;
@shalzz
shalzz / sparse2img.sh
Created May 3, 2017 08:09
System image from stock sparse system images
simg2img system.img_sparsechunk.* system.img.raw.tmp
offset=`LANG=C grep -aobP -m1 '\x53\xEF' system.img.raw.tmp | head -1 | awk '{print $1 - 1080}'`
dd if=system.img.raw.tmp of=system.img.raw ibs=$offset skip=1

Keybase proof

I hereby claim:

  • I am shalzz on github.
  • I am shalzz (https://keybase.io/shalzz) on keybase.
  • I have a public key whose fingerprint is 0B07 0D51 4535 885D 87D9 9AEB 27B7 EB19 E6E4 FF30

To claim this, I am signing this object:

#cloud-config
runcmd:
- [ git, clone, https://github.com/shalzz/dotfiles.git ]
- [ cd, dotfiles]
- [ make, dotfiles]
@shalzz
shalzz / 0001-use-ozone-gbm.patch
Last active June 24, 2018 17:46
chromium: use ozone-gbm
From 1d8128e84271e3c02ae2c031c5a09b6e8ab674f2 Mon Sep 17 00:00:00 2001
From: Shaleen Jain <shaleen@jain.sh>
Date: Sat, 23 Jun 2018 15:04:42 +0530
Subject: [PATCH] use ozone-gbm
---
PKGBUILD | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/PKGBUILD b/PKGBUILD
@shalzz
shalzz / continuous-marketing.py
Last active September 6, 2018 05:41
[Continuous Marketing] Python script to brute force an api for emails and send a template email via sendgrid #api #bruteforce
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Insipired from the Brute force basic http auth script by zed
See https://gist.github.com/zed/0a8860f4f9a824561b51
"""
from __future__ import print_function
import sys
import time
from base64 import b64encode
@shalzz
shalzz / novelty-chain-manifesto.md
Last active October 23, 2018 10:11
[Novelty Chain] Living manifesto for the Novelty Chain collaboration platform

Hard parts of open source

  • Pathways

    • Freedom
    • Engagement
    • Community
  • Desired:

    • No anonymity / Verified ID
    • context for statement
  • filter signal from noise.