From: Colin Walters <walters@verbum.org>
To: SE Linux <selinux@tycho.nsa.gov>
Cc: Russell Coker <russell@coker.com.au>
Subject: rssh.{te,fc}
Date: 07 Jul 2003 00:22:20 -0400 [thread overview]
Message-ID: <1057551740.1241.10.camel@columbia> (raw)
[-- Attachment #1: Type: text/plain, Size: 426 bytes --]
I've written a quick rssh.te; this is for the rssh program:
http://pizzashack.org/rssh/
Basically rssh is a restricted shell that just allows people to execute
scp.
This is my first from-scratch .te file, so I'd appreciate if people
could give it a sanity check. To set this all up, I added another user
(in this case named haskelluser), then added:
user haskelluser roles { rssh_r };
to /etc/selinux/users. Make sense?
[-- Attachment #2: rssh.te --]
[-- Type: text/plain, Size: 909 bytes --]
#DESC Rssh - Restricted (scp/sftp) only shell
#
# Authors: Colin Walters <walters@verbum.org>
# X-Debian-Package: rssh
#
type rssh_t, domain, privlog, privfd;
role rssh_r types rssh_t;
allow system_r rssh_r;
type rssh_exec_t, file_type, sysadmfile, exec_type;
type rssh_archive_t, file_type, sysadmfile;
type rssh_home_t, file_type, sysadmfile;
general_domain_access(rssh_t);
uses_shlib(rssh_t);
base_file_read_access(rssh_t);
r_dir_file(rssh_t, etc_t);
r_dir_file(rssh_t, etc_runtime_t);
r_dir_file(rssh_t, locale_t);
can_exec(rssh_t, bin_t);
r_dir_file(rssh_t, rssh_home_t);
rw_dir_create_file(rssh_t, rssh_archive_t);
ifdef(`ssh.te',`
allow rssh_t sshd_t:fd use;
allow rssh_t sshd_t:tcp_socket rw_stream_socket_perms;
allow rssh_t sshd_t:unix_stream_socket rw_stream_socket_perms;
domain_auto_trans(sshd_t, rssh_exec_t, rssh_t);
r_dir_file(sshd_t, rssh_home_t);
')
[-- Attachment #3: rssh.fc --]
[-- Type: text/plain, Size: 55 bytes --]
# rssh
/usr/bin/rssh system_u:object_r:rssh_exec_t
next reply other threads:[~2003-07-07 4:25 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-07-07 4:22 Colin Walters [this message]
2003-07-07 10:14 ` rssh.{te,fc} Russell Coker
2003-07-07 12:39 ` rssh.{te,fc} Tom
2003-07-07 17:39 ` rssh.{te,fc} Colin Walters
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1057551740.1241.10.camel@columbia \
--to=walters@verbum.org \
--cc=russell@coker.com.au \
--cc=selinux@tycho.nsa.gov \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.