Skip to content

Instantly share code, notes, and snippets.

istvan kosztik

Block or report user

Report or block kosztik

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View mailpilerimport.txt
Mailpiler - Importing & Deduplicating email from PST Files
Hi there,
I'll be tackling getting mail from PST files into mailpiler, and deduping them before the import.
This howto is written for Ubuntu 16.04 - as my Piler install howto is for the same.
#!/usr/bin/env python
import socket
import struct
import sys
import os
def ip2int(addr):
return struct.unpack("!I", socket.inet_aton(addr))[0]
kosztik /
Last active Feb 27, 2020
convert bank stm to csv
import sys
print ("tranzakcio tipus; banki azonosito; megbizas osszege; megbizas devizaneme; megbizo bankja; megbizo neve; megbizo szamlaszama; \
kozlemeny1; kozlemeny2; kozlemeny3; kozlemeny4; kedvezmenyezett bankja; kedvezmenyezett neve; kedvezmenyezett szamlaszama; \
bizonylatszam; hatarido; jovairas szamlaszama; jovairas devizaneme; jovairas vegso osszege; jovairas erteknapja; \
terheles szamlaszama; terheles devizaneme; terheles vegso osszege; terheles erteknapja")
filepath = sys.argv[1]
# Use: /var/log/ <from/to pattern>
# Used with postfix
if [[ $1 =~ gz ]]; then
kosztik / rename_accent
Last active Aug 31, 2019
rename accent files and dirs
View rename_accent
# Put the old filenames in a file.
ls $PATH >> oldValues
# Put the new names without accents in another file
cat oldValues | sed -e 'y/āáǎàēéěèīíǐìōóǒòūúǔùǖǘǚǜĀÁǍÀĒÉĚÈĪÍǏÌŌÓǑÒŪÚǓÙǕǗǙǛ/aaaaeeeeiiiioooouuuuüüüüAAAAEEEEIIIIOOOOUUUUÜÜÜÜ/' >> newValues
kosztik /
Last active Aug 7, 2019
punishment based on suhosin
# run screen; screen -r; watch /root/
ip=tail -1 /var/log/syslog| grep suhosin |grep ALERT | grep -v memory_limit|grep "([0-9]{1,3}[\.]){3}[0-9]{1,3}" -o -E
View send_nsca_saslauth
#^^^^^nincs használatban
#^^^^^^^^^^ Ezt hasznalom jelenleg
kosztik /
Last active Aug 3, 2019
upload check for suhosin
#use strict;
#use warnings;
# ===============================================================================================================
# ===================================== DEBUG START
# ===============================================================================================================
#open(my $fh, '>>', '/tmp/report.txt');
## feltolteskor a felhasznalo tulajdona lesz a file, es mas nem is tudja
# Copyright (c) 2016, Florian Schaal,
# All rights reserved.
# Redistribution and use in source and binary forms, with or without modification,
# are permitted
DOW1=`date +%j`
# no of backups
DOW=`expr $DOW1 % 3`
kosztik / media-query.css
Created Oct 26, 2018 — forked from gokulkrishh/media-query.css
CSS Media Queries for Desktop, Tablet, Mobile.
View media-query.css
##Device = Desktops
##Screen = 1281px to higher resolution desktops
@media (min-width: 1281px) {
You can’t perform that action at this time.