selinux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Creating a new port type
@ 2016-08-30 21:46 Ian Pilcher
  2016-08-31 10:51 ` Lukas Vrabec
  0 siblings, 1 reply; 3+ messages in thread
From: Ian Pilcher @ 2016-08-30 21:46 UTC (permalink / raw)
  To: selinux

I am attempting to write my first SELinux policy module (for the
Logitech Media Server/squeezeboxserver).  I would like to add a new
port type (slim_devices_port_t) for TCP and UDP 3483.

I haven't been able to find an example of how to do this, except for
stunnel.te, and the comments in that file don't lead me to believe that
it is the right way to do things.

Any pointers to examples or documentation would be appreciated.

Thanks!

-- 
========================================================================
Ian Pilcher                                         arequipeno@gmail.com
-------- "I grew up before Mark Zuckerberg invented friendship" --------
========================================================================

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Creating a new port type
  2016-08-30 21:46 Creating a new port type Ian Pilcher
@ 2016-08-31 10:51 ` Lukas Vrabec
  2016-08-31 11:50   ` Jason Zaman
  0 siblings, 1 reply; 3+ messages in thread
From: Lukas Vrabec @ 2016-08-31 10:51 UTC (permalink / raw)
  To: selinux

Hi Ian,

Blog by Dan Walsh will helps you.

http://danwalsh.livejournal.com/10607.html

Lukas.


On 08/30/2016 11:46 PM, Ian Pilcher wrote:
> I am attempting to write my first SELinux policy module (for the
> Logitech Media Server/squeezeboxserver).  I would like to add a new
> port type (slim_devices_port_t) for TCP and UDP 3483.
>
> I haven't been able to find an example of how to do this, except for
> stunnel.te, and the comments in that file don't lead me to believe that
> it is the right way to do things.
>
> Any pointers to examples or documentation would be appreciated.
>
> Thanks!
>


-- 
Lukas Vrabec
SELinux Solutions
Red Hat, Inc.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Creating a new port type
  2016-08-31 10:51 ` Lukas Vrabec
@ 2016-08-31 11:50   ` Jason Zaman
  0 siblings, 0 replies; 3+ messages in thread
From: Jason Zaman @ 2016-08-31 11:50 UTC (permalink / raw)
  To: selinux, refpolicy

On Wed, Aug 31, 2016 at 12:51:27PM +0200, Lukas Vrabec wrote:
> 
> 
> Blog by Dan Walsh will helps you.
> 
> http://danwalsh.livejournal.com/10607.html
> 
> Lukas.

Im sending this to the reference policy ML since thats a better place
for it.

The way in the blog post is if you have your own policy that is not part
of upstream. If you want the port to work properly by default it needs
to be in base.pp.
Look in policy/modules/kernel/corenetwork.te.in. You just need to
add one more line and it creates all the interfaces and types for you.

-- Jason

> 
> 
> On 08/30/2016 11:46 PM, Ian Pilcher wrote:
> > I am attempting to write my first SELinux policy module (for the
> > Logitech Media Server/squeezeboxserver).  I would like to add a new
> > port type (slim_devices_port_t) for TCP and UDP 3483.
> >
> > I haven't been able to find an example of how to do this, except for
> > stunnel.te, and the comments in that file don't lead me to believe that
> > it is the right way to do things.
> >
> > Any pointers to examples or documentation would be appreciated.
> >
> > Thanks!
> >
> 
> 
> -- 
> Lukas Vrabec
> SELinux Solutions
> Red Hat, Inc.
> _______________________________________________
> Selinux mailing list
> Selinux@tycho.nsa.gov
> To unsubscribe, send email to Selinux-leave@tycho.nsa.gov.
> To get help, send an email containing "help" to Selinux-request@tycho.nsa.gov.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-08-31 11:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-30 21:46 Creating a new port type Ian Pilcher
2016-08-31 10:51 ` Lukas Vrabec
2016-08-31 11:50   ` Jason Zaman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).