NAME

ccs-savepolicy - save TOMOYO Linux policy


SYNOPSIS

ccs-savepolicy [directory]

ccs-savepolicy [directory] [remote_ip:remote:port]


DESCRIPTION

This program saves TOMOYO Linux policy onto disk from kernel memory.

The directory /etc/ccs/policy/YY-MM-DD.hh:mm:ss is created with four files inside: domain_policy.conf, exception_policy.conf, profile.conf, and manager.conf. The symbolic links /etc/ccs/policy/previous and /etc/ccs/policy/current are updated to point to the previous and current YY-MM-DD.hh:mm:ss directories respectively.

The following symbolic links should exist within the /etc/ccs directory:

  domain_policy.conf -> policy/current/domain_policy.conf
  exception_policy.conf -> policy/current/exception_policy.conf
  profile.conf -> policy/current/profile.conf
  manager.conf -> policy/current/manager.conf
  policy/current -> policy/YY-MM-DD.hh:mm:ss
  policy/previous -> policy/YY-MM-DD.hh:mm:ss

You can therefore access the current policy files without having to descend into subdirectories, and without having to determine which YY-MM-DD.hh:mm:ss directory is the most recent.

If the policy type is specified, this program works similar to cat(1).


OPTIONS

-e

Print /proc/ccs/exception_policy to standard output.

-d

Print /proc/ccs/domain_policy to standard output.

-p

Print /proc/ccs/profile to standard output.

-m

Print /proc/ccs/manager to standard output.

-s

Print /proc/ccs/stat to standard output.

directory

Save policy to an alternative directory, rather than the default /etc/ccs directory.

remote_ip:remote_port

Save policy on a remote system via an agent waiting at port remote_port on IP address remote_ip.


EXAMPLES

Save policy to disk
  ccs-savepolicy
Print /proc/ccs/exception_policy to standard output
  ccs-savepolicy -e
Retrieve policy from a remote system and save in a local directory
  ccs-savepolicy /etc/ccs/192.168.1.1/ 192.168.1.1:10000


BUGS

If you find any bugs, send an email to <tomoyo-users-en@lists.osdn.me>.


AUTHORS

Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>

Main author.

Jamie Nguyen <jamie@tomoyolinux.co.uk>

Documentation and website.


SEE ALSO

ccs-editpolicy-agent(8), ccs-loadpolicy(8)

See <https://tomoyo.sourceforge.net> for more information.