touch & how labels are created

Dominick Grift domg472 at gmail.com
Sun Dec 5 19:23:45 UTC 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 12/05/2010 08:17 PM, Jorge Fábregas wrote:
> On Sunday 05 December 2010 14:46:49 Dominick Grift wrote:
>> You should remove the ; on the filetrans line
>>
>> mkdir mytest; cd mytest;
> 
> Thanks Dominick.  I have this on myfile.te:
> 
> 
>  ----------------------------- cut here ----------------------------
> policy_module(mytest, 1.0.0)
> gen_require(` type unconfined_t, etc_t, net_conf_t; ')
> 
> manage_files_pattern(unconfined_t, etc_t, net_conf_t)
> filetrans_pattern(unconfined_t, etc_t, net_conf_t, file)
>  ----------------------------- cut here ----------------------------
> 
> ...but when I use make (as regular user):
> 
> make -f /usr/share/selinux/devel/Makefile mytest.pp
> 
> I get:
> 
> make: Nothing to be done for `/home/jorge/mytest/mytest.te'.

and there is no mytest.pp in ~/mytest/ ?

[dgrift at localhost Desktop]$  mkdir mytest; cd mytest;
[dgrift at localhost mytest]$ echo "policy_module(mytest,1.0.0)" > mytest.te;
[dgrift at localhost mytest]$ echo "gen_require(\` type unconfined_t,
etc_t, net_conf_t; ')" >> mytest.te;
[dgrift at localhost mytest]$ echo "manage_files_pattern(unconfined_t,
etc_t, net_conf_t)" >> mytest.te;
[dgrift at localhost mytest]$ echo "filetrans_pattern(unconfined_t, etc_t,
net_conf_t, file)" >> mytest.te;
[dgrift at localhost mytest]$ make -f /usr/share/selinux/devel/Makefile
mytest.pp
Compiling bare_gui mytest module
/usr/bin/checkmodule:  loading policy configuration from tmp/mytest.tmp
/usr/bin/checkmodule:  policy configuration loaded
/usr/bin/checkmodule:  writing binary representation (version 10) to
tmp/mytest.mod
Creating bare_gui mytest.pp policy package
rm tmp/mytest.mod.fc tmp/mytest.mod
[dgrift at localhost mytest]$

> BTW, thanks for adding the comments to the code. They're very helpful. I see 
> it's not that straight forward (there are many things to take care of 
> beforehand).
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.16 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/

iEYEARECAAYFAkz75sEACgkQMlxVo39jgT8A5wCgvSzj7hpXmUwzvH8im5zZdVpH
4moAn1tU/Jw0TGNuzbCQdu58xZ2xD3c2
=jUE6
-----END PGP SIGNATURE-----


More information about the selinux mailing list