nginx 1.9.3

Software

The latest release of the (rather lovely, dare I say) nginx webserver comes with several useful fixes and security patches. This one in particular is most welcome:

Change: duplicate "http", "mail", and "stream" blocks are now disallowed.

This will make debugging and late night stupidity so much easier to fix. Thanks to the contribs :)

The update is available under nginx-devel in FreeBSD ports.


Renaming files with invalid characters

Software

WARNING: Messing with inodes should be seen as a last resort for end users, not least seasoned sysadmins. Be extremely careful. Measure ten times, then ten more times, then cut once. I won't be held responsible for data loss, and by reading this post, you agree.

Whew. So I thought I was being all clever with my regex and batch processing foo. Unfortunately, I ended up with a stupid file named this:

$ ls
==> Ruben\ Baka

(For the pedants, this is a contrived example. The original file I had contained a smorgasboard of characters; and not in a good way).

While an accurate name, the backslash prevents renaming it with traditional tools, because the shell expands them. The road to infinity is paved with escaping escaped characters and vain attempts at wrapping quotes and such.

$ mv 'Ruben\ Baka' NewName 
==> mv: cannot stat 'Ruben\\ Stupid': No such file or directory

We can keep going down the rabbit hole of escaping characters, or we can rename the file using its inode. For those who don't know what these are, Linux Magazine ran an excellent article on them. The -i flag for ls identifies the inode for a file:

$ ls -i
==> 101010 Ruben\ Baka

Using this inode, we can rename the file thusly:

$ find . -inum 101010 Ruben\ Baka -exec mv {} NewName \;

Running this on Debian produced no output. FreeBSD and NetBSD's find commands note that they can no longer find the file under the original name:

==> find: ./Ruben\\ Baka: No such file or directory

And now we can confirm the rename was successful.

$ ls
==> NewName

Now all that's left is to tell you that inode 101010 is 42 in binary, even though inode numbers are expressed in decimal. Must you pedants ruin all the things?


Overnightscape Central: James Bond

Media

View episode

The Overnightscape Central is a fun weekly podcast hosted by the illustrious PQ Ribber. Hosts and listeners of The Overnightscape Underground participate in a topic each week, and you’re welcome to join.

02:44:24 – Ian Fleming’s immortal spy is considered and examined!! Frank Edward Nora!! Rubinerd!! Cali Dingo!! Mike Boody!! Doc Sleaze!! PQ Ribber hosts, commentates, reviews the week on ONSUG and tells you how to participate in next week’s show!!

You can view this episode on the Underground, listen to it here, and subscribe with this feed in your podcast client.


Rubenerd Show 280: The exploring virtual worlds to electronica episode

Show

Rubenerd Show 280

Podcast: Play in new window · Download

46:57 – Topics include 80s electronica, SoundCloud, The Pet Shop Boys, insomnia, virtual machines, DOSBox, exploring virtual worlds, Challenger, Funan Centre, Sim Lim Square, the Need For Speed franchise, the Midtown Madness franchise, Battlefield 1942, Dust in Counter Strike, Radio Free Shambles, Sailor Moon, the Banpresto Sailor Mercury game prize figure, and musical spookiness.

Recorded in Sydney, Australia. Licence for this track: Creative Commons Attribution-ShareAlike 3.0. Attribution: Ruben Schade. Music by Who Ha.

Released July 2015 on The Overnightscape Underground, an Internet talk radio channel focusing on a freeform monologue style, with diverse and fascinating hosts.

Subscribe with iTunes, Pocket Casts, Overcast or add this feed to your podcast client.


Is site blocking effective in stopping piracy?

Software

By placing an ITNews.com.au question in the heading of this post, I can merely refer to Betteridge's Law.

For those unfamiliar, the answer is no.


Overnightscape Central: Terrible Television

Media

View episode

The Overnightscape Central is a fun weekly podcast hosted by the illustrious PQ Ribber. Hosts and listeners of The Overnightscape Underground participate in a topic each week, and you’re welcome to join.

Delayed by a day, but well worth the wait!! An amazing assemblage with awesome hosts and LOTS of them!! Rubenerd debuts!! Jimbo is in the House!! Mike Boody flows!! Frank Edward Nora Surfs with Us!! Doc Sleaze has deep thoughts!! Chad Bowers is Chad!! PQ hosts, commentates, reviews the past week on ONSUG and otherwise yaps!!

