cfengine  3.15.4
About: CFEngine is a configuration management system for configuring and maintaining Unix-like computers (using an own high level policy language). Community version.
  Fossies Dox: cfengine-3.15.4.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

mod_files.c File Reference
#include <mod_files.h>
#include <policy.h>
#include <syntax.h>
Include dependency graph for mod_files.c:

Go to the source code of this file.

Functions

static bool AclCheck (const Body *body, Seq *errors)
 

Variables

static const ConstraintSyntax location_constraints []
 
static const BodySyntax location_body = { "location" , location_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax edit_field_constraints []
 
static const BodySyntax edit_field_body = { "edit_field" , edit_field_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax replace_with_constraints []
 
static const BodySyntax replace_with_body = { "replace_with" , replace_with_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax select_region_constraints []
 
static const BodySyntax select_region_body = { "select_region" , select_region_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax delete_select_constraints []
 
static const BodySyntax delete_select_body = { "delete_select" , delete_select_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax insert_select_constraints []
 
static const BodySyntax insert_select_body = { "insert_select" , insert_select_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax CF_INSERTLINES_BODIES []
 
static const ConstraintSyntax CF_DELETELINES_BODIES []
 
static const ConstraintSyntax CF_COLUMN_BODIES []
 
static const ConstraintSyntax CF_REPLACE_BODIES []
 
const ConstraintSyntax CF_COMMON_EDITBODIES []
 
static const ConstraintSyntax acl_constraints []
 
static const BodySyntax acl_body = { "acl" , acl_constraints , &AclCheck , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax changes_constraints []
 
static const BodySyntax changes_body = { "changes" , changes_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax depth_search_constraints []
 
static const BodySyntax depth_search_body = { "depth_search" , depth_search_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax edit_defaults_constraints []
 
static const BodySyntax edit_defaults_body = { "edit_defaults" , edit_defaults_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax delete_constraints []
 
static const BodySyntax delete_body = { "delete" , delete_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax rename_constraints []
 
static const BodySyntax rename_body = { "rename" , rename_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax perms_constraints []
 
static const BodySyntax perms_body = { "perms" , perms_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax file_select_constraints []
 
static const BodySyntax file_select_body = { "file_select" , file_select_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax link_from_constraints []
 
static const BodySyntax link_from_body = { "link_from" , link_from_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax copy_from_constraints []
 
static const BodySyntax copy_from_body = { "copy_from" , copy_from_constraints , NULL , SYNTAX_STATUS_NORMAL }
 
static const ConstraintSyntax CF_FILES_BODIES []
 
const ConstraintSyntax CF_COMMON_XMLBODIES []
 
static const ConstraintSyntax CF_INSERTTAGS_BODIES []
 
static const ConstraintSyntax CF_DELETETAGS_BODIES []
 
static const ConstraintSyntax CF_INSERTATTRIBUTES_BODIES []
 
static const ConstraintSyntax CF_DELETEATTRIBUTES_BODIES []
 
const PromiseTypeSyntax CF_FILES_PROMISE_TYPES []
 

Function Documentation

◆ AclCheck()

static bool AclCheck ( const Body body,
Seq errors 
)
static

Variable Documentation

◆ acl_body

const BodySyntax acl_body = { "acl" , acl_constraints , &AclCheck , SYNTAX_STATUS_NORMAL }
static

Definition at line 177 of file mod_files.c.

◆ acl_constraints

const ConstraintSyntax acl_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "aces" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "((user|group):[^:]+:[-=+,rwx()dtTabBpcoD]*(:(allow|deny))?)|((all|mask):[-=+,rwx()]*(:(allow|deny))?)" , "Native settings for access control entry" , SYNTAX_STATUS_NORMAL },
{ "acl_directory_inherit" , CF_DATA_TYPE_OPTION, .range.validation_string = "nochange,parent,specify,clear" , "Access control list type for the affected file system" , SYNTAX_STATUS_DEPRECATED },
{ "acl_default" , CF_DATA_TYPE_OPTION, .range.validation_string = "nochange,access,specify,clear" , "How to apply default (inheritable) access control list" , SYNTAX_STATUS_NORMAL },
{ "acl_method" , CF_DATA_TYPE_OPTION, .range.validation_string = "append,overwrite" , "Editing method for access control list" , SYNTAX_STATUS_NORMAL },
{ "acl_type" , CF_DATA_TYPE_OPTION, .range.validation_string = "generic,posix,ntfs" , "Access control list type for the affected file system" , SYNTAX_STATUS_NORMAL },
{ "specify_inherit_aces" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "((user|group):[^:]+:[-=+,rwx()dtTabBpcoD]*(:(allow|deny))?)|((all|mask):[-=+,rwx()]*(:(allow|deny))?)" , "Native settings for access control entry" , SYNTAX_STATUS_DEPRECATED },
{ "specify_default_aces" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "((user|group):[^:]+:[-=+,rwx()dtTabBpcoD]*(:(allow|deny))?)|((all|mask):[-=+,rwx()]*(:(allow|deny))?)" , "Native settings for access control entry" , SYNTAX_STATUS_NORMAL },
{ "acl_inherit" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" ",nochange" , "Whether the object inherits its ACL from the parent (Windows only)" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}
@ SYNTAX_STATUS_NORMAL
Definition: cf3.defs.h:638
@ SYNTAX_STATUS_DEPRECATED
Definition: cf3.defs.h:639
@ CF_DATA_TYPE_NONE
Definition: cf3.defs.h:385
@ CF_DATA_TYPE_STRING_LIST
Definition: cf3.defs.h:372
@ CF_DATA_TYPE_BODY
Definition: cf3.defs.h:377
@ CF_DATA_TYPE_OPTION
Definition: cf3.defs.h:375
#define NULL
Definition: getopt1.c:56

Definition at line 163 of file mod_files.c.

◆ CF_COLUMN_BODIES

const ConstraintSyntax CF_COLUMN_BODIES[]
static
Initial value:
=
{
{ "edit_field" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &edit_field_body , "Edit line-based file as matrix of fields" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}
static const BodySyntax edit_field_body
Definition: mod_files.c:55

Definition at line 125 of file mod_files.c.

◆ CF_COMMON_EDITBODIES

const ConstraintSyntax CF_COMMON_EDITBODIES[]
Initial value:
=
{
{ "select_region" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &select_region_body , "Limit edits to a demarked region of the file" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}
static const BodySyntax select_region_body
Definition: mod_files.c:78

Definition at line 137 of file mod_files.c.

Referenced by ConstraintCheckSyntax(), ConstraintGetSyntax(), and PromiseTypeSyntaxGetConstraintSyntax().

◆ CF_COMMON_XMLBODIES

const ConstraintSyntax CF_COMMON_XMLBODIES[]
Initial value:
=
{
{ "build_xpath" , CF_DATA_TYPE_STRING, .range.validation_string = "" , "Build an XPath within the XML file" , SYNTAX_STATUS_NORMAL },
{ "select_xpath" , CF_DATA_TYPE_STRING, .range.validation_string = "" , "Select the XPath node in the XML file to edit" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}
@ CF_DATA_TYPE_STRING
Definition: cf3.defs.h:369

Definition at line 365 of file mod_files.c.

Referenced by ConstraintCheckSyntax(), ConstraintGetSyntax(), and PromiseTypeSyntaxGetConstraintSyntax().

◆ CF_DELETEATTRIBUTES_BODIES

const ConstraintSyntax CF_DELETEATTRIBUTES_BODIES[]
static
Initial value:
=
{
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 388 of file mod_files.c.

◆ CF_DELETELINES_BODIES

const ConstraintSyntax CF_DELETELINES_BODIES[]
static
Initial value:
=
{
{ "delete_select" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &delete_select_body , "Delete only if lines pass filter criteria" , SYNTAX_STATUS_NORMAL },
{ "not_matching" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false negate match criterion. Default value: false" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}
static const BodySyntax delete_select_body
Definition: mod_files.c:92

Definition at line 118 of file mod_files.c.

◆ CF_DELETETAGS_BODIES

const ConstraintSyntax CF_DELETETAGS_BODIES[]
static
Initial value:
=
{
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 377 of file mod_files.c.

◆ CF_FILES_BODIES

const ConstraintSyntax CF_FILES_BODIES[]
static
Initial value:
=
{
{ "acl" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &acl_body , "Criteria for access control lists on file" , SYNTAX_STATUS_NORMAL },
{ "changes" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &changes_body , "Criteria for change management" , SYNTAX_STATUS_NORMAL },
{ "copy_from" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &copy_from_body , "Criteria for copying file from a source" , SYNTAX_STATUS_NORMAL },
{ "create" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false whether to create non-existing file. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "delete" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &delete_body , "Criteria for deleting files" , SYNTAX_STATUS_NORMAL },
{ "depth_search" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &depth_search_body , "Criteria for file depth searches" , SYNTAX_STATUS_NORMAL },
{ "edit_defaults" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &edit_defaults_body , "Default promise details for file edits" , SYNTAX_STATUS_NORMAL },
{ "edit_line" , CF_DATA_TYPE_BUNDLE, .range.validation_string = (void*)1234 , "Line editing model for file" , SYNTAX_STATUS_NORMAL },
{ "edit_template" , CF_DATA_TYPE_STRING, .range.validation_string = "\"?(/.*)" , "The name of a special CFEngine template file to expand" , SYNTAX_STATUS_NORMAL },
{ "edit_template_string" , CF_DATA_TYPE_STRING, .range.validation_string = ".*" , "Template string to expand" , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , CF_DATA_TYPE_BUNDLE, .range.validation_string = (void*)1234 , "XML editing model for file" , SYNTAX_STATUS_NORMAL },
{ "file_select" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &file_select_body , "Choose which files select in a search" , SYNTAX_STATUS_NORMAL },
{ "file_type" , CF_DATA_TYPE_OPTION, .range.validation_string = "regular,fifo" , "Type of file to create. Default value: regular" , SYNTAX_STATUS_NORMAL },
{ "link_from" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &link_from_body , "Criteria for linking file from a source" , SYNTAX_STATUS_NORMAL },
{ "move_obstructions" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false whether to move obstructions to file-object creation. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "pathtype" , CF_DATA_TYPE_OPTION, .range.validation_string = "literal,regex,guess" , "Menu option for interpreting promiser file object" , SYNTAX_STATUS_NORMAL },
{ "perms" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &perms_body , "Criteria for setting permissions on a file" , SYNTAX_STATUS_NORMAL },
{ "rename" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &rename_body , "Criteria for renaming files" , SYNTAX_STATUS_NORMAL },
{ "repository" , CF_DATA_TYPE_STRING, .range.validation_string = "\"?(/.*)" , "Name of a repository for versioning" , SYNTAX_STATUS_NORMAL },
{ "touch" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false whether to touch time stamps on file" , SYNTAX_STATUS_NORMAL },
{ "transformer" , CF_DATA_TYPE_STRING, .range.validation_string = "\"?(/.*)" , "Command (with full path) used to transform current file (no shell wrapper used)" , SYNTAX_STATUS_NORMAL },
{ "template_method" , CF_DATA_TYPE_OPTION, .range.validation_string = "cfengine,inline_mustache,mustache" , "" , SYNTAX_STATUS_NORMAL },
{ "template_data" , CF_DATA_TYPE_CONTAINER, .range.validation_string = "", "" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}
@ CF_DATA_TYPE_BUNDLE
Definition: cf3.defs.h:378
@ CF_DATA_TYPE_CONTAINER
Definition: cf3.defs.h:384
static const BodySyntax depth_search_body
Definition: mod_files.c:204
static const BodySyntax acl_body
Definition: mod_files.c:177
static const BodySyntax file_select_body
Definition: mod_files.c:278
static const BodySyntax edit_defaults_body
Definition: mod_files.c:218
static const BodySyntax changes_body
Definition: mod_files.c:189
static const BodySyntax copy_from_body
Definition: mod_files.c:333
static const BodySyntax link_from_body
Definition: mod_files.c:297
static const BodySyntax perms_body
Definition: mod_files.c:254
static const BodySyntax delete_body
Definition: mod_files.c:228
static const BodySyntax rename_body
Definition: mod_files.c:241

Definition at line 335 of file mod_files.c.

◆ CF_FILES_PROMISE_TYPES

const PromiseTypeSyntax CF_FILES_PROMISE_TYPES[]
Initial value:
=
{
{ "agent" , "files" , CF_FILES_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_line" , "*" , CF_COMMON_EDITBODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_line" , "delete_lines" , CF_DELETELINES_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_line" , "insert_lines" , CF_INSERTLINES_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_line" , "field_edits" , CF_COLUMN_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_line" , "replace_patterns" , CF_REPLACE_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , "*" , CF_COMMON_XMLBODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , "build_xpath" , CF_INSERTTAGS_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , "delete_tree" , CF_DELETETAGS_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , "insert_tree" , CF_INSERTTAGS_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , "delete_attribute" , CF_DELETEATTRIBUTES_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , "set_attribute" , CF_INSERTATTRIBUTES_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , "delete_text" , CF_DELETETAGS_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , "set_text" , CF_INSERTTAGS_BODIES , NULL , SYNTAX_STATUS_NORMAL },
{ "edit_xml" , "insert_text" , CF_INSERTTAGS_BODIES , NULL , SYNTAX_STATUS_NORMAL },
}
const ConstraintSyntax CF_COMMON_XMLBODIES[]
Definition: mod_files.c:365
static const ConstraintSyntax CF_REPLACE_BODIES[]
Definition: mod_files.c:131
static const ConstraintSyntax CF_DELETEATTRIBUTES_BODIES[]
Definition: mod_files.c:388
static const ConstraintSyntax CF_INSERTTAGS_BODIES[]
Definition: mod_files.c:372
static const ConstraintSyntax CF_DELETETAGS_BODIES[]
Definition: mod_files.c:377
static const ConstraintSyntax CF_COLUMN_BODIES[]
Definition: mod_files.c:125
static const ConstraintSyntax CF_FILES_BODIES[]
Definition: mod_files.c:335
static const ConstraintSyntax CF_INSERTATTRIBUTES_BODIES[]
Definition: mod_files.c:382
const ConstraintSyntax CF_COMMON_EDITBODIES[]
Definition: mod_files.c:137
static const ConstraintSyntax CF_DELETELINES_BODIES[]
Definition: mod_files.c:118
static const ConstraintSyntax CF_INSERTLINES_BODIES[]
Definition: mod_files.c:108

Definition at line 396 of file mod_files.c.

◆ CF_INSERTATTRIBUTES_BODIES

const ConstraintSyntax CF_INSERTATTRIBUTES_BODIES[]
static
Initial value:
=
{
{ "attribute_value" , CF_DATA_TYPE_STRING, .range.validation_string = "" , "Value of the attribute to be inserted into the XPath node of the XML file" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 382 of file mod_files.c.

◆ CF_INSERTLINES_BODIES

const ConstraintSyntax CF_INSERTLINES_BODIES[]
static
Initial value:
=
{
{ "expand_scalars" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "Expand any unexpanded variables. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "insert_type" , CF_DATA_TYPE_OPTION, .range.validation_string = "literal,string,file,file_preserve_block,preserve_block,preserve_all_lines" , "Type of object the promiser string refers to. Default value: literal" , SYNTAX_STATUS_NORMAL },
{ "insert_select" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &insert_select_body , "Insert only if lines pass filter criteria" , SYNTAX_STATUS_NORMAL },
{ "location" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &location_body , "Specify where in a file an insertion will be made" , SYNTAX_STATUS_NORMAL },
{ "whitespace_policy" , CF_DATA_TYPE_OPTION_LIST, .range.validation_string = "ignore_leading,ignore_trailing,ignore_embedded,exact_match" , "Criteria for matching and recognizing existing lines" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}
@ CF_DATA_TYPE_OPTION_LIST
Definition: cf3.defs.h:376
static const BodySyntax insert_select_body
Definition: mod_files.c:106
static const BodySyntax location_body
Definition: mod_files.c:39

Definition at line 108 of file mod_files.c.

◆ CF_INSERTTAGS_BODIES

const ConstraintSyntax CF_INSERTTAGS_BODIES[]
static
Initial value:
=
{
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 372 of file mod_files.c.

◆ CF_REPLACE_BODIES

const ConstraintSyntax CF_REPLACE_BODIES[]
static
Initial value:
=
{
{ "replace_with" , CF_DATA_TYPE_BODY, .range.body_type_syntax = &replace_with_body , "Search-replace pattern" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}
static const BodySyntax replace_with_body
Definition: mod_files.c:65

Definition at line 131 of file mod_files.c.

◆ changes_body

const BodySyntax changes_body = { "changes" , changes_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 189 of file mod_files.c.

◆ changes_constraints

const ConstraintSyntax changes_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "hash" , CF_DATA_TYPE_OPTION, .range.validation_string = "md5,sha1,sha224,sha256,sha384,sha512,best" , "Hash files for change detection" , SYNTAX_STATUS_NORMAL },
{ "report_changes" , CF_DATA_TYPE_OPTION, .range.validation_string = "all,stats,content,none" , "Specify criteria for change warnings" , SYNTAX_STATUS_NORMAL },
{ "update_hashes" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "Update hash values immediately after change warning" , SYNTAX_STATUS_NORMAL },
{ "report_diffs" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "Generate reports summarizing the major differences between individual text files" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 179 of file mod_files.c.

◆ copy_from_body

const BodySyntax copy_from_body = { "copy_from" , copy_from_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 333 of file mod_files.c.

◆ copy_from_constraints

const ConstraintSyntax copy_from_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "source" , CF_DATA_TYPE_STRING, .range.validation_string = ".+" , "Reference source file from which to copy" , SYNTAX_STATUS_NORMAL },
{ "servers" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "[A-Za-z0-9_.:\\-\\[\\]]+" , "List of servers in order of preference from which to copy" , SYNTAX_STATUS_NORMAL },
{ "collapse_destination_dir" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "Copy files from subdirectories to the root destination directory. Default: false" , SYNTAX_STATUS_NORMAL },
{ "compare" , CF_DATA_TYPE_OPTION, .range.validation_string = "atime,mtime,ctime,digest,hash,exists,binary" , "Menu option policy for comparing source and image file attributes. Default: mtime or ctime differs" , SYNTAX_STATUS_NORMAL },
{ "copy_backup" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,timestamp" , "Menu option policy for file backup/version control. Default value: true" , SYNTAX_STATUS_NORMAL },
{ "encrypt" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false use encrypted data stream to connect to remote host. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "check_root" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false check permissions on the root directory when depth_search" , SYNTAX_STATUS_NORMAL },
{ "copylink_patterns" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "" , "List of patterns matching files that should be copied instead of linked" , SYNTAX_STATUS_NORMAL },
{ "copy_size" , CF_DATA_TYPE_INT_RANGE, .range.validation_string = "0,inf" , "Integer range of file sizes that may be copied" , SYNTAX_STATUS_NORMAL },
{ "findertype" , CF_DATA_TYPE_OPTION, .range.validation_string = "MacOSX" , "Menu option for default finder type on MacOSX" , SYNTAX_STATUS_NORMAL },
{ "linkcopy_patterns" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "" , "List of patterns matching files that should be replaced with symbolic links" , SYNTAX_STATUS_NORMAL },
{ "link_type" , CF_DATA_TYPE_OPTION, .range.validation_string = "symlink,hardlink,relative,absolute" , "Menu option for type of links to use when copying. Default value: symlink" , SYNTAX_STATUS_NORMAL },
{ "force_update" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false force copy update always. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "force_ipv4" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false force use of ipv4 on ipv6 enabled network. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "portnumber" , CF_DATA_TYPE_STRING, .range.validation_string = "" , "Port number or service name to connect to on server host" , SYNTAX_STATUS_NORMAL },
{ "preserve" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false whether to preserve file permissions on copied file. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "purge" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false purge files on client that do not match files on server when a depth_search is used. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "stealth" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false whether to preserve time stamps on copied file. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "timeout" , CF_DATA_TYPE_INT, .range.validation_string = "1,3600" , "Connection timeout, seconds" , SYNTAX_STATUS_NORMAL },
{ "trustkey" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false trust public keys from remote server if previously unknown. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "type_check" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false compare file types before copying and require match" , SYNTAX_STATUS_NORMAL },
{ "verify" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false verify transferred file by hashing after copy (resource penalty). Default value: false" , SYNTAX_STATUS_NORMAL },
{ "protocol_version" , CF_DATA_TYPE_OPTION, .range.validation_string = "0,undefined,1,classic,2,latest" , "CFEngine protocol version to use when connecting to the server. Default: undefined" , SYNTAX_STATUS_NORMAL },
{ "missing_ok" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false Do not treat missing file as an error. Default value: false" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}
@ CF_DATA_TYPE_INT
Definition: cf3.defs.h:370
@ CF_DATA_TYPE_INT_RANGE
Definition: cf3.defs.h:381

Definition at line 299 of file mod_files.c.

◆ delete_body

const BodySyntax delete_body = { "delete" , delete_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 228 of file mod_files.c.

◆ delete_constraints

const ConstraintSyntax delete_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "dirlinks" , CF_DATA_TYPE_OPTION, .range.validation_string = "delete,tidy,keep" , "Menu option policy for dealing with symbolic links to directories during deletion" , SYNTAX_STATUS_NORMAL },
{ "rmdirs" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false whether to delete empty directories during recursive deletion" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 220 of file mod_files.c.

◆ delete_select_body

const BodySyntax delete_select_body = { "delete_select" , delete_select_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 92 of file mod_files.c.

◆ delete_select_constraints

const ConstraintSyntax delete_select_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "delete_if_startwith_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Delete line if it starts with a string in the list" , SYNTAX_STATUS_NORMAL },
{ "delete_if_not_startwith_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Delete line if it DOES NOT start with a string in the list" , SYNTAX_STATUS_NORMAL },
{ "delete_if_match_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Delete line if it fully matches a regex in the list" , SYNTAX_STATUS_NORMAL },
{ "delete_if_not_match_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Delete line if it DOES NOT fully match a regex in the list" , SYNTAX_STATUS_NORMAL },
{ "delete_if_contains_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Delete line if a regex in the list match a line fragment" , SYNTAX_STATUS_NORMAL },
{ "delete_if_not_contains_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Delete line if a regex in the list DOES NOT match a line fragment" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 80 of file mod_files.c.

◆ depth_search_body

const BodySyntax depth_search_body = { "depth_search" , depth_search_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 204 of file mod_files.c.

◆ depth_search_constraints

const ConstraintSyntax depth_search_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "depth" , CF_DATA_TYPE_INT, .range.validation_string = "0,99999999999" , "Maximum depth level for search" , SYNTAX_STATUS_NORMAL },
{ "exclude_dirs" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "List of regexes of directory names NOT to include in depth search" , SYNTAX_STATUS_NORMAL },
{ "include_basedir" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false include the start/root dir of the search results" , SYNTAX_STATUS_NORMAL },
{ "include_dirs" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "List of regexes of directory names to include in depth search" , SYNTAX_STATUS_NORMAL },
{ "rmdeadlinks" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false remove links that point to nowhere. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "traverse_links" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false traverse symbolic links to directories. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "xdev" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "When true files and directories on different devices from the promiser will be excluded from depth_search results. Default value: false" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 191 of file mod_files.c.

◆ edit_defaults_body

const BodySyntax edit_defaults_body = { "edit_defaults" , edit_defaults_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 218 of file mod_files.c.

◆ edit_defaults_constraints

const ConstraintSyntax edit_defaults_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "edit_backup" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,timestamp,rotate" , "Menu option for backup policy on edit changes. Default value: true" , SYNTAX_STATUS_NORMAL },
{ "empty_file_before_editing" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "Baseline memory model of file to zero/empty before commencing promised edits. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "inherit" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "If true this causes the sub-bundle to inherit the private classes of its parent" , SYNTAX_STATUS_NORMAL },
{ "max_file_size" , CF_DATA_TYPE_INT, .range.validation_string = "0,99999999999" , "Do not edit files bigger than this number of bytes" , SYNTAX_STATUS_NORMAL },
{ "recognize_join" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "Join together lines that end with a backslash, up to 4kB limit. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "rotate" , CF_DATA_TYPE_INT, .range.validation_string = "0,99" , "How many backups to store if 'rotate' edit_backup strategy is selected. Default value: 1" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 206 of file mod_files.c.

◆ edit_field_body

const BodySyntax edit_field_body = { "edit_field" , edit_field_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 55 of file mod_files.c.

◆ edit_field_constraints

const ConstraintSyntax edit_field_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "allow_blank_fields" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false allow blank fields in a line (do not purge). Default value: false" , SYNTAX_STATUS_NORMAL },
{ "extend_fields" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false add new fields at end of line if necessary to complete edit. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "field_operation" , CF_DATA_TYPE_OPTION, .range.validation_string = "prepend,append,alphanum,delete,set" , "Menu option policy for editing subfields. Default value: none" , SYNTAX_STATUS_NORMAL },
{ "field_separator" , CF_DATA_TYPE_STRING, .range.validation_string = ".*" , "The regular expression used to separate fields in a line. Default value: none" , SYNTAX_STATUS_NORMAL },
{ "field_value" , CF_DATA_TYPE_STRING, .range.validation_string = ".*" , "Set field value to a fixed value" , SYNTAX_STATUS_NORMAL },
{ "select_field" , CF_DATA_TYPE_INT, .range.validation_string = "0,99999999" , "Integer index of the field required 0..n (default starts from 1)" , SYNTAX_STATUS_NORMAL },
{ "start_fields_from_zero" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "If set, the default field numbering starts from 0" , SYNTAX_STATUS_NORMAL },
{ "value_separator" , CF_DATA_TYPE_STRING, .range.validation_string = "^.$" , "Character separator for subfields inside the selected field. Default value: none" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 41 of file mod_files.c.

◆ file_select_body

const BodySyntax file_select_body = { "file_select" , file_select_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 278 of file mod_files.c.

◆ file_select_constraints

const ConstraintSyntax file_select_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "leaf_name" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "" , "List of regexes that match an acceptable name" , SYNTAX_STATUS_NORMAL },
{ "path_name" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "\"?(/.*)" , "List of pathnames to match acceptable target" , SYNTAX_STATUS_NORMAL },
{ "search_mode" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "[0-7augorwxst,+-=]+" , "A list of mode masks for acceptable file permissions" , SYNTAX_STATUS_NORMAL },
{ "search_size" , CF_DATA_TYPE_INT_RANGE, .range.validation_string = "0,inf" , "Integer range of file sizes" , SYNTAX_STATUS_NORMAL },
{ "search_owners" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "" , "List of acceptable user names or ids for the file, or regexes to match" , SYNTAX_STATUS_NORMAL },
{ "search_groups" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "" , "List of acceptable group names or ids for the file, or regexes to match" , SYNTAX_STATUS_NORMAL },
{ "search_bsdflags" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "[+-]*[(arch|archived|nodump|opaque|sappnd|sappend|schg|schange|simmutable|sunlnk|sunlink|uappnd|uappend|uchg|uchange|uimmutable|uunlnk|uunlink)]+" , "String of flags for bsd file system flags expected set" , SYNTAX_STATUS_NORMAL },
{ "ctime" , CF_DATA_TYPE_INT_RANGE, .range.validation_string = "0,2147483647" , "Range of change times (ctime) for acceptable files" , SYNTAX_STATUS_NORMAL },
{ "mtime" , CF_DATA_TYPE_INT_RANGE, .range.validation_string = "0,2147483647" , "Range of modification times (mtime) for acceptable files" , SYNTAX_STATUS_NORMAL },
{ "atime" , CF_DATA_TYPE_INT_RANGE, .range.validation_string = "0,2147483647" , "Range of access times (atime) for acceptable files" , SYNTAX_STATUS_NORMAL },
{ "exec_regex" , CF_DATA_TYPE_STRING, .range.validation_string = ".*" , "Matches file if this regular expression matches any full line returned by the command" , SYNTAX_STATUS_NORMAL },
{ "exec_program" , CF_DATA_TYPE_STRING, .range.validation_string = "\"?(/.*)" , "Execute this command on each file and match if the exit status is zero" , SYNTAX_STATUS_NORMAL },
{ "file_types" , CF_DATA_TYPE_OPTION_LIST, .range.validation_string = "plain,reg,symlink,dir,socket,fifo,door,char,block" , "List of acceptable file types from menu choices" , SYNTAX_STATUS_NORMAL },
{ "issymlinkto" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "" , "List of regular expressions to match file objects" , SYNTAX_STATUS_NORMAL },
{ "file_result" , CF_DATA_TYPE_STRING, .range.validation_string = "[!*(leaf_name|path_name|file_types|mode|size|owner|group|atime|ctime|mtime|issymlinkto|exec_regex|exec_program|bsdflags)[|&.]*]*" , "Logical expression combining classes defined by file search criteria" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 256 of file mod_files.c.

◆ insert_select_body

const BodySyntax insert_select_body = { "insert_select" , insert_select_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 106 of file mod_files.c.

◆ insert_select_constraints

const ConstraintSyntax insert_select_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "insert_if_startwith_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Insert line if it starts with a string in the list" , SYNTAX_STATUS_NORMAL },
{ "insert_if_not_startwith_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Insert line if it DOES NOT start with a string in the list" , SYNTAX_STATUS_NORMAL },
{ "insert_if_match_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Insert line if it fully matches a regex in the list" , SYNTAX_STATUS_NORMAL },
{ "insert_if_not_match_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Insert line if it DOES NOT fully match a regex in the list" , SYNTAX_STATUS_NORMAL },
{ "insert_if_contains_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Insert line if a regex in the list match a line fragment" , SYNTAX_STATUS_NORMAL },
{ "insert_if_not_contains_from_list" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = ".*" , "Insert line if a regex in the list DOES NOT match a line fragment" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 94 of file mod_files.c.

◆ link_from_body

const BodySyntax link_from_body = { "link_from" , link_from_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 297 of file mod_files.c.

◆ link_from_constraints

const ConstraintSyntax link_from_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "copy_patterns" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "" , "A set of patterns that should be copied and synchronized instead of linked" , SYNTAX_STATUS_NORMAL },
{ "link_children" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false whether to link all directory's children to source originals. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "link_type" , CF_DATA_TYPE_OPTION, .range.validation_string = "symlink,hardlink,relative,absolute" , "The type of link used to alias the file. Default value: symlink" , SYNTAX_STATUS_NORMAL },
{ "source" , CF_DATA_TYPE_STRING, .range.validation_string = ".+" , "The source file to which the link should point" , SYNTAX_STATUS_NORMAL },
{ "when_linking_children" , CF_DATA_TYPE_OPTION, .range.validation_string = "override_file,if_no_such_file" , "Policy for overriding existing files when linking directories of children" , SYNTAX_STATUS_NORMAL },
{ "when_no_source" , CF_DATA_TYPE_OPTION, .range.validation_string = "force,delete,nop" , "Behaviour when the source file to link to does not exist. Default value: nop" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 285 of file mod_files.c.

◆ location_body

const BodySyntax location_body = { "location" , location_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 39 of file mod_files.c.

◆ location_constraints

const ConstraintSyntax location_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "before_after" , CF_DATA_TYPE_OPTION, .range.validation_string = "before,after" , "Menu option, point cursor before of after matched line. Default value: after" , SYNTAX_STATUS_NORMAL },
{ "first_last" , CF_DATA_TYPE_OPTION, .range.validation_string = "first,last" , "Menu option, choose first or last occurrence of match in file. Default value: last" , SYNTAX_STATUS_NORMAL },
{ "select_line_matching" , CF_DATA_TYPE_STRING, .range.validation_string = ".*" , "Regular expression for matching file line location" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 30 of file mod_files.c.

◆ perms_body

const BodySyntax perms_body = { "perms" , perms_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 254 of file mod_files.c.

◆ perms_constraints

const ConstraintSyntax perms_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "bsdflags" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "[+-]*[(arch|archived|nodump|opaque|sappnd|sappend|schg|schange|simmutable|sunlnk|sunlink|uappnd|uappend|uchg|uchange|uimmutable|uunlnk|uunlink)]+" , "List of menu options for bsd file system flags to set" , SYNTAX_STATUS_NORMAL },
{ "groups" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "[a-zA-Z0-9_$.-]+" , "List of acceptable groups of group ids, first is change target" , SYNTAX_STATUS_NORMAL },
{ "mode" , CF_DATA_TYPE_STRING, .range.validation_string = "[0-7augorwxst,+-=]+" , "File permissions (like posix chmod)" , SYNTAX_STATUS_NORMAL },
{ "owners" , CF_DATA_TYPE_STRING_LIST, .range.validation_string = "[a-zA-Z0-9_$.-]+" , "List of acceptable owners or user ids, first is change target" , SYNTAX_STATUS_NORMAL },
{ "rxdirs" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false add execute flag for directories if read flag is set" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 243 of file mod_files.c.

◆ rename_body

const BodySyntax rename_body = { "rename" , rename_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 241 of file mod_files.c.

◆ rename_constraints

const ConstraintSyntax rename_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "disable" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "true/false automatically rename and remove permissions. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "disable_mode" , CF_DATA_TYPE_STRING, .range.validation_string = "[0-7augorwxst,+-=]+" , "The permissions to set when a file is disabled" , SYNTAX_STATUS_NORMAL },
{ "disable_suffix" , CF_DATA_TYPE_STRING, .range.validation_string = "" , "The suffix to add to files when disabling (.cfdisabled)" , SYNTAX_STATUS_NORMAL },
{ "newname" , CF_DATA_TYPE_STRING, .range.validation_string = "" , "The desired name for the current file" , SYNTAX_STATUS_NORMAL },
{ "rotate" , CF_DATA_TYPE_INT, .range.validation_string = "0,99" , "Maximum number of file rotations to keep" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 230 of file mod_files.c.

◆ replace_with_body

const BodySyntax replace_with_body = { "replace_with" , replace_with_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 65 of file mod_files.c.

◆ replace_with_constraints

const ConstraintSyntax replace_with_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "occurrences" , CF_DATA_TYPE_OPTION, .range.validation_string = "all,first" , "Menu option to replace all occurrences or just first (NB the latter is non-convergent). Default value: all" , SYNTAX_STATUS_NORMAL },
{ "replace_value" , CF_DATA_TYPE_STRING, .range.validation_string = ".*" , "Value used to replace regular expression matches in search" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 57 of file mod_files.c.

◆ select_region_body

const BodySyntax select_region_body = { "select_region" , select_region_constraints , NULL , SYNTAX_STATUS_NORMAL }
static

Definition at line 78 of file mod_files.c.

◆ select_region_constraints

const ConstraintSyntax select_region_constraints[]
static
Initial value:
=
{
{ "meta", CF_DATA_TYPE_STRING_LIST, .range.validation_string = "", "Tags describing the body", SYNTAX_STATUS_NORMAL }, { "inherit_from", CF_DATA_TYPE_BODY, .range.validation_string = "", "Body from which attributes will be inherited", SYNTAX_STATUS_NORMAL } ,
{ "include_start_delimiter" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "Whether to include the section delimiter. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "include_end_delimiter" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "Whether to include the section delimiter. Default value: false" , SYNTAX_STATUS_NORMAL },
{ "select_start" , CF_DATA_TYPE_STRING, .range.validation_string = ".*" , "Regular expression matching start of edit region" , SYNTAX_STATUS_NORMAL },
{ "select_end" , CF_DATA_TYPE_STRING, .range.validation_string = ".*" , "Regular expression matches end of edit region from start" , SYNTAX_STATUS_NORMAL },
{ "select_end_match_eof" , CF_DATA_TYPE_OPTION, .range.validation_string = "true,false,yes,no,on,off" , "Whether to include EOF as end of the region. Default value: false" , SYNTAX_STATUS_NORMAL },
{ NULL, CF_DATA_TYPE_NONE, .range.validation_string = NULL, .status = SYNTAX_STATUS_NORMAL }
}

Definition at line 67 of file mod_files.c.