Perl Blowfish

Perl Blowfish

Perl Blowfish

PostgreSQL released an update for all supported branches today, which includes a minor/major security fix and a minor/major enhancement, and you can and should get them now.

The arches are busy (bugs.gentoo.org) testing the packages, and will stabilize them as quick as they can. But, if you’re using the Blowfish cipher from pg_crypto, you probably won’t want to wait that long.

A bug was found (www.openwall.com) that encryption code could give wrong results on platforms where char is signed (which is most), leading to encrypted passwords being weaker than they should be.

If you are running a PostgreSQL server using the Blowfish cipher from pg_crypto, update now. If you’re not using pg_crypto in any of your databases, you’re safe and can wait for the latest versions to be stabilized, though I’d still recommend to make the move. If you don’t even have a PostgreSQL server on your machine, you’re doubly safe.

So, the security fix is minor if you don’t use the cipher, but major if you do.

On to Perl, 5.14 support was finally patched in. If you’ve been waiting for PostgreSQL to get this support going, this is a major enhancment, otherwise it’ll be a dull and dreary minor enhancement. Again, this only affects server owners.

There have been many other fixes, too. Check the news announcement (www.postgresql.org) for more information.

Gentoo 下安装 PAC Manager

PAC Manager 是一款不错的带有 GUI 界面的 SSH 链接管理器,可帮助你管理大量的远程 SSH 主机。PAC Manager 采用 Perl/GTK2 实现。由于官方只提供Deb包,所以在Gentoo下如果想用使用PAC Manager 需要从源代码手动安装,本文将介绍在Gentoo下如何安装PAC Manager

1、下载

从SourceForge主页上下载pac manager最新的源码包,地址为

http://sourceforge.net/projects/pacmanager/files/pac-2.0/

选择pac-*-all.tar.gz下载即可

或者从svn上直接checkout出最新的代码:

frank@frankpc-gentoo ~% svn co https://pacmanager.svn.sourceforge.net/svnroot/pacmanager pacmanager
2、安装依赖包

由于PAC Manager是perl程序,所以有一些perl的包需要安装,经过试验,发现下面这些包可以通过emerge来安装

在安装perl插件之前:

确保你的dev-lang/perl 的USE flag包括了ithreads,如果没有请执行:

frank@frankpc-gentoo ~% sudo USE=ithreads emerge -av dev-lang/perl

然后再执行:

frank@frankpc-gentoo ~% sudo emerge -av dev-perl/glib-perl dev-perl/yaml dev-perl/gtk2-perl dev-perl/Gtk2-Ex-Simple-List dev-perl/gtk2-gladexml dev-perl/crypt-cbc dev-perl/Expect dev-perl/Pango dev-perl/Cairo dev-perl/Crypt-Blowfish dev-perl/IO-Tty dev-perl/gnome2-gconf

不过还有两个包无法用emerge安装,一个是Net-ARP,另一个是Gnome2-Vte

这两个包可以从cpan的官网上去下载,下面给出这两个包的下载地址:

Net-ARP

Gnome2-vte

下载完成后解压两个包,分别cd进入两个包中执行:

frank@frankpc-gentoo ~% perl Makefile.PL frank@frankpc-gentoo ~% make frank@frankpc-gentoo ~% sudo make install

可选包 IO-Stty,这个包可以装,也可以不装,不会影响执行,下载地址 IO-Stty 下载完成后,解压,cd进入:

frank@frankpc-gentoo ~% perl Build.PL frank@frankpc-gentoo ~% ./Build frank@frankpc-gentoo ~% sudo cp blib/lib/IO/Stty.pm /usr/lib/perl5/5.12.2/IO/

上面这些步骤做完的话,依赖包就安装完成了。但是我启动的时候遇到了一个问题,就是PAC Manager无法识别jpeg图片,经过分析发现是因为libgtk+不支持jpeg,所以:

请确保你的x11-libs/gtk+的USE flag包括了jpeg,如果没有请执行:

frank@frankpc-gentoo ~% sudo USE=jpeg emerge -av gtk+
3、安装PAC Manager

把下载下来的pac-*-all.tar.gz解压,并cd进入解压后目录,执行:

frank@frankpc-gentoo pacmanager % mkdir ~/.pac frank@frankpc-gentoo pacmanager % mv res/pac.yml ~/.pac frank@frankpc-gentoo pacmanager % ./pac

这样的话就可以启动pac了,但是为了跟方便我们在菜单栏上启动,下面我们将一些文件放到系统指定的地方

frank@frankpc-gentoo pacmanager % sudo cp res/pac.desktop /usr/share/applications frank@frankpc-gentoo pacmanager % sudo cp res/pac.1 /usr/share/man/man1/ frank@frankpc-gentoo pacmanager % sudo cp res/pac*x*.png /usr/share/pixmaps frank@frankpc-gentoo pacmanager % sudo mkdir /opt/pac frank@frankpc-gentoo pacmanager % sudo cp -R lib LICENSE pac README res /opt/pac frank@frankpc-gentoo pacmanager % sudo ln -s /opt/pac/pac /usr/bin/pac

这样的话,你就可以在你的菜单栏的Internet分栏中看到pac的启动项了,我们就可以正常运行PAC Manager了

下面是几张截图


More From Fang Jian's Personal Blog

Ask Fang Jian's Personal Blog To Recommend Your Posts

Relevant pages: