codekingpro/portable-devtools
114k
1" Vim syntax file2" Language: sudoers(5) configuration files3" Maintainer: Eisuke Kawashima ( e.kawaschima+vim AT gmail.com )4" Previous Maintainer: Nikolai Weibull <now@bitwi.se>5" Latest Change: 2026 Mar 116 7if exists("b:current_syntax")8 finish9endif10 11let s:cpo_save = &cpo12set cpo&vim13 14" TODO: instead of 'skipnl', we would like to match a specific group that would15" match \\$ and then continue with the nextgroup, actually, the skipnl doesn't16" work...17" TODO: treat 'ALL' like a special (yay, a bundle of new rules!!!)18 19syn match sudoersUserSpec '^' nextgroup=@sudoersUserInSpec skipwhite20 21syn match sudoersSpecEquals contained '=' nextgroup=@sudoersCmndSpecList skipwhite22 23syn cluster sudoersCmndSpecList contains=sudoersUserRunasBegin,sudoersOptionSpec,sudoersTagSpec,@sudoersCmndInSpec24 25syn keyword sudoersTodo contained TODO FIXME XXX NOTE26 27syn region sudoersComment display oneline start='#' end='$' contains=sudoersTodo28syn region sudoersInclude display oneline start='[#@]\%(include\|includedir\)\s\+\S\+' end='$'29 30syn keyword sudoersAlias User_Alias Runas_Alias nextgroup=sudoersUserAlias skipwhite skipnl31syn keyword sudoersAlias Host_Alias nextgroup=sudoersHostAlias skipwhite skipnl32syn keyword sudoersAlias Cmnd_Alias nextgroup=sudoersCmndAlias skipwhite skipnl33 34syn match sudoersUserAlias contained '\<\u[A-Z0-9_]*\>' nextgroup=sudoersUserAliasEquals skipwhite skipnl35syn match sudoersUserNameInList contained '\<\l[-a-z0-9_]*\>' nextgroup=@sudoersUserList skipwhite skipnl36syn match sudoersUIDInList contained '#\d\+\>' nextgroup=@sudoersUserList skipwhite skipnl37syn match sudoersGroupInList contained '%\l[-a-z0-9_]*\>' nextgroup=@sudoersUserList skipwhite skipnl38syn match sudoersGIDInList contained '%#\d\+\>' nextgroup=@sudoersUserList skipwhite skipnl39syn match sudoersUserNetgroupInList contained '+\l[-a-z0-9_]*\>' nextgroup=@sudoersUserList skipwhite skipnl40syn match sudoersUserAliasInList contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersUserList skipwhite skipnl41syn keyword sudoersUserAllInList contained ALL nextgroup=@sudoersUserList skipwhite skipnl42 43syn match sudoersUserName contained '\<\l[-a-z0-9_]*\>' nextgroup=sudoersUserComma,@sudoersParameter skipwhite skipnl44syn match sudoersUID contained '#\d\+\>' nextgroup=sudoersUserComma,@sudoersParameter skipwhite skipnl45syn match sudoersGroup contained '%\l[-a-z0-9_]*\>' nextgroup=sudoersUserComma,@sudoersParameter skipwhite skipnl46syn match sudoersGID contained '%#\d\+\>' nextgroup=sudoersUserComma,@sudoersParameter skipwhite skipnl47syn match sudoersUserNetgroup contained '+\l[-a-z0-9_]*\>' nextgroup=sudoersUserComma,@sudoersParameter skipwhite skipnl48syn match sudoersUserAliasRef contained '\<\u[A-Z0-9_]*\>' nextgroup=sudoersUserComma,@sudoersParameter skipwhite skipnl49syn keyword sudoersUserAll contained ALL nextgroup=sudoersUserComma,@sudoersParameter skipwhite skipnl50syn match sudoersUserComma contained ',' nextgroup=sudoersUserNegation,sudoersUserName,sudoersUID,sudoersGroup,sudoersGID,sudoersUserNetgroup,sudoersUserAliasRef,sudoersUserAll skipwhite skipnl51 52syn match sudoersUserNameInSpec contained '\<\l[-a-z0-9_]*\>' nextgroup=@sudoersUserSpec skipwhite skipnl53syn region sudoersUIDInSpec display oneline start='#\d\+\>' end='' nextgroup=@sudoersUserSpec skipwhite skipnl54syn match sudoersGroupInSpec contained '%\l[-a-z0-9_]*\>' nextgroup=@sudoersUserSpec skipwhite skipnl55syn match sudoersGIDInSpec contained '%#\d\+\>' nextgroup=@sudoersUserSpec skipwhite skipnl56syn match sudoersUserNetgroupInSpec contained '+\l[-a-z0-9_]*\>' nextgroup=@sudoersUserSpec skipwhite skipnl57syn match sudoersUserAliasInSpec contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersUserSpec skipwhite skipnl58syn keyword sudoersUserAllInSpec contained ALL nextgroup=@sudoersUserSpec skipwhite skipnl59 60syn match sudoersUserNameInRunas contained '\<\l[-a-z0-9_]*\>' nextgroup=@sudoersUserRunas skipwhite skipnl61syn match sudoersUIDInRunas contained '#\d\+\>' nextgroup=@sudoersUserRunas skipwhite skipnl62syn match sudoersGroupInRunas contained '%\l[-a-z0-9_]*\>' nextgroup=@sudoersUserRunas skipwhite skipnl63syn match sudoersGIDInRunas contained '%#\d\+\>' nextgroup=@sudoersUserRunas skipwhite skipnl64syn match sudoersUserNetgroupInRunas contained '+\l[-a-z0-9_]*\>' nextgroup=@sudoersUserRunas skipwhite skipnl65syn match sudoersUserAliasInRunas contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersUserRunas skipwhite skipnl66syn keyword sudoersUserAllInRunas contained ALL nextgroup=@sudoersUserRunas skipwhite skipnl67 68syn match sudoersHostAlias contained '\<\u[A-Z0-9_]*\>' nextgroup=sudoersHostAliasEquals skipwhite skipnl69syn match sudoersHostNameInList contained '\<\l[a-z0-9_-]*\>' nextgroup=@sudoersHostList skipwhite skipnl70syn match sudoersIPAddrInList contained '\<\%(\d\{1,3}\.\)\{3}\d\{1,3}\>' nextgroup=@sudoersHostList skipwhite skipnl71syn match sudoersNetworkInList contained '\<\%(\d\{1,3}\.\)\{3}\d\{1,3}\%(/\%(\%(\d\{1,3}\.\)\{3}\d\{1,3}\|\d\+\)\)\=\>' nextgroup=@sudoersHostList skipwhite skipnl72syn match sudoersHostNetgroupInList contained '+\l\+\>' nextgroup=@sudoersHostList skipwhite skipnl73syn match sudoersHostAliasInList contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersHostList skipwhite skipnl74 75syn match sudoersHostName contained '\<\l[a-z0-9_-]*\>' nextgroup=sudoersHostComma,@sudoersParameter skipwhite skipnl76syn match sudoersIPAddr contained '\<\%(\d\{1,3}\.\)\{3}\d\{1,3}\>' nextgroup=sudoersHostComma,@sudoersParameter skipwhite skipnl77syn match sudoersNetwork contained '\<\%(\d\{1,3}\.\)\{3}\d\{1,3}/\%(\%(\d\{1,3}\.\)\{3}\d\{1,3}\|\d\+\)\>' nextgroup=sudoersHostComma,@sudoersParameter skipwhite skipnl78syn match sudoersHostNetgroup contained '+\l\+\>' nextgroup=sudoersHostComma,@sudoersParameter skipwhite skipnl79syn match sudoersHostAliasRef contained '\<\u[A-Z0-9_]*\>' nextgroup=sudoersHostComma,@sudoersParameter skipwhite skipnl80syn keyword sudoersHostAll contained ALL nextgroup=sudoersHostComma,@sudoersParameter skipwhite skipnl81syn match sudoersHostComma contained ',' nextgroup=sudoersHostNegation,sudoersHostName,sudoersIPAddr,sudoersNetwork,sudoersHostNetgroup,sudoersHostAliasRef,sudoersHostAll skipwhite skipnl82 83syn match sudoersCmndName contained '/[/A-Za-z0-9._-]\+' nextgroup=sudoersCmndComma,@sudoersParameter skipwhite skipnl84syn keyword sudoersCmndSpecial contained list sudoedit ALL nextgroup=sudoersCmndComma,@sudoersParameter skipwhite skipnl85syn match sudoersCmndAliasRef contained '\<\u[A-Z0-9_]*\>' nextgroup=sudoersCmndComma,@sudoersParameter skipwhite skipnl86syn match sudoersCmndComma contained ',' nextgroup=sudoersCmndNegation,sudoersCmndName,sudoersCmndSpecial,sudoersCmndAliasRef skipwhite skipnl87 88syn match sudoersHostNameInSpec contained '\<\l[a-z0-9_-]*\>' nextgroup=@sudoersHostSpec skipwhite skipnl89syn match sudoersIPAddrInSpec contained '\<\%(\d\{1,3}\.\)\{3}\d\{1,3}\>' nextgroup=@sudoersHostSpec skipwhite skipnl90syn match sudoersNetworkInSpec contained '\<\%(\d\{1,3}\.\)\{3}\d\{1,3}/\%(\%(\d\{1,3}\.\)\{3}\d\{1,3}\|\d\+\)\>' nextgroup=@sudoersHostSpec skipwhite skipnl91syn match sudoersHostNetgroupInSpec contained '+\l\+\>' nextgroup=@sudoersHostSpec skipwhite skipnl92syn match sudoersHostAliasInSpec contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersHostSpec skipwhite skipnl93syn keyword sudoersHostAllInSpec contained ALL nextgroup=@sudoersHostSpec skipwhite skipnl94 95syn match sudoersCmndAlias contained '\<\u[A-Z0-9_]*\>' nextgroup=sudoersCmndAliasEquals skipwhite skipnl96syn match sudoersCmndNameInList contained '[^[:space:],:=\\]\+\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=@sudoersCmndList,sudoersCommandEmpty,sudoersCommandArgs skipwhite97syn match sudoersCmndAliasInList contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersCmndList skipwhite skipnl98 99syn match sudoersCmndNameInSpec contained '[^[:space:],:=\\]\+\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=@sudoersCmndSpec,sudoersCommandEmptyInSpec,sudoersCommandArgsInSpec skipwhite100syn match sudoersCmndAliasInSpec contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersCmndSpec skipwhite skipnl101syn keyword sudoersCmndSpecialInSpec contained list sudoedit ALL nextgroup=@sudoersCmndSpec skipwhite skipnl102 103syn keyword sudoersCmndDigestInList contained sha224 sha256 sha384 sha512 nextgroup=sudoersCmndDigestColon skipwhite skipnl104syn match sudoersCmndDigestColon contained ':' nextgroup=sudoersDigestHex,sudoersDigestBase64 skipwhite skipnl105syn match sudoersDigestHex contained '\<\x\+\>' nextgroup=sudoersCmndDigestComma,sudoersCmndNegationInList,sudoersCmndNameInList,sudoersCmndAliasInList skipwhite skipnl106syn match sudoersDigestBase64 contained '\<[A-Za-z0-9+/]\+=*' nextgroup=sudoersCmndDigestComma,sudoersCmndNegationInList,sudoersCmndNameInList,sudoersCmndAliasInList skipwhite skipnl107syn match sudoersCmndDigestComma contained ',' nextgroup=sudoersCmndDigestInList skipwhite skipnl108 109syn match sudoersUserAliasEquals contained '=' nextgroup=@sudoersUserInList skipwhite skipnl110syn match sudoersUserListComma contained ',' nextgroup=@sudoersUserInList skipwhite skipnl111syn match sudoersUserListColon contained ':' nextgroup=sudoersUserAlias skipwhite skipnl112syn cluster sudoersUserList contains=sudoersUserListComma,sudoersUserListColon113 114syn match sudoersUserSpecComma contained ',' nextgroup=@sudoersUserInSpec skipwhite skipnl115syn cluster sudoersUserSpec contains=sudoersUserSpecComma,@sudoersHostInSpec116 117syn match sudoersUserRunasBegin contained '(' nextgroup=@sudoersUserInRunas,sudoersUserRunasColon,sudoersUserRunasEnd skipwhite skipnl118syn match sudoersUserRunasComma contained ',' nextgroup=@sudoersUserInRunas skipwhite skipnl119syn match sudoersUserRunasColon contained ':' nextgroup=@sudoersUserInRunas,sudoersUserRunasEnd skipwhite skipnl120syn match sudoersUserRunasEnd contained ')' nextgroup=sudoersOptionSpec,sudoersTagSpec,@sudoersCmndInSpec skipwhite skipnl121syn cluster sudoersUserRunas contains=sudoersUserRunasComma,sudoersUserRunasColon,@sudoersUserInRunas,sudoersUserRunasEnd122 123 124syn match sudoersHostAliasEquals contained '=' nextgroup=@sudoersHostInList skipwhite skipnl125syn match sudoersHostListComma contained ',' nextgroup=@sudoersHostInList skipwhite skipnl126syn match sudoersHostListColon contained ':' nextgroup=sudoersHostAlias skipwhite skipnl127syn cluster sudoersHostList contains=sudoersHostListComma,sudoersHostListColon128 129syn match sudoersHostSpecComma contained ',' nextgroup=@sudoersHostInSpec skipwhite skipnl130syn cluster sudoersHostSpec contains=sudoersHostSpecComma,sudoersSpecEquals131 132 133syn match sudoersCmndAliasEquals contained '=' nextgroup=@sudoersCmndInList skipwhite skipnl134syn match sudoersCmndListComma contained ',' nextgroup=@sudoersCmndInList skipwhite skipnl135syn match sudoersCmndListColon contained ':' nextgroup=sudoersCmndAlias skipwhite skipnl136syn cluster sudoersCmndList contains=sudoersCmndListComma,sudoersCmndListColon137 138syn match sudoersCmndSpecComma contained ',' nextgroup=@sudoersCmndSpecList skipwhite skipnl139syn match sudoersCmndSpecColon contained ':' nextgroup=@sudoersHostInSpec skipwhite skipnl140syn cluster sudoersCmndSpec contains=sudoersCmndSpecComma,sudoersCmndSpecColon141 142syn cluster sudoersUserInList contains=sudoersUserNegationInList,sudoersUserNameInList,sudoersUIDInList,sudoersGroupInList,sudoersGIDInList,sudoersUserNetgroupInList,sudoersUserAliasInList,sudoersUserAllInList143syn cluster sudoersHostInList contains=sudoersHostNegationInList,sudoersHostNameInList,sudoersIPAddrInList,sudoersNetworkInList,sudoersHostNetgroupInList,sudoersHostAliasInList144syn cluster sudoersCmndInList contains=sudoersCmndDigestInList,sudoersCmndNegationInList,sudoersCmndNameInList,sudoersCmndAliasInList145 146syn cluster sudoersUser contains=sudoersUserNegation,sudoersUserName,sudoersUID,sudoersGroup,sudoersGID,sudoersUserNetgroup,sudoersUserAliasRef,sudoersUserAll147syn cluster sudoersHost contains=sudoersHostNegation,sudoersHostName,sudoersIPAddr,sudoersNetwork,sudoersHostNetgroup,sudoersHostAll,sudoersHostAliasRef148syn cluster sudoersCmnd contains=sudoersCmndNegation,sudoersCmndName,sudoersCmndSpecial,sudoersCmndAliasRef149 150syn cluster sudoersUserInSpec contains=sudoersUserNegationInSpec,sudoersUserNameInSpec,sudoersUIDInSpec,sudoersGroupInSpec,sudoersGIDInSpec,sudoersUserNetgroupInSpec,sudoersUserAliasInSpec,sudoersUserAllInSpec151syn cluster sudoersHostInSpec contains=sudoersHostNegationInSpec,sudoersHostNameInSpec,sudoersIPAddrInSpec,sudoersNetworkInSpec,sudoersHostNetgroupInSpec,sudoersHostAliasInSpec,sudoersHostAllInSpec152syn cluster sudoersUserInRunas contains=sudoersUserNegationInRunas,sudoersUserNameInRunas,sudoersUIDInRunas,sudoersGroupInRunas,sudoersGIDInRunas,sudoersUserNetgroupInRunas,sudoersUserAliasInRunas,sudoersUserAllInRunas153syn cluster sudoersCmndInSpec contains=sudoersCmndNegationInSpec,sudoersCmndNameInSpec,sudoersCmndAliasInSpec,sudoersCmndSpecialInSpec154 155syn match sudoersUserNegationInList contained '!\+' nextgroup=@sudoersUserInList skipwhite skipnl156syn match sudoersHostNegationInList contained '!\+' nextgroup=@sudoersHostInList skipwhite skipnl157syn match sudoersCmndNegationInList contained '!\+' nextgroup=@sudoersCmndInList skipwhite skipnl158 159syn match sudoersUserNegation contained '!\+' nextgroup=@sudoersUser skipwhite skipnl160syn match sudoersHostNegation contained '!\+' nextgroup=@sudoersHost skipwhite skipnl161syn match sudoersCmndNegation contained '!\+' nextgroup=@sudoersCmnd skipwhite skipnl162 163syn match sudoersUserNegationInSpec contained '!\+' nextgroup=@sudoersUserInSpec skipwhite skipnl164syn match sudoersHostNegationInSpec contained '!\+' nextgroup=@sudoersHostInSpec skipwhite skipnl165syn match sudoersUserNegationInRunas contained '!\+' nextgroup=@sudoersUserInRunas skipwhite skipnl166syn match sudoersCmndNegationInSpec contained '!\+' nextgroup=@sudoersCmndInSpec skipwhite skipnl167 168syn match sudoersCommandArgs contained '[^[:space:],:=\\]\+\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=sudoersCommandArgs,@sudoersCmndList skipwhite169syn match sudoersCommandEmpty contained '""' nextgroup=@sudoersCmndList skipwhite skipnl170 171syn match sudoersCommandArgsInSpec contained '[^[:space:],:=\\]\+\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=sudoersCommandArgsInSpec,@sudoersCmndSpec skipwhite172syn match sudoersCommandEmptyInSpec contained '""' nextgroup=@sudoersCmndSpec skipwhite skipnl173 174syn keyword sudoersDefaultEntry Defaults nextgroup=sudoersDefaultTypeAt,sudoersDefaultTypeColon,sudoersDefaultTypeGreaterThan,sudoersDefaultTypeBang,sudoersDefaultTypeAny175syn match sudoersDefaultTypeAt contained '@' nextgroup=@sudoersHost skipwhite skipnl176syn match sudoersDefaultTypeColon contained ':' nextgroup=@sudoersUser skipwhite skipnl177syn match sudoersDefaultTypeGreaterThan contained '>' nextgroup=@sudoersUser skipwhite skipnl178syn match sudoersDefaultTypeBang contained '!' nextgroup=@sudoersCmnd skipwhite skipnl179syn match sudoersDefaultTypeAny contained '\s' nextgroup=@sudoersParameter skipwhite skipnl180 181" TODO: could also deal with special characters here182syn match sudoersParameterNegation contained '!\+' nextgroup=sudoersBooleanParameter,sudoersIntegerOrBooleanParameter,sudoersModeOrBooleanParameter,sudoersFloatOrBooleanParameter,sudoersTimeoutOrBooleanParameter,sudoersStringOrBooleanParameter,sudoersListParameter skipwhite skipnl183syn keyword sudoersBooleanParameter contained skipwhite skipnl184 \ nextgroup=sudoersParameterListComma185 \ always_query_group_plugin186 \ always_set_home187 \ authenticate188 \ case_insensitive_group189 \ case_insensitive_user190 \ closefrom_override191 \ compress_io192 \ env_editor193 \ env_reset194 \ exec_background195 \ fast_glob196 \ fqdn197 \ ignore_audit_errors198 \ ignore_dot199 \ ignore_iolog_errors200 \ ignore_local_sudoers201 \ ignore_logfile_errors202 \ ignore_unknown_defaults203 \ insults204 \ intercept205 \ intercept_allow_setid206 \ intercept_authenticate207 \ intercept_verify208 \ iolog_flush209 \ log_allowed210 \ log_denied211 \ log_exit_status212 \ log_host213 \ log_input214 \ log_output215 \ log_passwords216 \ log_server_keepalive217 \ log_server_verify218 \ log_stderr219 \ log_stdin220 \ log_stdout221 \ log_subcmds222 \ log_ttyin223 \ log_ttyout224 \ log_year225 \ long_otp_prompt226 \ mail_all_cmnds227 \ mail_always228 \ mail_badpass229 \ mail_no_host230 \ mail_no_perms231 \ mail_no_user232 \ match_group_by_gid233 \ netgroup_tuple234 \ noexec235 \ noninteractive_auth236 \ pam_acct_mgmt237 \ pam_rhost238 \ pam_ruser239 \ pam_session240 \ pam_setcred241 \ pam_silent242 \ passprompt_override243 \ path_info244 \ preserve_groups245 \ pwfeedback246 \ requiretty247 \ root_sudo248 \ rootpw249 \ runas_allow_unknown_id250 \ runas_check_shell251 \ runaspw252 \ selinux253 \ set_home254 \ set_logname255 \ set_utmp256 \ setenv257 \ shell_noargs258 \ stay_setuid259 \ sudoedit_checkdir260 \ sudoedit_follow261 \ syslog_pid262 \ targetpw263 \ tty_tickets264 \ umask_override265 \ use_loginclass266 \ use_netgroups267 \ use_pty268 \ user_command_timeouts269 \ utmp_runas270 \ visiblepw271 272syn keyword sudoersIntegerParameter contained273 \ nextgroup=sudoersIntegerParameterEquals274 \ skipwhite skipnl275 \ closefrom276 \ maxseq277 \ passwd_tries278 \ syslog_maxlen279 280syn keyword sudoersIntegerOrBooleanParameter contained281 \ nextgroup=sudoersIntegerParameterEquals,sudoersParameterListComma282 \ skipwhite skipnl283 \ loglinelen284 285syn keyword sudoersFloatOrBooleanParameter contained286 \ nextgroup=sudoersFloatParameterEquals,sudoersParameterListComma287 \ skipwhite skipnl288 \ passwd_timeout289 \ timestamp_timeout290 291syn keyword sudoersModeParameter contained292 \ nextgroup=sudoersModeParameterEquals293 \ skipwhite skipnl294 \ iolog_mode295 296syn keyword sudoersModeOrBooleanParameter contained297 \ nextgroup=sudoersModeParameterEquals,sudoersParameterListComma298 \ skipwhite skipnl299 \ umask300 301syn keyword sudoersTimeoutOrBooleanParameter contained302 \ nextgroup=sudoersTimeoutParameterEquals,sudoersParameterListComma303 \ skipwhite skipnl304 \ command_timeout305 \ log_server_timeout306 307syn keyword sudoersStringParameter contained308 \ nextgroup=sudoersStringParameterEquals309 \ skipwhite skipnl310 \ apparmor_profile311 \ askpass312 \ authfail_message313 \ badpass_message314 \ cmddenial_message315 \ group_plugin316 \ intercept_type317 \ iolog_file318 \ limitprivs319 \ log_format320 \ mailsub321 \ noexec_file322 \ pam_askpass_service323 \ pam_login_service324 \ pam_service325 \ passprompt326 \ privs327 \ role328 \ runas_default329 \ sudoers_locale330 \ timestamp_type331 \ timestampowner332 \ type333 334syn keyword sudoersStringOrBooleanParameter contained335 \ nextgroup=sudoersStringParameterEquals,sudoersParameterListComma336 \ skipwhite skipnl337 \ admin_flag338 \ editor339 \ env_file340 \ exempt_group341 \ fdexec342 \ iolog_dir343 \ iolog_group344 \ iolog_user345 \ lecture346 \ lecture_file347 \ lecture_status_dir348 \ listpw349 \ log_server_cabundle350 \ log_server_peer_cert351 \ log_server_peer_key352 \ logfile353 \ mailerflags354 \ mailerpath355 \ mailfrom356 \ mailto357 \ restricted_env_file358 \ rlimit_as359 \ rlimit_core360 \ rlimit_cpu361 \ rlimit_data362 \ rlimit_fsize363 \ rlimit_locks364 \ rlimit_memlock365 \ rlimit_nofile366 \ rlimit_nproc367 \ rlimit_rss368 \ rlimit_stack369 \ runcwd370 \ secure_path371 \ syslog372 \ syslog_badpri373 \ syslog_goodpri374 \ timestampdir375 \ verifypw376 377syn keyword sudoersListParameter contained378 \ nextgroup=sudoersListParameterEquals,sudoersParameterListComma379 \ skipwhite skipnl380 \ env_check381 \ env_delete382 \ env_keep383 \ log_servers384 \ passprompt_regex385 386syn match sudoersParameterListComma contained ',' nextgroup=@sudoersParameter skipwhite skipnl387 388syn cluster sudoersParameter contains=sudoersParameterNegation,sudoersBooleanParameter,sudoersIntegerParameter,sudoersIntegerOrBooleanParameter,sudoersModeParameter,sudoersModeOrBooleanParameter,sudoersFloatOrBooleanParameter,sudoersTimeoutOrBooleanParameter,sudoersStringParameter,sudoersStringOrBooleanParameter,sudoersListParameter389 390syn match sudoersIntegerParameterEquals contained '=' nextgroup=sudoersIntegerValue skipwhite skipnl391syn match sudoersModeParameterEquals contained '=' nextgroup=sudoersModeValue skipwhite skipnl392syn match sudoersFloatParameterEquals contained '=' nextgroup=sudoersFloatValue skipwhite skipnl393syn match sudoersTimeoutParameterEquals contained '=' nextgroup=sudoersTimeoutValue skipwhite skipnl394syn match sudoersStringParameterEquals contained '=' nextgroup=sudoersStringValue skipwhite skipnl395syn match sudoersListParameterEquals contained '[+-]\==' nextgroup=sudoersListValue skipwhite skipnl396 397syn match sudoersIntegerValue contained '\<\d\+\>' nextgroup=sudoersParameterListComma skipwhite skipnl398syn match sudoersModeValue contained '\<\o\+\>' nextgroup=sudoersParameterListComma skipwhite skipnl399syn match sudoersFloatValue contained '-\?\%(\<\d\+\>\|\<\d\+\%(\.\%(\d\+\>\)\?\)\?\|\.\d\+\>\)' nextgroup=sudoersParameterListComma skipwhite skipnl400syn match sudoersTimeoutValue contained '\<\d\+\>' nextgroup=sudoersParameterListComma skipwhite skipnl401syn match sudoersTimeoutValue contained '\<\%(\d\+[dDhHmMsS]\)\+\>' nextgroup=sudoersParameterListComma skipwhite skipnl402syn match sudoersStringValue contained '\s*\zs[^[:space:],:=\\]*\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=sudoersParameterListComma skipwhite skipnl403syn region sudoersStringValue contained start=+\s*\zs"+ skip=+\\"+ end=+"+ nextgroup=sudoersParameterListComma skipwhite skipnl404syn match sudoersListValue contained '\s*\zs[^[:space:],:=\\]*\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=sudoersParameterListComma skipwhite skipnl405syn region sudoersListValue contained start=+\s*\zs"+ skip=+\\"+ end=+"+ nextgroup=sudoersParameterListComma skipwhite skipnl406 407syn keyword sudoersOptionSpec contained ROLE TYPE nextgroup=sudoersSELinuxSpecEquals skipwhite408syn keyword sudoersOptionSpec contained APPARMOR_PROFILE nextgroup=sudoersAppArmorSpecEquals skipwhite409syn keyword sudoersOptionSpec contained PRIVS LIMITPRIVS nextgroup=sudoersSolarisPrivSpecEquals skipwhite410syn keyword sudoersOptionSpec contained NOTBEFORE NOTAFTER nextgroup=sudoersDateSpecEquals skipwhite411syn keyword sudoersOptionSpec contained TIMEOUT nextgroup=sudoersTimeoutSpecEquals skipwhite412syn keyword sudoersOptionSpec contained CWD CHROOT nextgroup=sudoersDirectorySpecEquals skipwhite413 414syn match sudoersSELinuxSpecEquals contained '=' nextgroup=sudoersSELinuxSpecParam skipwhite skipnl415syn match sudoersAppArmorSpecEquals contained '=' nextgroup=sudoersAppArmorSpecParam skipwhite skipnl416syn match sudoersSolarisPrivSpecEquals contained '=' nextgroup=sudoersSolarisPrivSpecParam skipwhite skipnl417syn match sudoersDateSpecEquals contained '=' nextgroup=sudoersDateSpecParam skipwhite skipnl418syn match sudoersTimeoutSpecEquals contained '=' nextgroup=sudoersTimeoutSpecParam skipwhite skipnl419syn match sudoersDirectorySpecEquals contained '=' nextgroup=sudoersDirectorySpecParam,sudoersDirectorySpecParamError skipwhite skipnl420 421syn match sudoersSELinuxSpecParam contained /\<[A-Za-z0-9_]\+\>/ nextgroup=sudoersOptionSpec,sudoersTagSpec,@sudoersCmndInSpec skipwhite skipnl422syn match sudoersAppArmorSpecParam contained /\S\+/ nextgroup=sudoersOptionSpec,sudoersTagSpec,@sudoersCmndInSpec skipwhite skipnl423syn match sudoersSolarisPrivSpecParam contained /\S\+/ nextgroup=sudoersOptionSpec,sudoersTagSpec,@sudoersCmndInSpec skipwhite skipnl424syn match sudoersDateSpecParam contained /\<\d\{10\}\%(\d\d\)\{0,2\}\%(Z\|[+-]\d\{4\}\)\?\>/ nextgroup=sudoersOptionSpec,sudoersTagSpec,@sudoersCmndInSpec skipwhite skipnl425syn match sudoersTimeoutSpecParam contained /\<\d\+\>\|\<\%(\d\+[dDhHmMsS]\)\+\>/ nextgroup=sudoersOptionSpec,sudoersTagSpec,@sudoersCmndInSpec skipwhite skipnl426syn match sudoersDirectorySpecParam contained '[/~]\f*\|\*' nextgroup=sudoersOptionSpec,sudoersTagSpec,@sudoersCmndInSpec skipwhite skipnl427syn match sudoersDirectorySpecParam contained '"\%([/~]\f\{-}\|\*\)"' nextgroup=sudoersOptionSpec,sudoersTagSpec,@sudoersCmndInSpec skipwhite skipnl428 429syn keyword sudoersTagSpec contained EXEC NOEXEC FOLLOW NOFOLLOW LOG_INPUT NOLOG_INPUT LOG_OUTPUT NOLOG_OUTPUT MAIL NOMAIL INTERCEPT NOINTERCEPT PASSWD NOPASSWD SETENV NOSETENV nextgroup=sudoersTagSpecColon skipwhite430syn match sudoersTagSpecColon contained /:/ nextgroup=sudoersTagSpec,@sudoersCmndInSpec skipwhite431 432hi def link sudoersSpecEquals Operator433hi def link sudoersTodo Todo434hi def link sudoersComment Comment435hi def link sudoersAlias Keyword436hi def link sudoersUserAlias Identifier437hi def link sudoersUserNameInList String438hi def link sudoersUIDInList Number439hi def link sudoersGroupInList PreProc440hi def link sudoersGIDInList Number441hi def link sudoersUserNetgroupInList PreProc442hi def link sudoersUserAliasInList PreProc443hi def link sudoersUserAllInList Special444hi def link sudoersUserName String445hi def link sudoersUID Number446hi def link sudoersGroup PreProc447hi def link sudoersGID Number448hi def link sudoersUserNetgroup PreProc449hi def link sudoersUserAliasRef PreProc450hi def link sudoersUserAll Special451hi def link sudoersUserComma Delimiter452hi def link sudoersUserNameInSpec String453hi def link sudoersUIDInSpec Number454hi def link sudoersGroupInSpec PreProc455hi def link sudoersGIDInSpec Number456hi def link sudoersUserNetgroupInSpec PreProc457hi def link sudoersUserAliasInSpec PreProc458hi def link sudoersUserAllInSpec Special459hi def link sudoersUserNameInRunas String460hi def link sudoersUIDInRunas Number461hi def link sudoersGroupInRunas PreProc462hi def link sudoersGIDInRunas Number463hi def link sudoersUserNetgroupInRunas PreProc464hi def link sudoersUserAliasInRunas PreProc465hi def link sudoersUserAllInRunas Special466hi def link sudoersHostAlias Identifier467hi def link sudoersHostNameInList String468hi def link sudoersIPAddrInList Number469hi def link sudoersNetworkInList Number470hi def link sudoersHostNetgroupInList PreProc471hi def link sudoersHostAliasInList PreProc472hi def link sudoersHostName String473hi def link sudoersIPAddr Number474hi def link sudoersNetwork Number475hi def link sudoersHostNetgroup PreProc476hi def link sudoersHostAll Special477hi def link sudoersHostComma Delimiter478hi def link sudoersHostAliasRef PreProc479hi def link sudoersCmndName String480hi def link sudoersCmndSpecial Special481hi def link sudoersCmndAliasRef PreProc482hi def link sudoersCmndComma Delimiter483hi def link sudoersHostNameInSpec String484hi def link sudoersIPAddrInSpec Number485hi def link sudoersNetworkInSpec Number486hi def link sudoersHostNetgroupInSpec PreProc487hi def link sudoersHostAliasInSpec PreProc488hi def link sudoersHostAllInSpec Special489hi def link sudoersCmndAlias Identifier490hi def link sudoersCmndNameInList String491hi def link sudoersCmndAliasInList PreProc492hi def link sudoersCmndNameInSpec String493hi def link sudoersCmndAliasInSpec PreProc494hi def link sudoersCmndSpecialInSpec Special495hi def link sudoersCmndDigestInList Type496hi def link sudoersCmndDigestColon Operator497hi def link sudoersDigestHex Number498hi def link sudoersDigestBase64 Number499hi def link sudoersCmndDigestComma Delimiter500hi def link sudoersUserAliasEquals Operator501hi def link sudoersUserListComma Delimiter502hi def link sudoersUserListColon Delimiter503hi def link sudoersUserSpecComma Delimiter504hi def link sudoersUserRunasBegin Delimiter505hi def link sudoersUserRunasComma Delimiter506hi def link sudoersUserRunasColon Delimiter507hi def link sudoersUserRunasEnd Delimiter508hi def link sudoersHostAliasEquals Operator509hi def link sudoersHostListComma Delimiter510hi def link sudoersHostListColon Delimiter511hi def link sudoersHostSpecComma Delimiter512hi def link sudoersCmndAliasEquals Operator513hi def link sudoersCmndListComma Delimiter514hi def link sudoersCmndListColon Delimiter515hi def link sudoersCmndSpecComma Delimiter516hi def link sudoersCmndSpecColon Delimiter517hi def link sudoersUserNegationInList Operator518hi def link sudoersHostNegationInList Operator519hi def link sudoersCmndNegationInList Operator520hi def link sudoersUserNegation Operator521hi def link sudoersHostNegation Operator522hi def link sudoersCmndNegation Operator523hi def link sudoersUserNegationInSpec Operator524hi def link sudoersHostNegationInSpec Operator525hi def link sudoersUserNegationInRunas Operator526hi def link sudoersCmndNegationInSpec Operator527hi def link sudoersCommandArgs String528hi def link sudoersCommandEmpty Special529hi def link sudoersDefaultEntry Keyword530hi def link sudoersDefaultTypeAt Special531hi def link sudoersDefaultTypeColon Special532hi def link sudoersDefaultTypeGreaterThan Special533hi def link sudoersDefaultTypeBang Special534hi def link sudoersParameterNegation Operator535hi def link sudoersBooleanParameter Identifier536hi def link sudoersIntegerParameter Identifier537hi def link sudoersIntegerOrBooleanParameter Identifier538hi def link sudoersModeParameter Identifier539hi def link sudoersModeOrBooleanParameter Identifier540hi def link sudoersFloatOrBooleanParameter Identifier541hi def link sudoersTimeoutOrBooleanParameter Identifier542hi def link sudoersStringParameter Identifier543hi def link sudoersStringOrBooleanParameter Identifier544hi def link sudoersListParameter Identifier545hi def link sudoersParameterListComma Delimiter546hi def link sudoersIntegerParameterEquals Operator547hi def link sudoersModeParameterEquals Operator548hi def link sudoersFloatParameterEquals Operator549hi def link sudoersTimeoutParameterEquals Operator550hi def link sudoersStringParameterEquals Operator551hi def link sudoersListParameterEquals Operator552hi def link sudoersIntegerValue Number553hi def link sudoersModeValue Number554hi def link sudoersFloatValue Float555hi def link sudoersTimeoutValue Number556hi def link sudoersStringValue String557hi def link sudoersListValue String558hi def link sudoersOptionSpec Special559hi def link sudoersSELinuxSpecEquals Operator560hi def link sudoersAppArmorSpecEquals Operator561hi def link sudoersSolarisPrivSpecEquals Operator562hi def link sudoersDateSpecEquals Operator563hi def link sudoersTimeoutSpecEquals Operator564hi def link sudoersDirectorySpecEquals Operator565hi def link sudoersSELinuxSpecParam String566hi def link sudoersAppArmorSpecParam String567hi def link sudoersSolarisPrivSpecParam String568hi def link sudoersDateSpecParam Number569hi def link sudoersTimeoutSpecParam Number570hi def link sudoersDirectorySpecParam String571hi def link sudoersTagSpec Special572hi def link sudoersTagSpecColon Delimiter573hi def link sudoersInclude Statement574 575let b:current_syntax = "sudoers"576 577let &cpo = s:cpo_save578unlet s:cpo_save579 