Archive | April, 2009

Preventing access to backup PHP~ files in Apache

Many Linux command-line people use the VI editor; but if you’re like me and prefer Emacs, you often run into the “problem” that Emacs creates backup files using the original filename and appending a tilde (~) to the end of the filename. E.g. “secret.conf.php” becomes “secret.conf.php~”.

There are a number of ways to go around this, of course. One way is to configure a separate directory for each user where Emacs stores its backup files, and then make that directory readable only by the user.

Why is this a problem? Well, if you’re using Emacs to quickly modify PHP applications’ configuration files, like the database configuration file, you’ll leave a trail of .php~ files. These files are typically not parsed by the PHP processor, instead they are handled by the text file handler in Apache. Meaning, if I enter the url http://myverycoolsite.com/secret.conf.php~, Apache will gladly display its actual contents, just like if you were editing the file.

This can be prevented by using the .. configuration construct in Apache like so:

<Files ~ “\.(html\~|htmls\~|php\~|phps\~|php3\~|php4\~)$”>
  Order allow,deny
  Deny from all
</Files>

Perhaps not the most elegant of solutions, but it works. It will result in an “Forbidden” response from Apache. Check out the Apache documentation for more details on this directive.

You can go back to sleep now 🙂

1

Why the Pirate Bay trial is bullshit

The outcome of the (first) Pirate Bay trial in Sweden is old news by now. You know the story, it’s about the guys behind the BitTorrent site “The Pirate Bay” (www.thepiratebay.org). Nevertheless, I feel the urge to ask the powers that be if they are right in the head, or if this is some sort of compensation for small egos, small genitalia or just a total lack of brain cells.

I haven’t read everything about the trial; because I cannot be bothered. Media is telling the part of the story that sells; the part that sells commercials on TV, the part that sells newspapers and magazines, and the part that make politicians look assertive and important.

Now, one thing should be made clear about this whole thing. The debate isn’t about copyright infringement, nor is the case. I don’t think anyone out there with half a brain would argue that stealing is ok. Most people know that walking into a grocery store and grabbing some milk & cookies without paying for it is actually theft. Had this trial been about the theft of intellectual propery, it would have been an open and shut case. But alas, it is not.

If the case is about the theft of intellectual property rights, where is the proof from the owners of these rights that the awarded sum of SEK 30,000,000 is actually a representative figure? How does one prove how “much has been stolen” in a digital world? The claim was initially for SEK 100,000,000. So in a country where one is supposed to be innocent until proven guilty, the state has “proven” that 30,000,000 is a reasonable sum. Or did they?

If the Pirate Bay trial shows anything, it shows that the laws and regulations of intellectual property rights are outdated to say the least. Few things have evolved at the same speed the Internet has. Let it be stated: this case won’t change a thing; it will not prevent file sharing or illegal distribution of digitized media, nor will it scare people for long. What it will do is to force the development of better, faster, and more efficient proxy-services for people who want to continue doing what they were doing before the trial ended. And people will be willing to pay money for these services.

By the same token, the state should sue the owners of YouTube since YT has tons of copyrighted material; the state should go after owners of MP3 players since they can be used for theft of intellectual property rights.

Come to think of it, here are some things that should be made illegal:

  • VCRs and digital TV boxes with recording capabilities; I mean, I could record something and send it to someone else.
  • The Internet; hey.. do I need to say more.
  • Anything that can be used as a weapon; here we should sue the manufacturers, since it’s obviously their fault. If I smash someone in the head with a toaster made by Philips, obviously Philips needs to be taken to court. They should assume the cost of the trial, as well as any money awarded for damages.

The people behind the Pirate Bay are being used as scapegoats for the millions of “criminals” (ordinary people) that the record and media companies cannot get at. These guys are paying the price for the fat executives’ anger.

If the Pirate Bay are responsible for the people using it to break the law, are the banks also responsible for the trillions of dollars being laundered every day in the banking system throughout the world? If not, why not? If they are, why aren’t we bringing them down?

If you cannot stop something with brute force, you need to find another solution. This has been debated for a number of years in Sweden, but the politicians are busy inspecting their inner person with their head (I’ll let you figure out where they have their head to be able to do that).

Sweden has a special “penalty tax” for certain types of media such as CDs and DVDs. Part of the “income” from that tax goes to organizations that “protect” artists’ rights. So here’s the next question: who stores music or movies on CDs and DVDs these days?

Sweden has a special fee for “public service television”. The fee should be paid for each TV receiver you own, including VCRs, digital TV boxes, TV sets, etc. Of course, nobody pays the fee twice and many people don’t bother paying the fee at all.

