Archive for the ‘ Linux ’ Category

pdftk cont’d…

I recently had cause to export many hundreds of email messages to .pdf. I’ll save you the details as to why but subsequently I needed to know the cost (in time and paper usage) of printing out all of the PDF files; how many pages would it be? How could I know? I previously posted about pdftk so I assumed it would provide me the answer. A bit of Googling led me to commandlinefu and the following solution.

find . -name "*.pdf" -exec pdftk {} dump_data output \; | grep NumberOfPages | awk '{s+=$2} END {print s}'

It worked like a charm.

The answer was “515” pages. Too many I think.

Very Cool

#Linux Reminiscing

I came across this today among other the books on shelf. It’s the first Linux distribution I ever used. I bought it at Comp USA sometime back in 1998. If I remember correctly I could not get X working properly but I was able to get it online, use pine to do some email and set up an ftp server on it.

Red Hat 5.2

2014-09-05 17.51.41-1

Sysadmin Day

So today is Sysadmin Day.


I can relate:

michael@silverado:~$ uptime
12:44:30 up 597 days, 15:23

Heartbleed and the Debian Way

With all the news about the Heartbleed vulnerability in the OpenSSL package lately I figured that I should make sure my servers were patched. In looking at the version I have installed it seemed I was indeed running one of the affected versions.

$ openssl version
OpenSSL 1.0.1 14 Mar 2012

I was concerned and confused because I was sure that I had made all the recent security updates which I did confirm with:

# apt-get dist-upgrade
Reading package lists… Done
Building dependency tree
Reading state information… Done
Calculating upgrade… Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

So I needed to understand how I could be running all the latest updates but still have version of a package that was in the range of known impacted versions. This led me to some “apt” tools I was not previously aware of.

# apt-get changelog openssl
openssl (1.0.1-4ubuntu5.12) precise-security; urgency=medium

* SECURITY UPDATE: side-channel attack on Montgomery ladder implementation
– debian/patches/CVE-2014-0076.patch: add and use constant time swap in
crypto/bn/bn.h, crypto/bn/bn_lib.c, crypto/ec/ec2_mult.c,
util/libeay.num.
– CVE-2014-0076
* SECURITY UPDATE: memory disclosure in TLS heartbeat extension
– debian/patches/CVE-2014-0160.patch: use correct lengths in
ssl/d1_both.c, ssl/t1_lib.c.
– CVE-2014-0160

— Marc Deslauriers Mon, 07 Apr 2014 15:45:14 -0400

You can see above in the output of “apt-get changelog openssl”, the comment in bold shows that OpenSSL on my system has indeed been patched. I always love it when I learn something new and useful about how the Debian system works.

GNU

I use GNU software and other GPL licensed software every day. My business depends on it. They are celebrating a birthday this weekend.

#lovelinux

So today I was trying to tarball a large file and wanted to use the lzma compression method. I’ve done it before but couldn’t remember the syntax and couldn’t get it right by guessing. So, off the the man-page for a quick refresher and I found this little gem:

-a, –auto-compress use archive suffix to determine the compression program

No need to specify the algorithm explicitly, just add the “a” to your options and pick the file-name suffix of the compression type you want to use. Sweet!

I just love finding the little things in Linux that make life easier and confirms for me all the reasons I like using it.

Happy Birthday Debian

Debian turns 19 today. Thank you Ian.

Distro bash.

Linus has never been one to pull punches. In his recent Google+ post on OpenSuSE he is consistent and quite funny.

Whoever moron thought that it’s “good security” to require the root password for everyday things like this is mentally diseased.

So here’s a plea: if you have anything to do with security in a distro, and think that my kids… need to have the root password to access some wireless network, or to be able to print out a paper, or to change the date-and-time settings, please just kill yourself now. The world will be a better place.

FreedomBox project.

I like this. I particularly like the idea of this being able to form a mesh. In my opinion it will be the mesh network that we will eventually rely on for the free dissemination of information. There are many other projects out there that can be aggregated to form the mesh. I mentioned the mesh-potato in the past. There are also many consumer grade wireless routers that can be adapted to the mesh task with freely available custom firmware. I use the WRT54GL and Tomato at home now. Its brilliant.

Here are some other mesh network related sites: