<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>MinhTech.com &#187; Wordpress</title>
	<atom:link href="http://minhtech.com/category/wordpress/feed/" rel="self" type="application/rss+xml" />
	<link>http://minhtech.com</link>
	<description>Yet another technology tutorial blog.</description>
	<lastBuildDate>Sat, 04 Sep 2010 19:04:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Lockdown WordPress File Permissions</title>
		<link>http://minhtech.com/wordpress/lockdown-wordpress-file-permissions/</link>
		<comments>http://minhtech.com/wordpress/lockdown-wordpress-file-permissions/#comments</comments>
		<pubDate>Wed, 09 Sep 2009 20:49:10 +0000</pubDate>
		<dc:creator>Minh</dc:creator>
				<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://minhtech.com/?p=620</guid>
		<description><![CDATA[Here is how to lockdown WordPress file permissions on a Linux server.]]></description>
			<content:encoded><![CDATA[<p>Here is how to lockdown WordPress file permissions on a Linux server.</p>
<h3>First, Set Default File Permissions:</h3>
<p class="code">> <span class="input">cd <span class="codered">/var/www/html</span></span><br />
> <span class="input">find . -type d -exec chmod 755 {} \;</span><br />
> <span class="input">find . -type f -exec chmod 644 {} \;</span></p>
<p>Navigate to the WordPress root directory.  For all sub-directories, grant full privileges to the owner, and then only read and execute privileges to all others. For files, grant full privileges to the owner, and then only the read privilege to all others.</p>
<h3>Next, Set Permissions for the Uploads Directory:</h3>
<p class="code">> <span class="input">cd <span class="codered">/var/www/html</span>/wp-content</span><br />
> <span class="input">chmod 777 uploads</span><br />
> <span class="input">cd uploads</span><br />
> <span class="input">find . -type d -exec chmod 777 {} \;</span><br />
> <span class="input">find . -type f -exec chmod 666 {} \;</span></p>
<p>WordPress intended this folder to be writeable by all.  Note that we do not grant execute privileges to the files.</p>
<h3>Optionally Allow Write on Theme Files:</h3>
<p class="code">> <span class="input">cd <span class="codered">/var/www/html</span>/wp-content/themes/<span class="codered">themename</span></span><br />
> <span class="input">chmod 666 *.php</span><br />
> <span class="input">chmod 666 *.css</span></p>
<p>Grant read and write privileges to all for the PHP and Cascading Style Sheet (CSS) files if you wish to use the built-in theme editor in the WordPress administration console.</p>
<h3>Optionally Allow Write on .htaccess:</h3>
<p class="code">> <span class="input">cd <span class="codered">/var/www/html</span></span><br />
> <span class="input">chmod 666 *.htaccess</span></p>
<p>Grant read and write privileges to all for the .htaccess file in the WordPress root directory if you wish to allow WordPress to automatically generate rewrite rules for you.  It is good practice to remove the write privilege from all others (<span class="command">chmod 644 .htaccess</span>) after you are done configuring WordPress in the administration console. Unless you are making changes to settings, WordPress does not normally need write access to this file.</p>
<h3>Optionally Allow Additional Permissions:</h3>
<p class="code">> <span class="input">cd <span class="codered">/var/www/html</span></span><br />
> <span class="input">chmod 666 sitemap.xml</span><br />
> <span class="input">chmod 666 sitemap.xml.gz</span></p>
<p>Third party themes and plugins may require additional permissions.  Please refer to their documentation for instructions.  In this example, read and write privileges are granted to all for files manipulated by the popular Google (XML) Sitemaps Generator plugin.</p>
]]></content:encoded>
			<wfw:commentRss>http://minhtech.com/wordpress/lockdown-wordpress-file-permissions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
