<?xml version="1.0" encoding="iso-8859-1"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/">
	<channel>
		
		<title>hellinga.org: Latest News</title>
		<link>http://www.hellinga.org/</link>
		<description>Latest news from hellinga.org</description>
		<language>en</language>
		<image>
			<title>hellinga.org: Latest News</title>
			<url>http://www.hellinga.org/EXT:tt_news/ext_icon.gif</url>
			<link>http://www.hellinga.org/</link>
			<width></width>
			<height></height>
			<description>Latest news from hellinga.org</description>
		</image>
		<generator>TYPO3 - get.content.right</generator>
		<docs>http://blogs.law.harvard.edu/tech/rss</docs>
		
		
		
		<lastBuildDate>Mon, 07 Sep 2009 12:45:00 +0200</lastBuildDate>
		
		
		<item>
			<title>Iphone 3g, TomTom, JVC kd-r801, Brodit carkit (navigation, music and calling)</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=13&#38;cHash=9d605db41f</link>
			<description>Being an owner of the Iphone 3g since the day of release i was waiting for TomTom to release their...</description>
			<content:encoded><![CDATA[<p class="bodytext">Being an owner of the Iphone 3g since the day of release i was waiting for TomTom to release their app. When they released it i was eager to try it.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">At first the app seemed to work fine. After a few weeks of navigating i came to the following experience. The first problem with TomTom on the iphone is that it frequently thinks you're on a road next to the one you're on. This means that TomTom has to recalculate the route way to often. Especially when you're navigating in a city where you have turn after turn it's very inconvenient that it looses your exact position. This will result in missing a turn if you have no knowledge of the location.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">I use the Iphone 3g in combination with the JVC kd-r801 car-audio system. The Iphone is docked in the Brodit active holder pass through and is provided with current trough the usb-port on the front of the receiver. Trough this connection i can also play and control the music i have on my Iphone. The bluetooth connection is used for calling. If the usb port is connected befor the bluetooth has connection the audio will stream trough the bluetooth connection. You can't control the music trough the bluetooth connection so i always wait till the bluetooth connection is up. This takes about 10 seconds. You're phonebook, received and made calls are synced with the radio automatically. </p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">If you make or receive a call the TomTom application will be terminated. So no navigation while calling. After you've finished the call the TomTom application will try to restart. On my Iphone it always fails and i have to start the app manually. </p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">Then there are the crashes. Every now and then while i'm cruising in my car the Iphone will crash and do a complete reboot. It will take about 2 minutes before the Iphone is up and running. Maybe navigating, calling and listening to music is a bit more then the Iphone can handle. </p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">Concluding this post i can say TomTom has an average initial release. It can use the GPS boost from the TomTom-carkit they are promising. The crashes are very inconvenient but i can't say if TomTom is to blame for that. Calling and controlling the music works fine for me. I am very pleased with the JVC receiver in combination with the Iphone although there is enough room for improvement from the Iphone side. </p>
<p class="bodytext">&nbsp;</p>]]></content:encoded>
			
			
			<pubDate>Mon, 07 Sep 2009 12:45:00 +0200</pubDate>
			
		</item>
		
		<item>
			<title>Web Analytics</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=12&#38;cHash=c3e4c32c0a</link>
			<description>Thirteen months since the last post, that's a bit long....

