Stephen, thanks for your help.  <br><br>Why I thought the restricted application was running with all the power
of an unconfined_t process is that the bentest script was:<br>
#!/bin/sh<br>
ps -Z<br>
touch /usr/bentest/touched<br>
touch /usr/touched<br>
<br>
All the commands in this file succeeded.  I expected them all to fail
(including the shell invocation itself), as I hadn't explicitly given
any "allow"s to  bentest_t.  The file contexts were:<br>/usr/bentest                    gen_context(system_u:object_r:bentest_t,s0)<br>/usr/bentest/bentest    --      gen_context(system_u:object_r:bentest_exec_t,s0)
<br><br>The system is running in enforcing mode according to "getenforce".  The files were correctly labeled.  I was running as root, but I expected that wouldn't matter.<br><br>I must be misunderstanding the fundamentals here.   Any help you can give would be greatly appreciated.
<br><br>Ben<br><br><div><span class="gmail_quote">On 12/20/05, <b class="gmail_sendername">Stephen Smalley</b> <<a href="mailto:sds@tycho.nsa.gov">sds@tycho.nsa.gov</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
On Mon, 2005-12-19 at 23:16 -0600, Benjamin Youngdahl wrote:<br>> I have a question on locking down an application under the targeted<br>> policy.<br>><br>> The policy module I've tried is below.  I can see that the process has
<br>> the appropriate type in "ps -Z".:<br>><br>> root:system_r:bentest_t:SystemLow-SystemHigh 13127 pts/1 00:00:00<br>> bentest<br>><br>> But it still appears to have all the power of "unconfined_t".  I did
<br>> to a "restorecon -RF", and the files are appropriately labeled.<br><br>What makes you say it has all the power of unconfined_t?<br><br>> Is it possible for an app to confine "unconfined_t", or should I be
<br>> switching over to the replacement for the strict policy?  (I think it<br>> is just called "mls" at this point, which is a confusing name<br>> considering that targeted itself is an "mls" it seems.)
<br><br>You should be able to confine a particular application under targeted<br>policy, just by putting it into its own domain, as you seem to be doing.<br>No need to switch to strict policy for that.  MLS has a specific
<br>meaning, not relevant here.<br><br>--<br>Stephen Smalley<br>National Security Agency<br><br></blockquote></div><br>