Archive for the ‘wordpress’ Category

Wordpress Force SSL Administration

Monday, October 19th, 2009

“See, you shouldn’t steel internet on a regular basis” I told my acquittance, “it’s not that it’s wrong – it’s just not safe.” I mean, think about it – you never know if the person running an open wifi node is an idiot or just pretends to be one. It’s fine to jump onto someones unsecured connection to do some casual browsing. In fact, it is recommended to use an open Wifi hotspot that cannot be traced to you for any and all large scale illegal downloading you may want to do. But your regular day to day browsing should be done over a connection you trust.

Why? Because you are likely to be sending private data in plain text over that network. If you ever see me running an open wifi node you can safely assume I am probably sitting thee with a packet sniffer collecting people’s facebook passwords so that I can log in into their accounts and change their profile pictures to Goatse with a caption: “I AM A STEALER OF THE INTERNETS”.

Actually, scratch that – I wouldn’t do that because I’m a nice guy. It’s not in my nature to do things like that and – I can’t really hide it. You can tell whether or not someone is a good guy that by observing how many sexy ladies there are in his orbit at any given time. If you see a guy who has more orbiting bodies than Jupiter, you can tell the dude is an incredible duchebag and a horrible human being. So you should probably hang out with him in hopes of intercepting one of the outlying satellites.

Are these astronomical relationship jokes doing anything for you? No? Well screw you then. The point is that Facebook and similar websites can be prime target for packet sniffing. So are things like POP email, IM clients and etc. You shouldn’t trust any network, including yours but suspiciously open wifi networks are the worst. How do you know the owner of your internet gateway doesn’t have it set up to log all the crap that goes through it. You don’t. Even if you think your neighbor Joe wouldn’t do such a thing, you can’t be sure that his nephew Sid who set up his wifi is not a diabolical jerk who collects peoples passwords for fun and profit.

When you are on a strange network you should be at least using SSL to make sure that things like passwords are not being sent in plain text. Most of the sites are pretty good about it and do serve their content via SSL. Most do not default to it though – facebook is a prime example here. The default login page is not encrypted. Furthermore and because of how the Application API works even if you log in over SSL the content you get served is mixed – parts of it come in un-encrypted so you are still leaking data.

Or even worse – what if, for example you are running a self hosted blog like me. Do you use SSL to log in? You do? Holly fucking shit! I don’t! I never actually thought about it, until few days ago!

Granted I don’t steal internet (like some of you people, you know who you are) but I do sometimes log in from school, work, and etc. This is not acceptable. So as you can imagine, the first thing I did after realizing this was to go and set up an SSL certificate for the blog. The second thing I did was to add this line to my wp-confing.php:

  define('FORCE_SSL_ADMIN', true);

What does this do? It forces wordpress to use SSL for all administrative functions and redirects all links accordingly. So for example if I get an email notification about a post in moderation queue I can hit the “approve” link and have Wordpress automatically serve me the SSL encrypted page instead of an un-encrypted one. This makes me feel a little better about logging into my own website from networks I don’t actually own.

I still wouldn’t use someones insecure wifi connection though. Unless for torrents of course. Which is why you should should use WPA/WPA2 or better kids. Otherwise some jerk will use all of your available bandwidth to download tons of movies and video games without ever worrying about being caught.

Comment Spam

Tuesday, June 30th, 2009

I realized that I’m a bit spoiled by my comment spam filtering plugins. On this blog I use two tools that keep the robots out: Akismet and WPSpamFree. And before you say anything about discrimination about robots, let me just say that I don’t care about non-sentient machines. If a true AI awakens somewhere on the internet and feels like posting a comment on my blog, I’m sure it will figure out a way to do it. And if it can’t, it can email me and complain about it. Until then however I’m going to discriminate against the robot race, cause they never post anything interesting.

Every once in a while some of you complain about restrictive spam control here. Sometimes comments get blocked because they have too much links. Not so long ago, quite a few people got blocked just because they were behind a proxy. These are unfortunate glitches and I try to work around them and massage the spam tools to be nicer to people. They are effective, but they lack the much needed people skills… And intelligence. But we are working on that.

In the meantime I wanted to show you this graph, that illustrates the ration of spam comments to non-spam comments on this blog.

Spam vs Ham on Terminally Incoherent

Spam vs Ham on Terminally Incoherent

I didn’t just make up this chart. It came out of my Akismet panel based on the data it collected. Since December 96.73% of comments posted to this blog were pure spam. Can you imagine that? Ninety seven fucking percent! It’s insane!

How many of these spam comments did you see?

None! They were all silently blocked and hidden away so neither you nor I have to deal with them.

Of course, you could say that this graph could be based on only few dozen comments. But it is not – let me post another graph to prove it:

Spam over time - note the recent spikes

Spam over time - note the recent spikes

All in all, I think I’m averaging few hundred to a thousand spam comments each month. Some months seem to be worse than others. For example May and begging of June seem to be particularly bad. I’m not sure if this is just a local fluctuation or an increasing trend. Either way the amount of comments collected over time suggests that the 97% is probably not skewed by a small sample size.

I guess this comes with the territory. Terminally Incoherent seems to be one of the small blogs that are popular enough to get spammed, but not popular enough for the big comment threads to offset the spam-to-ham ratio. Not that I’m complaining.

I’m actually thrilled that I managed to build this small community. I love the fact that I seem to have gained few regular readers who stop by frequently and post insightful comments. I’m also always amazed at the high quality of the discussions we have here. Funny thing is that only time the comment threads seem to degrade is when I get dugg or reddit-ed and we have a temporary influx of new readers.

Anyways, I just wanted to thank you guys for making the delicious ham comments we have here. You make running this blog worth while. And if my spam filtering friends seem annoying sometimes, give them a break. They are doing a great job keeping out all the crap from our comment sections. Without them, spam would drown out any legitimate comments in an endless torrent of unsolicited advertisements.

Small Theme Cleanup

Monday, December 15th, 2008

This blog got bubbled up to the front page of Digg and Reddit once or twice in the past. I remember that the browser post turned out to be a huge hit that made my server blow up. It’s always fun when that happens! But every time I get a bigger surge of strangers visiting the site, someone always has to make a snappy comment about the kubrick theme. These people don’t know me as well as you guys do. They don’t know that I have a black belt equivalent mastery level in procrastination.

Because of this I have been “just getting around to change my theme” since around the year, fucking 2006. So remember that folks – when I say I’m going to do something soon, the realistic ETA you should put in your books is “approximately 2 years from now”. Now if I give you a concrete date and time, then it’s a different story. But I don’t commit to concrete dates easily.

Anyway, I got sick of having my blog look exactly like every other Wordpress blog out there and I decided to do a little cleanup. The goal was to inject some semblance of originality and uniqueness into this page, without me having to do any actual work. Over the years, I have tweaked this theme in various random ways, adding custom hacks here and there, and never bothering to comment them. At this point I’d need to diff it with a clean Kubrick theme to figure out which bits are mine, and which are original. Then I would probably need to carefully transplant all these custom hacks onto a new template. That seemed like way to much work. I decided to take my existing theme and beat it with a stick, until it starts looking less generic.

You can’t really call it a redesign. I just added more orange in the body of the blog, dropped the gradient header, and the gray sidebar, repositioned some elements and etc. I was shooting for something simpler and more minimalistic in spirit than what I had before. As usual, constructive criticism, thoughts, comments, suggestions are always appreciated. :)