A couple of days ago i stumbled upon...</description>
			<content:encoded><![CDATA[<p class="bodytext">Thirteen months since the last post, that's a bit long....</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">A couple of days ago i stumbled upon <a href="http://www.piwik.org" target="_blank" >www.piwik.org</a></p>
<p class="bodytext">I wasn't looking for such a tool but i just happened to run into it, and cought my attention.</p>
<p class="bodytext">Everybody (or almost everybody) knows google analytics, a tool to gather information about your visitors on your website. This is an open-source alternative.</p>
<p class="bodytext">Not everyone, including me, is willing to put all his information at google. I didn't use google analytics for this reason and since i have awstats for my websites i didn't need to. But piwik seemed easy to install, (it was actually) and you keep in full control of your data. </p>
<p class="bodytext">You place your piwik install on a centralised place you add a website in it's management interface and all you have to do then is place a little piece of code into your websites source code. Or if you're a TYPO3 user like me, install the piwik extension and add 4 lines of code in your template.</p>
<p class="bodytext">After that sit back, take a cup of coffee and wait for your visitor data to gather. </p>]]></content:encoded>
			<category>SysAdmin</category>
			
			
			<pubDate>Thu, 23 Apr 2009 08:42:00 +0200</pubDate>
			
		</item>
		
		<item>
			<title>Countermeasures</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=11&#38;cHash=d2b63383bd</link>
			<description>I don't mind having visitors on this website, i don't even mind if it are more than a thousand in a...</description>
			<content:encoded><![CDATA[<p class="bodytext">I don't mind having visitors on this website, i don't even mind if it are more than a thousand in a week but i do mind if it are spammers and every single one decides to leave a [censored] comment.</p>
<p class="bodytext">So after being sick and tired of cleaning up spam messages once in a while and especially more than a thousand in a week i decided to put up some effort installing some countermeasures against spam. In this case &quot;captcha&quot;.</p>
<p class="bodytext">If you wish to leave a comment it's almost as easy as before, you just need to type a few letters more and i hope it saves me a lot of trouble cleaning up my database :)</p>]]></content:encoded>
			<category>General</category>
			<category>TYPO3</category>
			
			<author>lh@bulletgate.org</author>
			<pubDate>Tue, 11 Mar 2008 20:31:00 +0100</pubDate>
			
		</item>
		
		<item>
			<title>Traffic Monitoring</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=10&#38;cHash=ba67e0164a</link>
			<description>Almost all day i'm busy trying to fix a bug in one of the websites we created for a customer. At...</description>
			<content:encoded><![CDATA[<p class="bodytext">Almost all day i'm busy trying to fix a bug in one of the websites we created for a customer. At the end of the afternoon around 5 PM i was still unsuccesfull solving it so i decided to work a bit more on the problem from home. When doing so i had a couple of terminals open to the company servers for editing files and keeping track of the logfiles, nothing unusual when suddenly my sessions started lagging. And if there's something i hate it's&nbsp; lag on my terminals.</p>
<p class="bodytext">So i've logged on to my homeserver checking out the traffic on my external interface. I've got a 8/1Mbit connection at home and when opening iptraf i've noticed that i was uploading something @ almost 130 kbyte/s which is the total capacity of my upstream. Finding this unacceptable i've checked out the most common services for generating a lot of traffic but i couldn't find anything unusual except for the high amount of traffic off course. And since i'm not having any windows machines at home that also couldn't be the problem.</p>
<p class="bodytext">Then you start asking yourself the question how do i monitor the traffic and how do i see whereto and at what speed is traffic being sent. After a bit of searching at google and asking a friend on IRC i discovered the program &quot;jnettop&quot; so i installed it quickly and started it for monitoring my external interface. I quickly noticed i generated high amounts of traffic directed to the company mailserver. I seemed my client found it nescesary to copy some message to the mailserver so i've killed my mail client and remove some local cache when i find some time for it.</p>
<p class="bodytext">So if you find yourself generating lots of traffic but you don't know who or wat is generating it then remember &quot;jnettop&quot; it quickly shows you how many traffic is going to which server.</p>]]></content:encoded>
			<category>SysAdmin</category>
			
			<author>lh@bulletgate.org</author>
			<pubDate>Fri, 18 Jan 2008 21:41:00 +0100</pubDate>
			
		</item>
		
		<item>
			<title>M-Audio Midisport Uno and Mac OS X Leopard (10.5)</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=9&#38;cHash=3f60768d27</link>
			<description>I sometimes like to fiddle around with some producing tools trying to create some music. Back in...</description>
			<content:encoded><![CDATA[<p class="bodytext">I sometimes like to fiddle around with some producing tools trying to create some music. Back in the Tiger days i used to use my M-Audio Midisport Uno for this, unfortunatly this device doesn't work with Leopard yet :(</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">Though M-Audio was quite fast welcoming Leopard on their website and i quote: </p>
<p class="bodytext">&quot;M-Audio works closely with Apple to ensure future support of new operating system&quot;</p>
<p class="bodytext">if this were true they would have had drivers available (beta?) before Leopard was officially released. But after almost a month they still don't have Leopard drivers.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">After some searching on the internet again i found a way to make the following devices work with Leopard:</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">MidiSport UNO</p>
<p class="bodytext">MidiSport 1x1</p>
<p class="bodytext">MidiSport 2x2</p>
<p class="bodytext">MidiSport 4x4</p>
<p class="bodytext">MidiSport 8x8</p>
<p class="bodytext">KeyStation (old models: 49, 61)</p>
<p class="bodytext">Oxygen8 (v1)</p>
<p class="bodytext">Radium 49</p>
<p class="bodytext">Radium 61</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">So if you've got one of these devices, good news for you:</p>
<p class="bodytext">It's quite easy to set up, surf to the m-audio website and download the driver for your device for tiger: 10.4.10 and install them.</p>
<p class="bodytext">then surf to: <a href="http://namedfork.net/midisportloader/" target="_blank" >namedfork.net/midisportloader/</a></p>
<p class="bodytext">and follow the install instructions.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">It made my M-Audio Midisport Uno USB work with Leopard. Many thanks for this nice piece of software.</p>]]></content:encoded>
			<category>General</category>
			
			<author>lh@bulletgate.org</author>
			<pubDate>Fri, 23 Nov 2007 16:38:00 +0100</pubDate>
			
		</item>
		
		<item>
			<title>How to write a TYPO3 extension (frontend plugin)</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=8&#38;cHash=5efdff93cc</link>
			<description>This document is writen for the single purpose of helping people start developing their TYPO3...</description>
			<content:encoded><![CDATA[<h2>Preparation</h2>
<p class="bodytext">Before you start developing a TYPO3 extension you should have a basic knowledge of TYPO3 and PHP. There are enough tutorials and manuals on the internet explaining all that.</p>
<p class="bodytext">TYPO3 has some key components you should understand before you start to develop your extension. The two most important components are the TCA and TCE. That stands for Table Configuration Array and TYPO3 Core Engine. The basics of those components are explained below. If you would like to know more about these components you should go to the TYPO3.org website and look for the core_api. </p>
<p class="bodytext">Befor you start developing you need a working TYPO3 installation. </p>
<h4>Table Configuration Array</h4>
<p class="bodytext">TCA is an global array wich contains all editable database tables and relations between them. The basic TCA array consists of four tables. These tables are:</p><ul><li>pages</li><li>be_users</li><li>be_groups</li><li>sys_filemounts</li></ul><p class="bodytext">All other tables in this array are configured in extensions. The pages table contains the page tree of TYPO3. This tree is the hierarchial tree you will create within TYPO3 that represents your site.</p>
<p class="bodytext">The next two tables are be_users and be_groups. These tables containt the group and user configuration with their rights within TYPO3.</p>
<p class="bodytext">The last default table is the sys_filemounts wich contains the file mounts of the backend users.<br /> </p>
<h4>TYPO3 Core Engine</h4>
<p class="bodytext">The TYPO3 Core Engine handles all data manipulation from the database tables configured in the TCA. It also handles versioning and history of records and the sys_log. It handles all information available in the TCA. By using the TCE and if the TCA has been set up correctly the validity of the database information can be guaranteed. </p>
<p class="bodytext">Becouse the TCE needs a backend user to check it's permissions you can not use the TCEmain features at the frontend of TYPO3.<br /> </p>
<h2>Start of development</h2>
<p class="bodytext">After the TYPO3 installation is completed it's important to start thinking about how to develop your extension. It's important to have a complete picture about your extension. The main two reasons are:<br /> </p><ul><li>When developing software you can 	only create a solid base for your software if you know the details 	of what your going to create.</li></ul><ul><li>To make life easy on you TYPO3 has 	the extension “kickstarter”. This extension can be used to 	create the framework for your extension, but it can't be used to 	make changes later on in you development process.</li></ul><p class="bodytext">If you have to save data in your extension you have te create the tables in the TCA explained earlyer. If you do this by hand it's a very difficult job and it's very easy to create bugs. For this reason TYPO3 has the extension kickstarter which you can only use as a kick start for your extension. With the kickstarter it's very easy to create all the tables, columns and relations beteween them. It also guarantees the integrity of the TCA. </p>
<h2>Kickstarter</h2>
<p class="bodytext">The kickstarter is the ideal tool to create the framework for your extension. You can't only configure all database properties for your extension but you can also create the whole setup. Within the kickstarter you have a number of properties. These are:</p><ul><li>General info</li><li>Setup languages</li><li>New Database Tables</li><li>extend existing tables</li><li>Frontend Plugins</li><li>Backend Modules</li><li>Intergrate in existing Modules</li><li>Clickmenu items</li><li>Services</li><li>Static TypoScript code</li><li>Tsconfig</li></ul><p class="bodytext">These properties describe each component of an extension. Most extensions do not need all of the components. When you have configured the components you need you can let the kickstarter write your extension to the extension directory. At this point it's important to test your partialy working extension to be surtain you havn't forgotten any options. Most times you'll find a column missing within the database tables. At this point you can still easily add it through the kickstarter. After you start writing PHP within you extension the kickstarter can't be used anymore because it will overwrite any changes you've made.<br /> </p>
<h2>Front end development</h2>
<p class="bodytext">When your basic configuration of the extension is completed you can start writing PHP. For outputting HTML to the browser TYPO3 has a templating engine. You can add markers in a HTML template which can be parsed within TYPO3. A template can contain markers for single items, parts from a template and a endless depth of subparts. The TYPO3 way for repeating parts is done within the PHP code of your extension. This means that there's not a function that will repeat parts from your template that for example adds new table rows. For more detailed information about templating there's a link at the bottom of this document.<br /> </p>
<h2>Backend configuration</h2>
<p class="bodytext">TYPO3 has an excelent way of creating configuration options for your extension. This is done by flexforms and is only usefull if you have a frontend plugin in you extension. Flexforms are forms written in XML which contain options for your extension. You can also call functions from your extension to fill sertain fields with information from for example the database. How flexforms work and how you can create them is explained at one of the links at the bottom of this document.<br /> </p>
<h2>Multi language</h2>
<p class="bodytext">There are two parts of multi language features that i would like to describe here. The first part is multi language in the backend of TYPO3. The second is multi language in the frontend of TYPO3. The default language of TYPO3 is english. When developing an extension it's recommended that you choose english as the default language. It's the TYPO3 way and it'll probably save you trouble later on.<br /> </p>
<h4>Backend</h4>
<p class="bodytext">In the backend you can configure the languages you want to support within you extension within the kickstarter. For each language you select you'll see that there's a new field for each database column where you can add the translation. If you want to support multiple languages in your flexforms it's done by using XML files. Details about how to create these XML files you can read at the localization link at the bottom of this document.<br /> </p>
<h4>Frontend</h4>
<p class="bodytext">TYPO3 knows in which language you are working so by calling the getLL('label') function you will get the correct translation for the label given as a parameter. The function is available in the TYPO3 class “tslib_pibase”. Your main class will extend from this class so you can call $this-&gt;getLL('label') from within this class. If the translation isn't found it'll return the translation from the default language. The XML file that contains the translations is created in the same way as the backend XML translationfile. </p>
<h2>Useful links</h2><ul><li><p>TYPO3 core 	api:<br /><a href="http://typo3.org/documentation/document-library/core-documentation/doc_core_api/4.1.0/view/toc/0/" target="_blank" >http://typo3.org/documentation/document-library/core-documentation/doc_core_api/4.1.0/view/toc/0/</a></p> 	</li><li><p>Extension Development, using 	HTML-Templates:<br /><a href="http://wiki.typo3.org/index.php/Extension_Development%2C_using_HTML-Templates" target="_blank" >http://wiki.typo3.org/index.php/Extension_Development%2C_using_HTML-Templates</a></p> 	</li><li><p>Extension Development, using 	Flexforms:<br /><a href="http://wiki.typo3.org/index.php/Extension_Development%2C_using_Flexforms#FlexForms_In_Action" target="_blank" >http://wiki.typo3.org/index.php/Extension_Development%2C_using_Flexforms#FlexForms_In_Action</a></p> 	</li><li><p>Localization (language) 	handling.<br /><a href="http://typo3.org/documentation/document-library/core-documentation/doc_core_inside/4.1.0/view/3/8/" target="_blank" >http://typo3.org/documentation/document-library/core-documentation/doc_core_inside/4.1.0/view/3/8/</a></p> 	</li><li><p>Extension Developers 	Guide<br /><a href="http://wiki.typo3.org/index.php/Extension_Developers_Guide" target="_blank" >http://wiki.typo3.org/index.php/Extension_Developers_Guide</a></p> </li></ul>]]></content:encoded>
			<category>TYPO3</category>
			
			
			<pubDate>Mon, 27 Aug 2007 15:03:00 +0200</pubDate>
			
		</item>
		
		<item>
			<title>Import a CSV File into a MySQL Table</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=7&#38;cHash=9a870a9f46</link>
			<description>Today i found myself having a CSV file (or Comma Seperated Values) with over 432000 lines. But for...</description>
			<content:encoded><![CDATA[<p class="bodytext">Today i found myself having a CSV file (or Comma Seperated Values) with over 432000 lines. But for some project i'm working on i would like to have those values inside a MySQL Database. I already knew how to export a table to a CSV file and it seemed silly i would need a PHP script to import a CSV back into the database.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">After searching around a bit i found myself a nice query which perfectly inserts a CSV back into the database. Here's how it works:</p>
<p class="bodytext">Upload your csv file to the database server (in this example we assume it has been uploaded to /home/user/file.csv )</p>
<p class="bodytext">Make sure you have your database and table ready</p>
<p class="bodytext">Then execute the following query:</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">----SNIP----</p>
<p class="bodytext">LOAD DATA LOCAL INFILE '/home/user/file.csv' </p>
<p class="bodytext">INTO TABLE test_table </p>
<p class="bodytext">FIELDS TERMINATED BY ',' </p>
<p class="bodytext">LINES TERMINATED BY '\n' </p>
<p class="bodytext">(field_a, field_b, field_c);</p>
<p class="bodytext">----SNIP----</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">In my case it took about 10 to 15 seconds and then MySQL responded:</p>
<p class="bodytext">Query OK, 432144 rows affected, 1 warning (13.27 sec)</p>
<p class="bodytext">Records: 432144  Deleted: 0  Skipped: 0  Warnings: 0</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">(the warning MySQL complained about was that an additional field in my table didn't have a default value, nothing to worry about.)</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">Of course your table can be much bigger than 3 columns just add them on the last row of the query. If your databasecolumns are built up like a,b,c but your CSV file is ordered like b,c,a enter them as b,c,a in your query so it correponds to the order of your file.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">As you can see this is much quicker as writing a custom PHP script to insert the data into your database.</p>]]></content:encoded>
			<category>MySQL</category>
			
			<author>lammert@hellinga.org</author>
			<pubDate>Tue, 14 Aug 2007 21:16:00 +0200</pubDate>
			
		</item>
		
		<item>
			<title>chmod directories recursively</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=6&#38;cHash=3ead342b71</link>
			<description>Quite often i use &quot;chmod -R 755 something&quot; to set permissions on all things inside a directory but...</description>
			<content:encoded><![CDATA[<p class="bodytext">Quite often i use &quot;chmod -R 755 something&quot; to set permissions on all things inside a directory but today i wanted to do the same but only on directories.</p>
<p class="bodytext">To do this is actually quite simple &quot;find . -type d -exec chmod 755 {} \;&quot; and voila all directories inside your current (and your current too) are chmod'ed 755.</p>]]></content:encoded>
			<category>SysAdmin</category>
			
			<author>lh@bulletgate.org</author>
			<pubDate>Mon, 13 Aug 2007 09:05:00 +0200</pubDate>
			
		</item>
		
		<item>
			<title>TYPO3 and Shared hosting</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=5&#38;cHash=b4ad709a19</link>
			<description>Until now i was used setting up TYPO3 on servers which i own or private servers on which i have...</description>
			<content:encoded><![CDATA[<p class="bodytext">Until now i was used setting up TYPO3 on servers which i own or private servers on which i have full control and PHP isn't running in safe mode. Sometime around last christmas i was asked to create a website for the inn where we were staying at that time. The owners now had arranged a shared hosting package and since i've been using TYPO3 for about the last two or three years this was the obvious choice for their website also.</p>
<p class="bodytext">&nbsp;A few days ago i started uploading the TYPO3 files to get started with the install process which normally is quite easy but soon i realized i was facing a new challenge in my TYPO3 career. The shared hosting account has Safe mode and Safe mode GID enabled and i understand why these settings are enabled. And at this point i wasn't suspecting big problems. I had a little bit of trouble getting the symlinks uploaded which are part of the dummy package, but once i've had created a temporary directory (chmodded 777) and used a little PHP script using the symlink(); command i was able to get the symlinks right.</p>
<p class="bodytext">Soon after that i was facing bigger problems when i started installing TYPO3. It seemed once TYPO3 created a directory it wasn't able to do anything inside anymore, like creating subdirectories. The error i got was quite explaining: All the files belong to user:user (user is the replacement for the real username) but when TYPO3 starts creating files and/or directories they are set to httpd:httpd which is the user running the webserver. When TYPO3 tries to create a file or directory inside this directory which belongs to httpd:httpd it replies it isn't allowed because of a safe mode restriction. When safe_mode_gid is enabled at least the group of the executing script in this case &quot;user&quot; must match the group of the directory, in our case &quot;httpd&quot;.</p>
<p class="bodytext">Ok small problem i thought so i did a little search on the internet, found a similar problem and the answer was simple, download the created directories, delete them from the server and upload them, then the user and group are set to user:user. I've managed to get TYPO3 running with this workaround but the joy was for a small amount of time because when i tried to download and install an extension from the TER it complained again about not being able to create directories because of different groups. About the time i was smart enough to search the support forums of the hoster i was very surprised actually finding a topic, out of 8 or so, with the exact same problem i had. You can find the most interesting post <a href="http://forum.surftown.com/viewtopic.php?p=1218&amp;sid=586d136f1a11253c13e8be90520de0ae#1218" title="Opens external link in new window" target="_blank" class="external-link-new-window" >here.</a></p>
<p class="bodytext">After a while trying to decipher the topic (It's a Swedish hosting company and their support forums are also in the Swedish language, and i'm dutch) i found out that you should set the two following variables in your localconf.php which you can find as you probably know in your typo3conf directory:</p>
<p class="bodytext"><strong>$TYPO3_CONF_VARS[&quot;BE&quot;][&quot;fileCreateMask&quot;] = '0660'; <br />$TYPO3_CONF_VARS[&quot;BE&quot;][&quot;folderCreateMask&quot;] = '02777';</strong></p>
<p class="bodytext">Please note that the above is a bit different then the post i mentioned before, the 0 preceding 2777 seems to be needed to get the right mode on a newly created directory.</p>
<p class="bodytext">The following variable should <strong><span class="important">NOT</span></strong> be set:</p>
<p class="bodytext"><strong>$TYPO3_CONF_VARS[&quot;BE&quot;][&quot;createGroup&quot;]</strong></p>
<p class="bodytext">The post also provided a small patch file for t3lib/class.t3lib_div.php but knowing the topic was two years old i thought it was wise to patch the file myself using an editor. You're looking for the function mkdir which in version 4.1.1 of TYPO3 can be found on line 2520. The function after manually patching looks like this:</p>
<p class="bodytext"><strong>function mkdir($theNewFolder) {<br />&nbsp;&nbsp;&nbsp; $theNewFolder = preg_replace('|/$|','',$theNewFolder);<br />&nbsp;&nbsp;&nbsp; $OLD_UMASK = umask(0); <br />&nbsp;&nbsp;&nbsp; if (mkdir($theNewFolder, octdec($GLOBALS['TYPO3_CONF_VARS']['BE']['folderCreateMask']))){<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; //chmod($theNewFolder, octdec($GLOBALS['TYPO3_CONF_VARS']['BE']['folderCreateMask'])); //added this line, because the mode at 'mkdir' has a strange behaviour sometimes<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; umask($OLD_UMASK); <br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; //Surftown - this doesent work: chmod($theNewFolder, octdec($GLOBALS['TYPO3_CONF_VARS']['BE']['folderCreateMask'])); //No... this is because of wrong umask() setting, and it deletes SGID setting <br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if($GLOBALS['TYPO3_CONF_VARS']['BE']['createGroup'])&nbsp;&nbsp;&nbsp; {&nbsp;&nbsp;&nbsp; // skip this if createGroup is empty<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; chgrp($theNewFolder, $GLOBALS['TYPO3_CONF_VARS']['BE']['createGroup']);<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; return TRUE;<br />&nbsp;&nbsp;&nbsp; }<br />&nbsp;&nbsp;&nbsp; umask($OLD_UMASK); <br />}</strong></p>
<p class="bodytext">All this has a few reasons: The config options make sure files and directories are created with a certain mode, and the code change is to make sure that these modes are actually set. The 02777 sets a so called &quot;setGID&quot; bit on the directory and makes it writable for the user, group and others. The change in the code is necessary get the final mode right, in my case the umask mode of PHP defaults to something not 0 and when the directory is created with the defined mask the umask mode first gets subtracted from the defined mask resulting in something not 02777, not what we want.</p>
<p class="bodytext">When i was finished modifying the files i really thought this was going to work, unfortunately it didn't. After fiddling around with some test scripts i wrote i found out that it would be wise to chmod the &quot;fileadmin&quot;, &quot;typo3temp&quot;, &quot;typo3conf&quot;, &quot;uploads&quot; and all the directories inside 2777 using FTP. After doing so i retried installing an extension and finally it worked. </p>
<p class="bodytext">All this cost me about 8 hours of work trying to figure out how to bypass the safemode restrictions. I hope this blog post will help you install TYPO3 in less then 8 hours on a shared hosting account.</p>]]></content:encoded>
			<category>TYPO3</category>
			
			
			<pubDate>Wed, 30 May 2007 19:59:00 +0200</pubDate>
			
		</item>
		
		<item>
			<title>Secure passwords with Netatalk</title>
			<link>http://www.hellinga.org/index.php?id=1&#38;tx_ttnews%5Btt_news%5D=4&#38;cHash=ac68a4c1e8</link>
			<description>Being a Mac user i sometimes want to transfer some file between my mac and my linux server. The...</description>
			<content:encoded><![CDATA[<p class="bodytext">Being a Mac user i sometimes want to transfer some file between my mac and my linux server. The obvious way to do this is using AFP. Debian provides a nice package offering this protocol named &quot;netatalk&quot;.</p>
<p class="bodytext">Easy to install by entering &quot;apt-get install netatalk&quot; on your rootshell. </p>
<p class="bodytext">Easy to configure also just modify /etc/netatalk/AppleVolumes.default with the directory's you want to share. Start the service and you're good to go, however one thing bothered me, whilst connecting to my server using AFP, after entering my username and password, Mac OS X complained about sending my password cleartext over the network, that i didn't like. </p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">So i looked up a manual on the internet for setting up netatalk (which can be found here: <a href="http://netatalk.sourceforge.net/2.0/htmldocs/configuration.html#authentication" target="_blank" >netatalk.sourceforge.net/2.0/htmldocs/configuration.html</a>) here we see we can load several UAM's as they are called to provide secure authentication. The one we definitly don't want is uams_cleartxt.so as it seems the one we want is uams_dhx.so .</p>
<p class="bodytext">Time to open up /etc/netatalk/afpd.conf go all the way to the bottom and uncomment the last line change the -uamlist so it loads up uams_dhx.so and not uams_cleartxt.so (the other options are ok for now) save the file and restart the service. Try to connect and suddenly Mac OS X begins to complain about some error -35 or so. After searching a while i get the clear idea to search in some logfiles, /var/log/syslog suddenly reveals something like: </p>
<p class="bodytext">----snip----</p>
<p class="bodytext">May 26 21:50:27 myst afpd[10447]: uam: loading (/usr/lib/netatalk/uams_dhx.so)</p>
<p class="bodytext">May 26 21:50:27 myst afpd[10447]: uam: uam not found (status=-1)</p>
<p class="bodytext">May 26 21:50:27 myst afpd[10447]: uam: loading (/usr/lib/netatalk/uams_gss.so)</p>
<p class="bodytext">May 26 21:50:27 myst afpd[10447]: uam: uams_gss.so loaded</p>
<p class="bodytext">May 26 21:50:27 myst afpd[10447]: uam: &quot;Client Krb v2&quot; available</p>
<p class="bodytext">May 26 21:50:27 myst afpd[10447]: Finished parsing Config File</p>
<p class="bodytext">----snip----</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">After checking /usr/lib/netatalk/ i can confirm that it doesn't exist.</p>
<p class="bodytext">Another search on the internet brings me to this page: https://bugs.launchpad.net/debian/+source/netatalk/+bug/26452</p>
<p class="bodytext">and this tells us exactly what we want to know, it seems that for some licensing issues, netatalk is built without SSL Support and thus uams_dhx.so is not available.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">So i decide to build the package myself, after creating a directory in /usr/src i fetch the source using &quot;apt-get source netatalk&quot;.</p>
<p class="bodytext">After checking out the debian/rules file i find that if you set some config option it should be built with SSL support. After reading debian/README.Debian i know i should set &quot;DEB_BUILD_OPTIONS=ssl&quot; so i put this in the debian/rules file beneath </p>
<p class="bodytext">&quot;DEB_UPDATE_RCD_PARAMS := defaults 50&quot;.</p>
<p class="bodytext">Time to build the package by issueing &quot;dpkg-buildpackage&quot; on my system it complained about some dependencies missing but i figure you know how to install some dependencies.</p>
<p class="bodytext">When dpkg-buildpackage goes on you see the ./configure line passing by if you edited debian/rules ok it should say --with-ssl-dir almost at the end of that line. </p>
<p class="bodytext">Get a cup of coffee and wait till your build completes. When it's done install your newly created deb package by issueing &quot;dpkg -i netatalk_&lt;version&gt;_&lt;arch&gt;.deb&quot;</p>
<p class="bodytext"> check /usr/lib/netatalk again there should be a uams_dhx.so now.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">Time to restart netatalk again and in /var/log/syslog you now should see something like:</p>
<p class="bodytext">----snip----</p>
<p class="bodytext">May 26 22:41:54 myst afpd[12962]: uam: loading (/usr/lib/netatalk/uams_dhx.so)</p>
<p class="bodytext">May 26 22:41:54 myst afpd[12962]: uam: uams_dhx.so loaded</p>
<p class="bodytext">May 26 22:41:54 myst afpd[12962]: uam: &quot;DHCAST128&quot; available</p>
<p class="bodytext">May 26 22:41:54 myst afpd[12962]: Finished parsing Config File</p>
<p class="bodytext">----snip----</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">Congratulations you've got it working, no more plaintext passwords over the network.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">I also noticed some extra services starting with netatalk which i do not use, if you like you could disable them. Edit your /etc/default/netatalk, somewhere in this file you should see something like &quot;# Set which daemons to run (papd is dependent upon atalkd):&quot; if you only need AFP over TCP like i do change it so that it matches the part below:</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">----snip----</p>
<p class="bodytext"># Set which daemons to run (papd is dependent upon atalkd):</p>
<p class="bodytext">ATALKD_RUN=no</p>
<p class="bodytext">PAPD_RUN=no</p>
<p class="bodytext">CNID_METAD_RUN=no</p>
<p class="bodytext">AFPD_RUN=yes</p>
<p class="bodytext">TIMELORD_RUN=no</p>
<p class="bodytext">A2BOOT_RUN=no</p>
<p class="bodytext">----snip----</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">This tells netatalk only to run afpd. At this point it is wise to also change /etc/netatalk/afpd.conf my config line looks like:</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">----snip----</p>
<p class="bodytext">- -tcp -uamlist uams_dhx.so -nosavepassword</p>
<p class="bodytext">----snip----</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">This tells afpd to only provide afpd over tcp, only load uams_dhx.so and don't offer to save passwords, you can change it to match your needs off course, see man afpd.conf for more options on this file.</p>
<p class="bodytext">&nbsp;</p>
<p class="bodytext">Restart netatalk again and you will notice it only runs afpd now. That's it you're finished now. Have fun with it.</p>]]></content:encoded>
			<category>SysAdmin</category>
			
			
			<pubDate>Sat, 26 May 2007 22:51:00 +0200</pubDate>
			
		</item>
		
	</channel>
</rss>