<?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>Tommi&#039;s stuff &#187; selinux</title>
	<atom:link href="http://tommi.org/tag/selinux/feed/" rel="self" type="application/rss+xml" />
	<link>http://tommi.org</link>
	<description>joogoogilizer!</description>
	<lastBuildDate>Mon, 04 Jan 2010 20:48:11 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>SElinux and Proliant Support Pack (PSP) on RHEL or Centos 5</title>
		<link>http://tommi.org/2010/01/04/selinux-and-proliant-support-pack-psp-on-rhel-or-centos-5/</link>
		<comments>http://tommi.org/2010/01/04/selinux-and-proliant-support-pack-psp-on-rhel-or-centos-5/#comments</comments>
		<pubDate>Mon, 04 Jan 2010 20:01:51 +0000</pubDate>
		<dc:creator>tommi</dc:creator>
				<category><![CDATA[Open Source]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[proliant support pack]]></category>
		<category><![CDATA[psp]]></category>
		<category><![CDATA[red hat]]></category>
		<category><![CDATA[redhat]]></category>
		<category><![CDATA[rhel]]></category>
		<category><![CDATA[rhel5]]></category>
		<category><![CDATA[rhel54]]></category>
		<category><![CDATA[selinux]]></category>

		<guid isPermaLink="false">http://tommi.org/?p=55</guid>
		<description><![CDATA[I&#8217;ve been getting these annoying messages in the audit log, /var/log/audit/audit.log after installing the Proliant Support Pack on RHEL5.
type=AVC msg=audit(1262639482.789:2027381): avc:  denied  { read write } for  pid=18916 comm=&#8221;ethtool&#8221; path=&#8221;/dev/hpilo/d0ccb5&#8243; dev=tmpfs ino=6784 scontext=system_u:system_r:ifconfig_t:s0 tcontext=system_u:object_r:device_t:s0 tclass=chr_file
type=AVC msg=audit(1262639482.789:2027381): avc:  denied  { read write } for  pid=18916 comm=&#8221;ethtool&#8221; path=&#8221;socket:[22602]&#8221; dev=sockfs ino=22602 scontext=system_u:system_r:ifconfig_t:s0 tcontext=system_u:system_r:initrc_t:s0 tclass=netlink_route_socket
I don&#8217;t know what this [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been getting these annoying messages in the audit log, /var/log/audit/audit.log after installing the Proliant Support Pack on RHEL5.</p>
<blockquote><p>type=AVC msg=audit(1262639482.789:2027381): avc:  denied  { read write } for  pid=18916 comm=&#8221;ethtool&#8221; path=&#8221;/dev/hpilo/d0ccb5&#8243; dev=tmpfs ino=6784 scontext=system_u:system_r:ifconfig_t:s0 tcontext=system_u:object_r:device_t:s0 tclass=chr_file<br />
type=AVC msg=audit(1262639482.789:2027381): avc:  denied  { read write } for  pid=18916 comm=&#8221;ethtool&#8221; path=&#8221;socket:[22602]&#8221; dev=sockfs ino=22602 scontext=system_u:system_r:ifconfig_t:s0 tcontext=system_u:system_r:initrc_t:s0 tclass=netlink_route_socket</p></blockquote>
<p>I don&#8217;t know what this is but <strong>I DON&#8217;T</strong> want to allow it and I don&#8217;t want to see this in the audit log anymore</p>
<p>First off 3 terms:</p>
<ul>
<li>SElinux &#8211; <strong>Security-Enhanced Linux</strong> (<strong>SELinux</strong>) is a Linux feature that provides a mechanism for supporting access control security policies, including <a title="U.S. Department of Defense" href="http://en.wikipedia.org/wiki/U.S._Department_of_Defense">U.S. Department of Defense</a> style <a title="Mandatory access control" href="http://en.wikipedia.org/wiki/Mandatory_access_control">mandatory access controls</a>, through the use of <a title="Linux Security Modules" href="http://en.wikipedia.org/wiki/Linux_Security_Modules">Linux Security Modules</a> (LSM) in the <a title="Linux kernel" href="http://en.wikipedia.org/wiki/Linux_kernel">Linux kernel</a>. (wikipedia)</li>
<li><a href="http://h18000.www1.hp.com/products/servers/management/psp/">ProLiant Support Packs</a> (PSP) represent operating system (OS) specific bundles of ProLiant optimized drivers, utilities, and management agents.</li>
<li>RHEL (Red Hat Enterprise Linux) &#8211; CentOS (Community ENTerprise Operating System, RHEL Clone)</li>
</ul>
<p>So basicly what I did to get rid of these messages is that I wrote a new module called pspignore to ignore, without allowing them. Here&#8217;s what I did:</p>
<p><strong>Make a local directory for my modules</strong></p>
<blockquote><p>mkdir -p /etc/selinux/local</p></blockquote>
<blockquote><p>cd /etc/selinux/local</p></blockquote>
<p><strong>Download my custom module which include &#8220;dontaudit&#8221; for these conditions.</strong></p>
<blockquote><p>wget http://tommi.org/static/ignorepsp.te</p></blockquote>
<p><strong>Build the module and install it</strong></p>
<blockquote><p>checkmodule -M -m -o ignorepsp.mod ignorepsp.te</p>
<p>semodule_package -o ignorepsp.pp -m ignorepsp.mod</p>
<p>semodule -i ignorepsp.pp</p></blockquote>
<p>That should be it. The main thing can be found at the bottom of ignorepsp.te:</p>
<blockquote><p>dontaudit ifconfig_t device_t:chr_file { read write };<br />
dontaudit ifconfig_t initrc_t:netlink_route_socket { read write };</p></blockquote>
<p>Hope this is helpfull.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Ftommi.org%2F2010%2F01%2F04%2Fselinux-and-proliant-support-pack-psp-on-rhel-or-centos-5%2F&amp;linkname=SElinux%20and%20Proliant%20Support%20Pack%20%28PSP%29%20on%20RHEL%20or%20Centos%205"><img src="http://tommi.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://tommi.org/2010/01/04/selinux-and-proliant-support-pack-psp-on-rhel-or-centos-5/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Making Oracle work with SELinux on Red Hat Enterprise Linux 5</title>
		<link>http://tommi.org/2008/12/23/making-oracle-work-with-selinux-on-red-hat-enterprise-linux-5/</link>
		<comments>http://tommi.org/2008/12/23/making-oracle-work-with-selinux-on-red-hat-enterprise-linux-5/#comments</comments>
		<pubDate>Tue, 23 Dec 2008 23:15:28 +0000</pubDate>
		<dc:creator>tommi</dc:creator>
				<category><![CDATA[open source]]></category>
		<category><![CDATA[instant client]]></category>
		<category><![CDATA[instantclient]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[rhel]]></category>
		<category><![CDATA[rhel5]]></category>
		<category><![CDATA[selinux]]></category>

		<guid isPermaLink="false">http://tommi.org/?p=34</guid>
		<description><![CDATA[I wanted to put up for easy reference, how to setup the Oracle Instant Client packages on a SELinux enabled Red Hat Enterprise Linux 5 machine, the documentation was created on a x86_64 machine but should work on the 32 bit version as well.
Install packages:
oracle-instantclient11.1-basic-11.1.0.7.0-1.x86_64.rpm
oracle-instantclient11.1-devel-11.1.0.7.0-1.x86_64.rpm
oracle-instantclient11.1-sqlplus-11.1.0.7.0-1.x86_64.rpm
Put the relevant libraries into the textrel_shlib_t context:
semanage fcontext -a -t [...]]]></description>
			<content:encoded><![CDATA[<p>I wanted to put up for easy reference, how to setup the Oracle Instant Client packages on a SELinux enabled Red Hat Enterprise Linux 5 machine, the documentation was created on a x86_64 machine but should work on the 32 bit version as well.</p>
<p><strong>Install packages:</strong></p>
<pre>oracle-instantclient11.1-basic-11.1.0.7.0-1.x86_64.rpm
oracle-instantclient11.1-devel-11.1.0.7.0-1.x86_64.rpm
oracle-instantclient11.1-sqlplus-11.1.0.7.0-1.x86_64.rpm</pre>
<p><strong>Put the relevant libraries into the textrel_shlib_t context:</strong></p>
<pre><span style="font-family: Courier New,courier,monaco,monospace,sans-serif">semanage fcontext -a -t textrel_shlib_t /usr/lib/oracle/11.1/client64 /lib/libnnz11.so
</span><span style="font-family: Courier New,courier,monaco,monospace,sans-serif">semanage fcontext -a -t textrel_shlib_t /usr/lib/oracle/11.1/client64/lib/libclntsh.so.11.1
</span><span style="font-family: Courier New,courier,monaco,monospace,sans-serif">semanage fcontext -a -t textrel_shlib_t /usr/lib/oracle/11.1/client64/lib/libsqlplus.so
</span><span style="font-family: Courier New,courier,monaco,monospace,sans-serif">semanage fcontext -a -t textrel_shlib_t /usr/lib/oracle/11.1/client64/lib/libociei.so
</span><span style="font-family: Courier New,courier,monaco,monospace,sans-serif">semanage fcontext -a -t textrel_shlib_t /usr/lib/oracle/11.1/client64/lib/libsqlplusic.so
</span><span style="font-family: Courier New,courier,monaco,monospace,sans-serif">restorecon -R -v /usr/lib/oracle/11.1/client64/lib/</span></pre>
<p><strong>Put the libraries into the path of the dynamic library loader</strong></p>
<pre><span style="font-family: Courier New,courier,monaco,monospace,sans-serif">echo "export ORACLE_HOME=/usr/lib/oracle/11.1/client64" &gt; /etc/profile.d/oracle.sh

</span></pre>
<p><strong><span style="font-family: Courier New,courier,monaco,monospace,sans-serif">Set the path to the tnsnames.ora, I like /etc/tnsnames.ora</span></strong></p>
<p><span style="font-family: Courier New,courier,monaco,monospace,sans-serif">echo &#8220;export TNS_ADMIN=/etc/tnsnames.ora&#8221; &gt;&gt; /etc/profile.d/oracle.sh</span></p>
<p>Of course you have to have a valid tnsnames.ora file available.</p>
<p>Logout and login to update your environment and voila, you should be able to run sqlplus, install perl-DBD-Oracle or php-oci8, python, whatever your flavor is..</p>
<p>Ohh, and merry christmas! <img src='http://tommi.org/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Ftommi.org%2F2008%2F12%2F23%2Fmaking-oracle-work-with-selinux-on-red-hat-enterprise-linux-5%2F&amp;linkname=Making%20Oracle%20work%20with%20SELinux%20on%20Red%20Hat%20Enterprise%20Linux%205"><img src="http://tommi.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://tommi.org/2008/12/23/making-oracle-work-with-selinux-on-red-hat-enterprise-linux-5/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