There is no such tax on Internet services like ADSL, VDSL, residential broadband, etc. Why not? Simply put the tax on each connectivity service, everybody pays. Do the same thing with the “public service television” fee. Everybody pays. Let’s say we have three million Internet connectivity accounts in Sweden (it’s probably a lot more since some people have both residential ADSL as well as a mobile broadband account); add SEK 50 per month per account to the connection fee. That’d be SEK 150,000,000 per month, times 12 we get 1,800,000,000 or SEK 1.8 billion per year. Now, you tell me this wouldn’t make up for the “loss in revenue”?

This trial is about a justice system being bullied by fat media companies that have been unable to capitalize on the positive sides of the Internet. The reason they have been unable to embrace technology is because they are not well prepared for a decentralized market.

And guess what, you are paying for it.

The record store is dead. The CD and DVD are dead. Boo-hoo. Move on, get with the 21st century, that’s where the rest of us are.

3

I am me

My feet need to feel the earth, my nose needs to smell the air, my eyes need to see the trees, and my ears need to hear the water. I am all those things, and I need all those things. I am complex and simple, I am weak and I am powerful. I am me.

0

HyresgÀstföreningen sviker sina medlemmar igen

“’VĂ„rt förslag tryggar hyresrĂ€ttens framtid’’
– HyresgĂ€stföreningen och de kommunala bostadsföretagens organisation, SABO har kommit överens om ett förslag till hur regelverket kring allmĂ€nnyttan och hyressĂ€ttningen bör tillĂ€mpas i framtiden. – VĂ„rt gemensamma förslag skapar stabila och lĂ„ngsiktiga lösningar för allmĂ€nnyttan och hyressĂ€ttningen i framtiden. Det Ă€r bra för bĂ„de hyresgĂ€ster och hyresvĂ€rdar, sĂ€ger Barbro Engman, förbundsordförande pĂ„ HyresgĂ€stföreningen.

En bra illusion gÄr ut pÄ att man lyckas avleda nÄgons uppmÀrksamhet frÄn nÄgot uppenbart, sÄ att det uppenbara framstÄr som hÀpnadsvÀckande och pÄ grÀnsen till det omöjliga. SÄ skulle man ocksÄ kunna sammanfatta HyresgÀstföreningens stöd till sina medlemmar. Allt oftare gÄr man de privata hyresvÀrdarnas Àrenden, allt oftare hamnar den lilla mÀnniskan i klÀm. Och vem Àr dÄ denna lilla mÀnniska som hamnar i klÀm? Jo, det Àr HyresgÀstföreningens medlemmar. De som betalar medlemsavgifter för att HyresgÀstföreningen skall representera dem och deras intressen i hyresfrÄgor.

DĂ€r vi bor, pĂ„ Hjalmar Söderbergs VĂ€g i Kristineberg pĂ„ Kungsholmen i Stockholm, sĂ„ uppstod det en “olösbar” situation under hyresförhandlingarna 2007 mellan HyresgĂ€stföreningen och hyresvĂ€rden, Arbetarebostadsfonden. Förhandlingarna strandade och Ă€rendet skulle tas upp i hyresnĂ€mnden. TvĂ„ Ă„r senare (!) sĂ„ har hyresnĂ€mnden givit sitt utlĂ„tande, vilket i praktiken innebĂ€r en retroaktiv (!) hyreshöjningen med ett snitt pĂ„ 12% frĂ„n april 2007. Arbetarebostadsfondens största argument Ă€r höjda kostnader för underhĂ„ll. Uppenbarligen valde hyresnĂ€mnden att gĂ„ pĂ„ vĂ€rdens linje. HyresgĂ€stföreningen verkar inte vara sĂ€rskilt intresserade av att göra nĂ„gonting alls. Fastigheterna som hyreshöjningen gĂ€ller Ă€r i sĂ„ dĂ„ligt skick att man undrar hur nĂ„gon som borde ha detta som sitt yrke och dĂ€rmed vara bra pĂ„ det kan undgĂ„ att se bristerna.

  • ventilationen Ă€r sĂ„ undermĂ„lig att hyresvĂ€rden sjĂ€lv rekommenderar att flĂ€ktar i badrum stĂ„r pĂ„ dygnet runt. SjĂ€lvklart bekostar hyresgĂ€sten kostnaden för elektriciteten
  • det gĂ„r inte att fĂ„ tillgĂ„ng till modern kabel-TV och/eller bredband eftersom nĂ€tet i fastigheterna Ă€r ett s k “kaskadnĂ€t” frĂ„n tiden dĂ„ det levererades av StjĂ€rn-TV. SĂ„ledes mĂ„ste alla hyresgĂ€ster sjĂ€lva bekosta bredband. Vill man ocksĂ„ ha nĂ„gon form av modern TV-mottagning sĂ„ fĂ„r man bekosta marksĂ€nd digital-TV (t ex via Boxer) sjĂ€lv eftersom ComHem inte kan leverera alla sina tjĂ€nster i detta nĂ€t pga nĂ€tets Ă„lder
  • fönster lĂ€cker som sĂ„ll; trĂ€karmar och lister Ă€r ruttna efter minst 10 Ă„r utan nĂ„got underhĂ„ll
  • nĂ€r temperaturen gĂ„r ned under fem (5) plusgrader sĂ„ Ă€r det fysiskt omöjligt att fĂ„ det varmare Ă€n 15 grader i nĂ„gra av sovrummen. Detta har pĂ„pekats bĂ„de till HyresgĂ€stföreningen och Arbetarebostadsfonden i 10 Ă„rs tid utan nĂ„gon som helst kommentar eller Ă„tgĂ€rd
  • hissar stĂ„r stilla 10-20 ggr per Ă„r; detta har pĂ„gĂ„tt i 10 Ă„r, trots att man sĂ€ger sig ha Ă„tgĂ€rdat problemet sĂ„ uppstĂ„r det om och om igen
  • trapphus, kĂ€llare och tvĂ€ttstuga Ă€r alltid smutsiga; inför hyresnĂ€mndens inspektion mĂ„lade Arbetarebostadsfonden om golven i kĂ€llaren – tydligen sĂ„ lyckades den finten bra
  • lĂ€genheterna Ă€r generellt sett slitna
  • det har varit problem med kvaliteten pĂ„ vattnet, bĂ„de det varma (temperatur) och kalla under 10 Ă„rs tid

