DOKK / manpages / debian 10 / tomoyo-tools / tomoyo-patternize.8.en
TOMOYO-PATTERNIZE(8) System Administration Utilities TOMOYO-PATTERNIZE(8)

tomoyo-patternize - utility to convert pathnames in policy into patterns

tomoyo-patternize

tomoyo-patternize [configfile]

This program reads domain policy from standard input and replaces pathnames with patterns. Replacement rules are defined in /etc/tomoyo/tools/patternize.conf. The resulting policy is sent to standard output and is useful to shorten and simplify domain or exception policy.

Pathnames used for domain names themselves will not be replaced. Only the first matching rule is used for any particular pathname. If a pathname does not match any rules, it is left unchanged.

  rewrite path_pattern proc:/self/fd/\$
    
  rewrite head_pattern proc:/\$
    
  rewrite tail_pattern /etc/mtab~\$
    
  rewrite path_pattern /tmp/php\?\?\?\?\?\? @GROUP1
    
  rewrite number_pattern 0-100 @GROUP2
  rewrite number_pattern 100-200 @GROUP2
    
  rewrite address_pattern 127.0.0.1 @LOCALHOST
  rewrite address_pattern 0:0:0:0:0:0:0:1 @LOCALHOST
    

See the configuration file for more information on rule syntax.

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

Main author.
Documentation and website.

tomoyo-findtemp(8), tomoyo-diffpolicy(8)

See <http://tomoyo.sourceforge.jp> for more information.

2012-04-14 tomoyo-tools 2.5.0