Benchmarking Javascript for computational purposes

18 minute read Published:

Since Javascript at the moment is the simplest way to execute code on any client computer around the world, i thought it could be an interesting exercise trying to figure out how fast it became and if it’s a viable way to use it for a distributed computing platform. From some sources around the Web it appears a lot of work has been done to make Javascript as fast as possible and found this wonderful snippet who claimed:

How to block brute force attacks against your wordpress and live happy

3 minute read Published:

Some time ago i installed on my wordpress a wonderful plugin to help me secure this (and others) blog. it’s named Sucuri Security and it’s from it scans your wordpress for the most common mistakes and add some interesting features. One of these features it’s the capability of trace failed logins and save them in a log file in JSON format like: {"user_login":"admin","user_password":"","attempt_time":1422522535,"remote_addr":"","user_agent":false} This made me think of a possible way to exploit this information to temporary block the ip of the attacker so i made a simple script to “abuse” their log and ended up with a simple script in python.

Killing in the name of

1 minute read Published:

Using psmisc in python i’ve found this function quite useful in many projects i’ve been working lately. Basically it will kill all the process older than one hour that match “name” All those try except are just to avoid permission denied on kill or on name check. def killing_in_the_name_of(name): now = time.time() for p in psutil.get_process_list(): exe = "" try: exe = p.exe except Exception,e: pass if name in exe: exetime = now - p.

A suitable vimrc for python

1 minute read Published:

Since i find myself in a lot of trouble when going to a new linux system due to misconfigured vim i thought i might share with you my tipical default configuration for vim that is good for developing in python here are the main lines, since i use a dark background i like a lot the “background=dark” feature set compatible syntax on set background=dark if has("autocmd") au BufReadPost * if line("