Skip to content

Instantly share code, notes, and snippets.

@hazarkarabay
hazarkarabay / asnvpn.rsc
Created May 5, 2018 20:04
Mikrotik'te ASN bilgisinden IP range bulan ve address list'e ekleyen script.
# ASN bazinda VPN scripti
# 2018 Hazar
:local VPNAddrList "vpnize-auto";
:local ASNlist {
202196="booking";
43996="booking";
14907="wiki";
11820="wiki";
@hazarkarabay
hazarkarabay / b64decode-uipow.lua
Created September 20, 2015 12:29
Working Lua base64 decode for nodemcu float builds
#!/usr/local/bin/lua
-- httpserver-b64decode.lua
-- Part of nodemcu-httpserver, contains b64 decoding used for HTTP Basic Authentication.
-- Modified to use an exponentiation by multiplication method for only applicable for unsigned integers.
-- Based on http://lua-users.org/wiki/BaseSixtyFour by Alex Kloss
-- compatible with lua 5.1
-- http://www.it-rfc.de
-- Author: Marcos Kirsch
local function uipow(a, b)
@hazarkarabay
hazarkarabay / Hmail_Pass
Created December 8, 2014 13:06
Validate and generate Hmailserver passwords using PHP
<?php
/**
* A poor implementation of Hmailserver's HashCreator.h in PHP
*
* Blowfish(ETBlowFish) and "plaintext"(ETNone) not currently supported.
*
* This matches with accountpwencryption field on DB. Hmail_Pass class uses different constants for types, like original source.
* From \hmailserver\source\Server\Common\Util\Crypt.h
* ETNone = 0,