We get unusual messages from time to time here at Naked Security.
There was the Ukrainian bloke (well, he said he was Ukrainian, and said he was a bloke, for that matter) who kindly offered us part of his liver.
We had forum spammers who unleashed on us all the canned comments from their database in one giant, if incomprehensible, spew of spam.
Today, however, we had a much more cheerful, albeit out-of-the-ordinary, message from the sort of source we’d really love to hear from more often.
A vacationing coder with a penchant for fitting geekiness into regular life!
Jonathan Molteno describes himself as an “old school, round-peg assembler programmer currently jammed into a square hole called AJAX.”
He comes, he says, from somewhere “notoriously rainy, where the North Sea is considered an ocean and a bunch of mudflats a beach.”
Seeking a temporary respite from the weather, Jonathan found himself with some coding colleagues taking a team-building trip to Cape Town.
It seems they chose Cape Town on the inescapably logical grounds (to a bunch of programmers, anyway) that it was about as far from the North Sea as they could get, literally and figuratively, on a single overnight flight using only air miles.
As Jonathan tells it:
Being the old one out in the group, I decided to give the Whale Watching tour a miss, because of the 4 hour minibus trip to a place called Hermanus. I bet they have a lot of trouble with their road signs. I went for a walk instead, up a prominence behind the hotel called Signal Hill. More of a mountain at my age.
After taking a wrong turning I came to a chain link fence with barbed wire on it, apparently just short of the summit. There was a much-used hole in it so I slipped through, past a giant red flag that I probably should have paid more attention to...and suddenly I was looking down the twin barrels of two cannons, both of them looking dangerously old - they were covered in verdigrease - but rigged up as though to fire.
Apparently, I'd stumbled on the Noon Guns - they have two in case the first one doesn't go off, or the 300-year-old smooth-bore barrel finally bursts, or something. The South African Navy has fired a Noon Gun every day for close on 200 years, and despite everyone having precise time on their phones these days thanks to GPS there was a big crowd out to watch. The cannons blast out a huge puff of very smoky gunpowder so ships in the harbour can see exactly when it's noon, because the sound takes a few seconds to reach the city and the water's edge below.
My geek interest was aroused: according to the blurb, the time signal to fire the gun comes from the Astronomical Observatory offices about 8km away. Does the Astronomical Observatory set its time clocks in turn from the Noon Gun? Apparently not, they use NTP, which sounds like cheating to me.
Then I noticed that yesterday, according to a signboard, was the Navy's 65,535th firing of the gun. Just shy of 180 years [*], then, assuming they've never missed a day. (There was a very shipshape Navy officer in attendance with a super-shiny belt buckle. Somehow I didn't want to ask him if they'd ever forgotten to fire it.)
Suddenly I was nerdily nervous, though I didn't dare ask him this question either, "What about integer overflow?"
Today was going to be the 216th firing! There was nothing for it but to sit in the sunshine, gazing out to sea - there's a great view of Robben Island from up there - waiting for noon and daydreaming about whether any other daily military traditions from the 19th century are also heading to that 16-bit flipover point.
Then, at 12:00:00 precisely, BANG! (Huge puff of smoke.)
I thought I'd better take a photo of the updated signboard.
Like we said, we get some great stories here at Naked Security, and we loved this one, plus the picture to prove that it all ended well.
But we couldn’t help but wonder, of all the things a concerned observer might worry about at the firing of the Noon Gun, if integer overflow was really the big one.
We think we’d have been more concerned about problems such as, “Has anyone ever inadvertently put a cannon ball down the muzzle when loading it, out of habit?”
Oh, and, “What kind of programmer ignores a giant red flag?”
[*] Apparently, the Noon Gun is not fired on Sundays. So 65535 firings is actually just over 200 years, and since the practice was started by the British, that ties in with the British takeover of the Cape in 1806.
PS.You can follow the Noon Gun on Twitter. There’s a certain rhythm to its tweets, in a repetitious sort of way. But it will raise the alarm if anyone ever forgets.
“I’m a cannon, shoot me.” Just seemed amusing.
The most impressive thing about the gun (as seen from the SA NAVY sign) is that it is powered by a Lithium Ion Battery.
I *think* you may find that a different sort of lion is being talked about here. And a somewhat more punishing type of battery 🙂
(Seems that Signal Hill is also known as Lion’s Rump because it’s one end of a ridge that has Lion’s Head at the other end. Apparently the ridge is supposed to look Sphinx-ish. Wikipedia has some pictures.)
http://en.wikipedia.org/wiki/Lion%27s_Head_%28Cape_Town%29
http://en.wikipedia.org/wiki/Signal_Hill_%28Cape_Town%29
If the lion gunners never miss the BANG! tweet and never let the Signal_Hill_Gun tweet anything else, then they will trigger the same integer overflow point for the tweet count at firing number 65535-203=65332, which will be in the year 2224 – if the gunning habits stay constant.
At least from that point in time it is still a while until the five-digit-problem for the year count arises. 2.434.338 more smoking guns. Pretty sure, they willl need the second barrel until then.
BTW: I had to manually add 1 to calculate the last result, because Excel is not recognizing 01.01.10000 as a valid date. So you see, that this problem is really neglected and already prevalent today.
Don’t you mean “unfazed”?
(Your speech recognition software and spell chequer didn’t pick this one up!)
I meant “unphased,” as in “not knocked out of step” or “able to remain on time, on target.”
(For all that my Oxford Dictionary of English insists that “faze” is not related to “phase” and should not be written that way, it also notes that 25% of its appearances in the Oxford English Corpus spell it like it I did, even when “fazed” was intended. The Oxford lexicographers also provide what sounds to me like an unlikely etymology – that it’s a 19th century US dialect word from an Old English of unknown origin, “fesian.” Seriously? Or is it just a corruption of “phase”, adopted into everyday language at the height of America’s industrial revolution?)
Anyway, the gunners were no doubt unfazed as well…
Don’t you mean “spell checker”? 🙂
I think he meant “spelt chukka,” which is a period of play in a game of polo that is played on special grass.
What sort of programmer ignores a red flag? er … any sort?
Be honest…when was the last time you checked the value of the auxiliary carry flag? Or the parity bit? Do you always check that realloc() succeeded, even when you are shrinking a memory block?