解码heidiSql的密码

先导出heidisql的设置到文本文件. 然后找出密码字段,放到以下的js 去解码.

function heidiDecode(hex) {
    var str = '';
    var shift = parseInt(hex.substr(-1));
    hex = hex.substr(0, hex.length - 1);
    for (var i = 0; i < hex.length; i += 2) {
        str += String.fromCharCode(parseInt(hex.substr(i, 2), 16) - shift);
    }
    return str;
}

来源: http://www.chasewoodford.com/blog/how-to-recover-a-stored-password-from-heidisql/

ZF1的DB语法文档和查询实际的query

是的,我还在用zF1,而且还需要查文档.这是ZF1的数据库相关的文档,每次写都要看.

https://framework.zend.com/manual/1.12/en/zend.db.select.html

另外,我还需要查看数据库到底执行了哪些查询,需要打开log

  1. Execute SET GLOBAL log_output = 'TABLE';
  2. Execute SET GLOBAL general_log = 'ON';
  3. Take a look at the table mysql.general_log

来源:https://stackoverflow.com/questions/650238/how-to-show-the-last-queries-executed-on-mysql 

但是在heidi里看到的argument还是hex,还要用个开关来转为txt.

https://www.heidisql.com/forum.php?t=24486

这样终于看到实际执行的sql了.