You can view this episode on the Underground, listen to it here, and subscribe with this feed in your podcast client.


Say what, Perl?

Software

Unlike in other languages, Perl's default print function doesn't print newlines by default. This is often desirable, such as in this case:

#!/usr/bin/env perl
use strict;
use warnings;
print("Please enter your name: ");
my $name = <STDIN>;

The resulting prompt will have the user type their name on the same line.

Please enter your name: Tousaka Rin

In situations where you want a newline, you use the standard \n:

print("Zettai Ryouiki FTW\n");
print("Tousakaaaaaa!\n");

This was the subject of ridicule from my Ruby development friends in the past, so in 2010 I presented a function that did the same thing. Recent Perl versions have an even shorter function name, with the say command. The following will print the same as the above:

say("Zettai Ryouiki FTW");
say("Tousakaaaaaaa!")

You can use this in your scripts today by requiring at least Perl 5.10, or explicitly enabling the feature:

use 5.010;
use feature qw(say);

Done, and done.


That's a lot of Windows domains

Software

For a Mac/*nix gentleman, I've been doing an awful lot of Windows stuff of late. Today was discovering why certain services don't operate with external firewalls and proxy servers.

According to this Technet article, the following domains are required for successful Windows Updates:

http://windowsupdate.microsoft.com
http://*.windowsupdate.microsoft.com
https://*.windowsupdate.microsoft.com
http://*.update.microsoft.com
https://*.update.microsoft.com
http://*.windowsupdate.com
http://download.windowsupdate.com
http://download.microsoft.com
http://*.download.windowsupdate.com
http://wustat.windows.com
http://ntservicepack.microsoft.com

And according to this knowledgebase article, these URLs are required to be bypassed if you're running a proxy server, otherwise Windows Activation will fail:

http://go.microsoft.com/
https://sls.microsoft.com/
https://sls.microsoft.com:443
http://crl.microsoft.com/pki/crl/products/MicrosoftRootAuthority.crl
http://crl.microsoft.com/pki/crl/products/MicrosoftProductSecureCommunications.crl
http://www.microsoft.com/pki/crl/products/MicrosoftProductSecureCommunications.crl
http://crl.microsoft.com/pki/crl/products/MicrosoftProductSecureServer.crl
http://www.microsoft.com/pki/crl/products/MicrosoftProductSecureServer.crl
https://activation.sls.microsoft.com

And finally, these URLs are required for your daily dose of nostalgially bad web design:

//rubenerd.com/

It reminds me of all the domains I had to whitelist in NoScript to access my student email in Outlook Web Access. As much as I dislike and not trust Google thesedays, I only needed one domain for Gmail to work back then.

And as an aside, this is the second post in 2015 to start with "That's a lot of...". Make of that what you will. I wouldn't recommend overthinking it, or anything for that matter. I wonder if I can make ten? Sounds like a challenge :3.


Rubenerd Show 279: The four cities of Sydney episode

Show

Rubenerd Show 279

Podcast: Play in new window · Download

53:45 – Topics include Fireside Brew tea by Cauldron Brews, not feeling quite with it, comma seperated values, The Geographic Names Board of New South Wales, Melbourne, Albion, Parramatta, Winterfest 2015, Scottish and German ancestry, ergonomic keyboards, outdated Wikipedia rips, cost of living in Sydney and NYC, virtual offices and real spammers, an ideal trip to North America, Israel Brown, and finding Woodland Hills.

Recorded in Sydney, Australia. Licence for this track: Creative Commons Attribution-ShareAlike 3.0. Attribution: Ruben Schade. Music by CyberSDF.

Released July 2015 on The Overnightscape Underground, an Internet talk radio channel focusing on a freeform monologue style, with diverse and fascinating hosts.

Subscribe with iTunes, Pocket Casts, Overcast or add this feed to your podcast client.


A computer on every desk and in every home

Software

Ars Technica has an article about Microsoft's revised mission statement. Its marketing buzzwords and uninspiring verbosity lead the article's author to opine:

Both are a far cry from the Bill Gates era. "A computer on every desk and in every home" was clearer in intent and actually measurable; it was a mission statement that allowed Microsoft to more or less say "Mission accomplished."

I'm not even frustrated by this any more, I'm just curious why nobody ever quotes the second part of that statement:

[..] running Microsoft software.

It's like the journalists of the world have collective amnesia. I'd argue it significantly changes the tone of any article that quotes it.