Skip to content

Instantly share code, notes, and snippets.

View thijzert's full-sized avatar

Thijs van Dijk thijzert

  • Den Haag, Nederland
View GitHub Profile

Betreft: Geluidsoverlast Huisman / Seven Waves
Datum: 30 december 2016

Aan:

  • Huisman Equipment BV
  • Damen Shiprepair Schiedam
  • Gemeente Schiedam
  • DCMR Milieudienst Rijnmond
@thijzert
thijzert / encoded-word.php
Last active November 9, 2017 10:36
MIME encoded-word (RFC2047) decoder
<?php
/**
* @param string $value Raw MIME header field
* @return string UTF-8 subject
**/
function decode_header_field( $value )
{
if ( preg_match( "/^\\=\\?([a-z0-9-]+)\\?([QB])\\?(.*)\\?\\=\$/i", $value, $sub ) )
{
@thijzert
thijzert / bad-passwords.php
Last active February 26, 2018 15:33
Bad password generation
<?php
/**
* Note: from PHP 7.0 and up, rand() is identical to mt_rand().
* In order to test both functions, run this file on PHP 5.6 or below.
*/
$date = 'Tue, 21 Feb 2018 11:21:40 +0100';
$hash = '$1$Wp8cWAg7$stCx1RGCLwwZmYJi9eKRI0';