Att Arbetarebostadsfonden höjer hyrorna i olika omrÄden för att bekosta uppköp av nytt bestÄnd i andra omrÄden Àr sedan lÀnge nÄgot alla vet om; man höjer alltsÄ inte hyrorna för att höja standarden pÄ respektive bestÄnd.

Uppenbarligen spelar det ingen som helst roll. Man fÄr bete sig precis hur svinigt som helst mot sina hyresgÀster. Ett stort tack till HyresgÀstföreningens representanter, ni har verkligen visat att ni tar uppdraget pÄ fullaste allvar, och bryr er om era egna löner och samarbetet med hyresvÀrden. För det var vÀl det som var uppdraget.. ?

LÀnge leve hyresrÀtten!
LÀnge leve HyresgÀstföreningen!
LÀnge leve hyresnÀmnden!
LĂ€nge leve Arbetarebostadsfonden!

0

Fördelen med standarder

”Fördelen med standarder Ă€r att det finns sĂ„ mĂ„nga att vĂ€lja bland”

Hur man möjliggör missbruk av tekniska standarder genom lathet, snÄlhet, ovilja och en oförmÄga att lÀsa innantill; kort sagt, en seriös skopa inkompetens. Ett raljerande inlÀgg i teknikdebatten av Joaquim Homrighausen, WebbPlatsen i Sverige AB, joho@webbplatsen.se.

Genom att tĂ€nja pĂ„ grĂ€nser har vi nĂ„tt sann innovation inom flera omrĂ„den, sĂ„ Ă€ven IT. Varje minut klĂ€cker nĂ„gon nĂ€sta storsĂ€ljande webbtjĂ€nst, varje dag lanseras det nya sĂ€kerhetsprodukter som skall förbĂ€ttra vĂ„ra liv tillsammans med Internet, och varje dag kommer det s k ”trendanalyser” (som ofta Ă€r dĂ„ligt maskerade sponsrade ”undersökningar”) och rapporter om nya hot.

En stor del av Internet skulle fungera sÄ mycket bÀttre om beslutsfattarna förstod vad teknikerna hÄller pÄ med, och om samma beslutsfattare förstod vilka konsekvenser det fÄr nÀr tekniker inte gör det de borde göra.
Protokoll

Att kommunicera Àr inte sÄ svÄrt, för det mesta. Man hittar nÄgon gemensam form av dialog och tar fasta pÄ den; det kan vara ett sprÄk, en metod, en princip, osv. För mÀnniskan rÀcker det inte med att vi har riktiga religionskrig, vi mÄste hitta pÄ vÄra egna. I ett rum fullt av duktiga systemutvecklare tar det förmodligen mindre Àn 30 sekunder att skapa ett verbalt inferno genom att pÄstÄ att ett sprÄk eller en metod Àr bÀttre Àn den andra. Alltid Àr det nÄgon som kÀnner sig trampad pÄ tÄrna.
Continue Reading →

0

Powered by WordPress. Designed by WooThemes