<?xmlversion="1.0" encoding="US-ASCII"?> <?rfc toc="yes"?> <?rfc symrefs="yes"?> <?rfc sortrefs="yes" ?> <?rfc compact="yes"?> <?rfc subcompact="no"?> <?rfc linkmailto="no" ?> <?rfc editing="no" ?> <?rfc comments="yes" ?> <?rfc inline="yes"?> <?rfc rfcedstyle="yes"?> <?rfc-ext allow-markup-in-artwork="yes" ?> <?rfc-ext include-index="no" ?> <!--<?rfc strict="no"?> -->version='1.0' encoding='UTF-8'?> <!DOCTYPE rfc [ <!ENTITY nbsp " "> <!ENTITY zwsp "​"> <!ENTITY nbhy "‑"> <!ENTITY wj "⁠"> ]> <rfc xmlns:xi="http://www.w3.org/2001/XInclude" category="std" docName="draft-ietf-netmod-syslog-model-33" number="9742" obsoletes="" updates="" ipr="trust200902" submissionType="IETF"consensus="true"> <?rfc toc="yes"?>consensus="true" tocInclude="true" symRefs="true" sortRefs="true" version="3" xml:lang="en"> <front> <title abbrev="Syslog Management">A YANG Data Model for Syslog Configuration</title> <seriesInfo name="RFC" value="9742"/> <author fullname="Joe Clarke" initials="J" role="editor" surname="Clarke"> <organization>Cisco</organization> <address> <postal><country>US</country><country>United States of America</country> </postal> <email>jclarke@cisco.com</email> </address> </author> <author fullname="Mahesh Jethanandani" initials="M" role="editor" surname="Jethanandani"> <organization>Kloud Services</organization> <address> <postal><country>US</country><country>United States of America</country> </postal> <email>mjethanandani@gmail.com</email> </address> </author> <author fullname="Clyde Wildes" initials="C" role="editor" surname="Wildes"> <organization>Cisco Systems Inc.</organization> <address> <postal> <street>170 West Tasman Drive</street> <city>San Jose</city> <region>CA</region> <code>95134</code><country>US</country><country>United States of America</country> </postal> <phone>+1 415 819-6111</phone> <email>clyde@clydewildes.com</email> </address> </author> <author fullname="Kiran Koushik" initials="K" role="editor" surname="Koushik"> <organization>Verizon Wireless</organization> <address> <postal> <street>500 W Dove Rd.</street> <city>Southlake</city> <region>TX</region> <code>76092</code><country>US</country><country>United States of America</country> </postal> <phone>+1 512 650-0210</phone> <email>kirankoushik.agraharasreenivasa@verizonwireless.com</email> </address> </author><date/> <area>General</area> <workgroup>NETMOD WG</workgroup><date month="March" year="2025"/> <area>OPS</area> <workgroup>netmod</workgroup> <!-- [rfced] Please insert any keywords (beyond those that appear in the title) for use on https://www.rfc-editor.org/search. --> <keyword>example</keyword> <!--[rfced] We have received guidance from Benoit Claise and the YANG Doctors that "YANG module" and "YANG data model" are preferred. We have updated the text to use these forms. Please review. --> <!-- [rfced] Some author comments are present in the XML. Please confirm that no updates related to these comments are outstanding. Note that the comments will be deleted prior to publication. --> <abstract> <t> This document defines a YANG data model for the configuration of a syslog process. It is intended that this data model be used by vendors who implement syslog collectors in their systems. </t> </abstract> </front> <middle><section title="Introduction"><section> <name>Introduction</name> <t>This document defines a YANG <xref target="RFC7950"/> configuration data model that may be used to configure the syslog feature running on a system. YANG data models can be used with network management protocols such as NETCONF <xref target="RFC6241"/> to install, manipulate, and delete the configuration of network devices.</t> <t>The data model makes use of the YANG "feature" constructwhichthat allows implementations to support only those syslog features that lie within their capabilities.</t> <t> This module can be used to configure the syslog application conceptual layers as implemented on the syslog collector. </t> <t>Essentially, a syslog process receives messages (from the kernel, processes,applicationsapplications, or other syslog processes) and processes them. The processing may involve logging to a local file,and/ordisplaying on console, and/or relaying to syslog processes on other machines. Theprocessingprocess is determined by the "facility" that originated the message and the "severity" assigned to the message by the facility.</t> <t>Such definitions of syslog protocol are defined in <xref target="RFC5424"/>,and are used in this RFC.</t> <t>The YANG data model in this document conforms to the Network Management Datastore Architecture defined in[RFC8342].</t> <section title="Requirements Language"> <t>The<xref target="RFC8342"/>.</t> <section> <name>Requirements Language</name> <t> The key words"MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY","<bcp14>MUST</bcp14>", "<bcp14>MUST NOT</bcp14>", "<bcp14>REQUIRED</bcp14>", "<bcp14>SHALL</bcp14>", "<bcp14>SHALL NOT</bcp14>", "<bcp14>SHOULD</bcp14>", "<bcp14>SHOULD NOT</bcp14>", "<bcp14>RECOMMENDED</bcp14>", "<bcp14>NOT RECOMMENDED</bcp14>", "<bcp14>MAY</bcp14>", and"OPTIONAL""<bcp14>OPTIONAL</bcp14>" in this document are to be interpreted as described inBCP 14BCP 14 <xref target="RFC2119"/> <xref target="RFC8174"/> when, and only when, they appear in all capitals, as shownhere.</t>here. </t> </section> </section><section title="Terminology"><section> <name>Terminology</name> <t> The following terms are used throughout this document: </t><ul> <li> Originator: an<dl spacing="normal" newline="false"> <dt>Originator:</dt><dd>An "originator" refers to an entity that generates syslog content to be carried in a message. The term is defined in <xreftarget="RFC5424"/> </li> <li> Relay: Atarget="RFC5424"/>.</dd> <dt>Relay:</dt> <dd>A "relay" is an entity that forwards syslog messages. It accepts messages from originators or other relays and sends them to collectors or other relays. The term is defined in <xreftarget="RFC5424"/> </li> <li> Collector: Atarget="RFC5424"/>.</dd> <dt>Collector:</dt> <dd>A "collector" gathers syslog content for further analysis. The term is defined in <xreftarget="RFC5424"/>. </li> <li> Action: Thetarget="RFC5424"/>.</dd> <dt>Action:</dt> <dd>The term "action" refers to theprocessingprocess that takes place for each syslog messagereceived. </li> </ul>received.</dd> </dl> </section><section title="NMDA Compliance"><section> <name>NMDA Compliance</name> <t>The YANG data model in this document conforms to the Network Management Datastore Architecture (NMDA) defined in <xreftarget="RFC8342"/> . </t> </section> <section title="Editorial Note (To be removed by RFC Editor)"> <t>This document contains many placeholder values that need to be replaced with finalized values at the time of publication. This note summarizes all of the substitutions that are needed. No other RFC Editor instructions are specified elsewhere in this document.</t> <t>Artwork in this document contains shorthand references to drafts in progress. Please apply the following replacements: <list style="symbols"> <t> <spanx style="verb">I-D.ietf-netconf-crypto-types</spanx> --> the assigned RFC value for draft-ietf-netconf-crypto-types</t> <t> <spanx style="verb">I-D.ietf-netconf-tls-client-server</spanx> --> the assigned RFC value for draft-ietf-netconf-tls-client-server</t> <t> <spanx style="verb">zzzz</spanx> --> the assigned RFC value for this draft</t> </list>target="RFC8342"/>. </t> </section><section title="Design<section> <name>Design of the SyslogModel">Model</name> <t> The syslog model was designed by comparing various syslog features implemented by variousvendors'vendors in different implementations. </t> <t> The module defines leafs that are common across implementations. Its simple design is meant to offer maximum flexibility. However, not all optional features defined in this document are present in all vendor implementations.Vendors therefore,Therefore, vendors need to use the feature statements to specify the optional features they support. At the same time, vendors can augment the model to add proprietary features. <xref target="extending_facilities">Extending Facilities</xref> shows an examples of how that can be realized. </t> <t>Syslog consists of originators and collectors. The following diagram shows syslog messages flowing fromoriginators,originators to collectors where filtering can take place.</t><figure> <artwork<figure title="Syslog Processing Flow"><artwork name="Syslog Process Flow" align="left"><![CDATA[ Originators +-------------+ +-------------+ +-------------+ +-------------+ | Various | | OS | | | | Remote | | Components | | Kernel | | Line Cards | | Servers | +-------------+ +-------------+ +-------------+ +-------------+ +-------------+ +-------------+ +-------------+ +-------------+ | SNMP | | Interface | | Standby | | Syslog | | Events | | Events | | Supervisor | | Itself | +-------------+ +-------------+ +-------------+ +-------------+ | | +----------------------------------------------------------------+ | | | | +-------------+--------------+ | | | v v v Collectors +----------+ +----------+ +----------------+ | | | Log | |Remote Relay(s)/| | Console | | File(s) | |Collector(s) | +----------+ +----------++----------------+ ]]> </artwork> <postamble>Figure 1. Syslog Processing Flow</postamble> </figure>+----------------+]]></artwork></figure> <t>Collectors are configured using the leaves in the syslog model "actions" containerwhichthat correspond to each message collector:</t><t> <list style="empty"><ul spacing="normal"> <li> <t>console</t> </li> <li> <t>log file(s)</t> </li> <li> <t>remote relay(s)/collector(s)</t></list> </t></li> </ul> <!-- [rfced] What field is "[RFC5424] field" referring to in this sentence? Original: Within each action, a selector is used to filter syslog messages. A selector consists of a list of one or more filters specified by facility-severity pairs, and, if supported via the select-match feature, an optional regular expression pattern match that is performed on the [RFC5424] field. --> <t>Within each action, a selector is used to filter syslog messages. A selector consists of a list of one or more filters specified by facility-severity pairs, and, if supported via the select-match feature, an optional regular expression pattern match that is performed on the <xref target="RFC5424"/> field.</t> <t>A syslog message is processed if:<figure> <artwork><![CDATA[</t> <!-- [rfced] This text has been changed from an artwork element to a sourcecode element with type="pseudocode". Please let us know if you prefer to change it to running text (within a <t> element). Original: A syslog message is processed if: There is an element of facility-list (F, S) where the message facility matches F and the message severity matches S and/or the message text matches the regex pattern (if it is present)]]> </artwork> </figure> </t>Perhaps: A syslog message is processed if there is an element of facility-list (F, S) where the message facility matches F, the message severity matches S, and/or the message text matches the regex pattern (if it is present). --> <sourcecode type="pseudocode"><![CDATA[ There is an element of facility-list (F, S) where the message facility matches F and the message severity matches S and/or the message text matches the regex pattern (if it is present)]]></sourcecode> <t>The facility is one of a specificsyslog-facility,syslog-facility or all facilities.</t> <t> The model offers the ability to select a transport that a user might want to use for a remote relay or collector. The choice is between usingUDP,UDP orTLS basedTLS-based sessions. The user can configure multiple relays or collectors, but they have to use the same transport. </t> <t>The severity is one of type syslog-severity, all severities, or none. None is a special case that can be used to disable a filter. When filtering severity, the default comparison is that messages of the specified severity and higher are selected to be logged. This is shown in the model as "default equals-or-higher". This behavior can be altered if the select-adv-compare feature is enabled to specify a compare operation and an action. Compare operations are: "equals" to select messages with this single severity, or "equals-or-higher" to select messages of the specified severity and higher. Actions are used to log the message, block the message, or stop the message from being logged.</t> <t> Many vendors extend the list of facilities available for logging in their implementation. An example is included in<xref target="extending_facilities">Extending Facilities</xref>."Extending Facilities" (<xref target="extending_facilities"/>). </t><section title="Syslog Module"><section> <name>Syslog Module</name> <t> A simplified tree representation of the data model is used in this document. Please see <xref target="RFC8340"/> for tree diagram notation. </t> <figure> <name>Tree Diagram for Syslog Model</name><artwork><![CDATA[<!-- [rfced] FYI, in the YANG tree, this line was followed by a floating question mark, which we moved up to the preceding line. This line exceeds the character limit (69 chars for <sourcecode>) by 3 characters. For updating it, which option do you prefer? Original: | | | {certificate-expiration-notification} ? Current: | | | {certificate-expiration-notification}? Option A (using the "\" line wrapping notation as used in Appendix A.1 and adding the note about line wrapping for formatting only): | | | {certificate-expiration-notificati\ on}? Option B (moving it 3 spaces to the left): | | | {certificate-expiration-notification}? --> <sourcecode type="yangtree"><![CDATA[ module: ietf-syslog +--rw syslog! +--rw actions +--rw console! {console-action}? | +--rw filter | | +--rw facility-list* [facility severity] | | +--rw facility union | | +--rw severity union | | +--rw advanced-compare {select-adv-compare}? | | +--rw compare? enumeration | | +--rw action? identityref | +--rw pattern-match? string {select-match}? +--rw file {file-action}? | +--rw log-file* [name] | +--rw name inet:uri | +--rw filter | | +--rw facility-list* [facility severity] | | +--rw facility union | | +--rw severity union | | +--rw advanced-compare {select-adv-compare}? | | +--rw compare? enumeration | | +--rw action? identityref | +--rw pattern-match? string {select-match}? | +--rw structured-data? boolean {structured-data}? | +--rw file-rotation | +--rw number-of-files? uint32 {file-limit-size}? | +--rw max-file-size? uint32 {file-limit-size}? | +--rw rollover? uint32 | | {file-limit-duration}? | +--rw retention? uint32 | {file-limit-duration}? +--rw remote {remote-action}? +--rw destination* [name] +--rw name string +--rw (transport) | +--:(udp) | | +--rw udp | | +--rw udp* [address] | | +--rw address inet:host | | +--rw port? inet:port-number | +--:(tls) | +--rw tls | +--rw tls* [address] | +--rw address inet:host | +--rw port? | | inet:port-number | +--rw client-identity! | | +--rw (auth-type) | | ... | +--rw server-authentication | | +--rw ca-certs! {server-auth-x509-cert}? | | | ... | | +--rw ee-certs! {server-auth-x509-cert}? | | | ... | | +--rw raw-public-keys! | | | {server-auth-raw-public-key}? | | | ... | | +--rw tls12-psks? empty | | | {server-auth-tls12-psk}? | | +--rw tls13-epsks? empty | | {server-auth-tls13-epsk}? | +--rw hello-params {tlscmn:hello-params}? | | +--rw tls-versions | | | ... | | +--rw cipher-suites | | ... | +--rw keepalives {tls-client-keepalives}? | +--rw peer-allowed-to-send? empty | +--rw test-peer-aliveness! | ... +--rw filter | +--rw facility-list* [facility severity] | +--rw facility union | +--rw severity union | +--rw advanced-compare {select-adv-compare}? | +--rw compare? enumeration | +--rw action? identityref +--rw pattern-match? string {select-match}? +--rw structured-data? boolean {structured-data}? +--rw facility-override? identityref +--rw source-interface? if:interface-ref | {remote-source-interface}? +--rw signing! {signed-messages}? +--rw cert-signers +--rw cert-signer* [name] | +--rw name string | +--rw cert | | +--rw public-key-format? | | | identityref | | +--rw public-key? binary | | +--rw private-key-format? | | | identityref | | +--rw (private-key-type) | | | +--:(cleartext-private-key) | | | | {cleartext-private-keys}? | | | | ... | | | +--:(hidden-private-key) | | | | {hidden-private-keys}? | | | | ... | | | +--:(encrypted-private-key) | | | {encrypted-private-keys}? | | | ... | | +--rw cert-data? | | | end-entity-cert-cms | | +---n certificate-expiration | | |{certificate-expiration-notification} ?{certificate-expiration-notification}? | | | +-- expiration-date | | | yang:date-and-time | | +---x generate-csr {csr-generation}? | | +---w input | | | ... | | +--ro output | | ... | +--rw hash-algorithm? enumeration +--rw cert-initial-repeat? uint32 +--rw cert-resend-delay? uint32 +--rw cert-resend-count? uint32 +--rw sig-max-delay? uint32 +--rw sig-number-resends? uint32 +--rw sig-resend-delay? uint32 +--rw sig-resend-count? uint32]]> </artwork>]]></sourcecode> </figure> </section> </section><section title="Syslog<section> <name>Syslog YANGModule"> <section title="TheModule</name> <section> <name>The ietf-syslogModule">Module</name> <t> This module imports typedefs from <xref target="RFC6991"/>, <xref target="RFC8343"/>, groupings from <xreftarget="I-D.ietf-netconf-crypto-types"/>,target="RFC9640"/>, and <xreftarget="I-D.ietf-netconf-tls-client-server"/>, and ittarget="RFC9645"/>. It references <xref target="RFC5424"/>, <xref target="RFC5425"/>, <xref target="RFC5426"/>, <xref target="RFC5848"/>, <xref target="RFC8089"/>, <xref target="RFC8174"/>, and <xref target="Std-1003.1-2008"/>. </t> <!-- [rfced] We have the following questions regarding the YANG module. a) What do the numbers in parentheses refer to in various descriptions? They seem to refer to the numerical codes in Table 1 of RFC 5424; should a sentence be added so that this is clear to readers? Original: "The facility for local use 0 messages (16)."; b) May we change two instances of "the compare" to "the compare operation" to match previous use? Original: "The compare can be used to specify the comparison operator that should be used to compare the syslog message severity with the specified severity." Perhaps: "The compare operation can be used to specify the comparison operator that should be used to compare the syslog message severity with the specified severity." --> <!--[rfced] Note that the YANG module has been updated per the formatting option of pyang. Please let us know any concerns. --> <figure><name>Sylog<name>Syslog YANGModel</name> <artwork><![CDATA[ <CODE BEGINS> file "ietf-syslog@2024-09-18.yang"Module</name> <sourcecode type="yang" markers="true" name="ietf-syslog@2025-03-03.yang"><![CDATA[ module ietf-syslog { yang-version 1.1; namespace "urn:ietf:params:xml:ns:yang:ietf-syslog"; prefix syslog; import ietf-inet-types { prefix inet; reference "RFC 6991: Common YANG Data Types"; } import ietf-interfaces { prefix if; reference "RFC 8343: A YANG Data Model for Interface Management"; } import ietf-tls-client { prefix tlsc; reference"I-D.ietf-netconf-tls-client-server:"RFC 9645: YANG Groupings for TLS Clients and TLS Servers"; } import ietf-crypto-types { prefix ct; reference"I-D.ietf-netconf-crypto-types:"RFC 9640: YANG Data Types and Groupings for Cryptography"; } organization "IETF NETMOD (Network Modeling) Working Group"; contact "WG Web: <https://datatracker.ietf.org/wg/netmod/> WG List: <mailto:netmod@ietf.org> Editor: Mahesh Jethanandani <mailto:mjethanandani@gmail.com> Editor: Joe Clarke <mailto:jclarke@cisco.com> Editor: Kiran Agrahara Sreenivasa <mailto:kirankoushik.agraharasreenivasa@verizonwireless.com> Editor: Clyde Wildes <mailto:clyde@clydewildes.com>"; description "This module contains a collection of YANG definitions for syslog configuration. Copyright (c)20242025 IETF Trust and the persons identified as authors of the code. All rights reserved. Redistribution and use in source and binary forms, with or without modification, is permitted pursuant to, and subject to the license terms contained in, the Revised BSD License set forth in Section 4.c of the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info). This version of this YANG module is part of RFCzzzz (https://www.rfc-editor.org/info/rfczzzz);9742 (https://www.rfc-editor.org/info/rfc9742); see the RFC itself for full legal notices. The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', 'MAY', and 'OPTIONAL' in this document are to be interpreted as described in BCP 14 (RFC 2119) (RFC 8174) when, and only when, they appear in all capitals, as shown here."; revision2024-09-182025-03-03 { description "Initial Revision"; reference "RFCzzzz:9742: Syslog YANGModel";Module"; } feature console-action { description "This feature indicates that the local console action is supported."; } feature file-action { description "This feature indicates that the local file action is supported."; } feature file-limit-size { description "This feature indicates that file logging resources are managed using size and number limits."; } feature file-limit-duration { description "This feature indicates that file logging resources are managed using time based limits."; } feature remote-action { description "This feature indicates that the remote server action is supported."; } feature remote-source-interface { description "This feature indicates that source-interface is supportedsupportedfor the remote-action."; } feature select-adv-compare { description "This feature represents the ability to select messages using the additional comparison operators when comparing the syslog message severity."; } feature select-match { description "This feature represents the ability to select messages based on a Posix 1003.2 regular expression pattern match."; } feature structured-data { description "This feature represents the ability to log messages in structured-data format."; reference "RFC 5424: The Syslog Protocol"; } feature signed-messages { description "This feature represents the ability to configure signed syslog messages."; reference "RFC 5848: Signed Syslog Messages"; } typedef syslog-severity { type enumeration { enum emergency { value 0; description "The severity level 'Emergency'indicatingindicates that the system is unusable."; } enum alert { value 1; description "The severity level 'Alert'indicatingindicates that an action must be taken immediately."; } enum critical { value 2; description "The severity level 'Critical'indicatingindicates a critical condition."; } enum error { value 3; description "The severity level 'Error'indicatingindicates an error condition."; } enum warning { value 4; description "The severity level 'Warning'indicatingindicates a warning condition."; } enum notice { value 5; description "The severity level 'Notice'indicatingindicates a normal but significant condition."; } enum info { value 6; description "The severity level 'Info'indicatingindicates an informational message."; } enum debug { value 7; description "The severity level 'Debug'indicatingindicates a debug-level message."; } } description "The definitions for Syslog message severity. Note that a lower value is a higher severity. Comparisons of equal-or-higher severity meanequal or lowerequal-or-lower numeric value"; reference "RFC 5424: The Syslog Protocol"; } identity syslog-facility { description "This identity is used as a base for all syslog facilities."; reference "RFC 5424: The Syslog Protocol"; } identity kern { base syslog-facility; description "The facility for kernel messages (0)."; reference "RFC 5424: The Syslog Protocol"; } identity user { base syslog-facility; description "The facility for user-level messages (1)."; reference "RFC 5424: The Syslog Protocol"; } identity mail { base syslog-facility; description "The facility for the mail system (2)."; reference "RFC 5424: The Syslog Protocol"; } identity daemon { base syslog-facility; description "The facility for the system daemons (3)."; reference "RFC 5424: The Syslog Protocol"; } identity auth { base syslog-facility; description "The facility for security/authorization messages (4)."; reference "RFC 5424: The Syslog Protocol"; } identity syslog { base syslog-facility; description "The facility for messages generated internally by a syslogd facility (5)."; reference "RFC 5424: The Syslog Protocol"; } identity lpr { base syslog-facility; description "The facility for the line printer subsystem (6)."; reference "RFC 5424: The Syslog Protocol"; } identity news { base syslog-facility; description "The facility for the network news subsystem (7)."; reference "RFC 5424: The Syslog Protocol"; } identity uucp { base syslog-facility; description "The facility for theUUCPUnix-to-Unix Copy (UUCP) subsystem (8)."; reference "RFC 5424: The Syslog Protocol"; } identity cron { base syslog-facility; description "The facility for the clock daemon (9)."; reference "RFC 5424: The Syslog Protocol"; } identity authpriv { base syslog-facility; description "The facility for privileged security/authorization messages (10)."; reference "RFC 5424: The Syslog Protocol"; } identity ftp { base syslog-facility; description "The facility for the FTP daemon (11)."; reference "RFC 5424: The Syslog Protocol"; } identity ntp { base syslog-facility; description "The facility for the NTP subsystem (12)."; reference "RFC 5424: The Syslog Protocol"; } identity audit { base syslog-facility; description "The facility for log audit messages (13)."; reference "RFC 5424: The Syslog Protocol"; } identity console { base syslog-facility; description "The facility for log alert messages (14)."; reference "RFC 5424: The Syslog Protocol"; } identity cron2 { base syslog-facility; description "The facility for the second clock daemon (15)."; reference "RFC 5424: The Syslog Protocol"; } identity local0 { base syslog-facility; description "The facility for local use 0 messages (16)."; reference "RFC 5424: The Syslog Protocol"; } identity local1 { base syslog-facility; description "The facility for local use 1 messages (17)."; reference "RFC 5424: The Syslog Protocol"; } identity local2 { base syslog-facility; description "The facility for local use 2 messages (18)."; reference "RFC 5424: The Syslog Protocol"; } identity local3 { base syslog-facility; description "The facility for local use 3 messages (19)."; reference "RFC 5424: The Syslog Protocol"; } identity local4 { base syslog-facility; description "The facility for local use 4 messages (20)."; reference "RFC 5424: The Syslog Protocol"; } identity local5 { base syslog-facility; description "The facility for local use 5 messages (21)."; reference "RFC 5424: The Syslog Protocol"; } identity local6 { base syslog-facility; description "The facility for local use 6 messages (22)."; reference "RFC 5424: The Syslog Protocol"; } identity local7 { base syslog-facility; description "The facility for local use 7 messages (23)."; reference "RFC 5424: The Syslog Protocol"; } identity action { description "Base identity for action for how a message will be handled."; } identity log { base action; description "This identity specifies that if the compare operation istruetrue, the message will be logged."; } identity block { base action; description "This identity specifies that if the compare operation istruetrue, the message will not be logged."; } identity stop { base action; description "This identity specifies that if the compare operation istruetrue, the message will not be logged and no further processing will occur for it."; } grouping severity-filter { description "This grouping defines the processing used to select log messages by comparing syslog message severity using the following processing rules: - if 'none', do not match. - if 'all', match. -elseelse, compare message severity with the specified severity according to the default compare rule (all messages of the specified severity and greater match) or if the select-adv-compare feature is present, use the advance-compare rule."; leaf severity { type union { type syslog-severity; type enumeration { enum none { value 2147483647; description "This enum describes the case where no severities are selected."; } enum all { value -2147483648; description "This enum describes the case where all severities are selected."; } } } mandatory true; description "This leaf specifies the syslog message severity."; } container advanced-compare { when "../severity != \"all\" and ../severity != \"none\"" { description "The advanced compare container is not applicable for severity 'all' or severity 'none'"; } if-feature "select-adv-compare"; leaf compare { type enumeration { enum equals { description "This enum specifies that the severity comparison operation will be equals."; } enum equals-or-higher { description "This enum specifies that the severity comparison operation will be equals or higher."; } } default "equals-or-higher"; description "The compare can be used to specify the comparison operator that should be used to compare the syslog message severity with the specified severity."; } leaf action { type identityref { base"action";action; } default "log"; description "The action can be used to specify how the message should be handled. This may include logging the message, not logging the message (i.e., blocking it), or stopping further processing."; } description "This container describes additional severity compare operations that can be used in place of the default severity comparison. The compare leaf specifies the type of the compare that is done and the action leaf specifies the intended result. Example: compare->equals and action->block means messages that have a severity that are equal to the specified severity will not be logged."; } } grouping selector { description "This grouping defines a syslogselectorselector, which is used to select log messages for the log-actions (console, file, remote, etc.). Choose one or both of the following: facility [<facility> <severity>...] pattern-match regular-expression-match-string If both facility and pattern-match are specified, both must match in order for a log message to be selected."; container filter { description "This container describes the syslog filter parameters."; list facility-list { key "facility severity"; ordered-by user; description "This list describes a collection of syslog facilities and severities."; leaf facility { type union { type identityref { base syslog-facility; } type enumeration { enum all { description "This enum describes the case where all facilities are requested."; } } } description "The leaf uniquely identifies a syslog facility."; } uses severity-filter; } } leaf pattern-match { if-feature "select-match"; type string; description "This leaf describes a Posix 1003.2 regular expression string that can be used to select a syslog message for logging. The match is performed on the SYSLOG-MSG field."; reference "RFC 5424: The Syslog Protocol Std-1003.1-2008 Regular Expressions"; } } grouping structured-data { description "This grouping defines the syslog structured dataoptionoption, which is used to select the format used to write log messages."; leaf structured-data { if-feature "structured-data"; type boolean; default "false"; description "This leaf describes how log messages are written. If true, messages will be written with one or more STRUCTURED-DATA elements; if false, messages will be written with STRUCTURED-DATA = NILVALUE."; reference "RFC 5424: The Syslog Protocol"; } } container syslog { presence "Enables logging."; description "This container describes the configuration parameters for syslog."; container actions { description "This container describes the log-action parameters for syslog."; container console { if-feature "console-action"; presence "Enables logging to the console"; description "This container describes the configuration parameters for console logging."; uses selector; } container file { if-feature "file-action"; description "This container describes the configuration parameters for file logging. If file-archive limits are not supplied, it is assumed that the local implementation defined limits will be used."; list log-file { key "name"; description "This list describes a collection of local logging files."; leaf name { type inet:uri { pattern 'file:.*'; } description "This leaf specifies the name of the logfilefile, which MUST use the uri scheme file:."; reference "RFC 8089: The file URI Scheme"; } uses selector; uses structured-data; container file-rotation { description "This container describes the configuration parameters for log file rotation."; leaf number-of-files { if-feature "file-limit-size"; type uint32; default "1"; description "This leaf specifies the maximum number of log files retained. Specify 1 for implementations that only support one log file."; } leaf max-file-size { if-feature "file-limit-size"; type uint32; units "megabytes"; description "This leaf specifies the maximum log file size."; } leaf rollover { if-feature "file-limit-duration"; type uint32; units "minutes"; description "This leaf specifies the length of time that log events should be written to a specific log file. Log events that arrive after the rollover period cause the current log file to be closed and a new log file to be opened."; } leaf retention { if-feature "file-limit-duration"; type uint32; units "minutes"; description "This leaf specifies the length of time that completed/closed log event files should be stored in the file system before they are removed."; } } } } container remote { if-feature "remote-action"; description "This container describes the configuration parameters for forwarding syslog messages to remote relays or collectors."; list destination { key "name"; description "This list describes a collection of remote logging destinations."; leaf name { type string; description "An arbitrary name for the endpoint to connect to."; } choice transport { mandatory true; description "This choice describes the transport option."; case udp { container udp { description "This container describes the UDP transport options."; reference "RFC 5426: Transmission of Syslog Messages over UDP"; list udp { key "address"; description "List of all UDP sessions."; leaf address { type inet:host; description "The leaf uniquely specifies the address of the remote host. One of the following must be specified: - an ipv4 address, - an ipv6 address, or a - host name."; } leaf port { type inet:port-number; default "514"; description "This leaf specifies the port number used to deliver messages to the remote server."; } } } } case tls { container tls { description "This container describes the TLS transport options."; reference "RFC 5425: Transport Layer Security (TLS) Transport Mapping for Syslog "; list tls { key "address"; description "List of allTLS basedTLS-based sessions."; leaf address { type inet:host; description "The leaf uniquely specifies the address of the remote host. One of the following must be specified: an ipv4 address, an ipv6 address, or a host name."; } leaf port { type inet:port-number; default "6514"; description "TCP port 6514 has been allocated as the default port for syslog over TLS."; } uses tlsc:tls-client-grouping; } } } } uses selector; uses structured-data; leaf facility-override { type identityref { base syslog-facility; } description "If specified, this leaf specifies the facility used to override the facility in messages delivered to the remote server."; } leaf source-interface { if-feature "remote-source-interface"; type if:interface-ref; description "This leaf sets the source interface to be used to send messages to the remote syslog server. If not set, messages can be sent on any interface."; } container signing { if-feature "signed-messages"; presence "If present, syslog-signing options is activated."; description "This container describes the configuration parameters for signed syslog messages."; reference "RFC 5848: Signed Syslog Messages"; container cert-signers { description "This container describes the signing certificate configuration for Signature Group00, which covers the case for administrators who want all Signature Blocks to be sent to a single destination."; list cert-signer { key "name"; description "This list describes a collection of syslog message signers."; leaf name { type string; description "This leaf specifies the name of the syslog message signer."; } container cert { uses ct:asymmetric-key-pair-with-cert-grouping; description "This is the certificate that is periodically sent to the remote receiver. The certificate is inherently associated with its private and public keys."; } leaf hash-algorithm { type enumeration { enum SHA1 { value 1; description "This enum describes the SHA1 algorithm."; } enum SHA256 { value 2; description "This enum describes the SHA256 algorithm."; } } description "This leaf describes the syslog signer hash algorithm used."; } } leaf cert-initial-repeat { type uint32; default "3"; description "This leaf specifies the number of times each Certificate Block should be sent before the first message is sent."; } leaf cert-resend-delay { type uint32; units "seconds"; default "3600"; description "This leaf specifies the maximum time delay in seconds until resending the Certificate Block."; } leaf cert-resend-count { type uint32; default "0"; description "This leaf specifies the maximum number of other syslog messages to send until resending the Certificate Block."; } leaf sig-max-delay { type uint32; units "seconds"; default "60"; description "This leaf specifies when to generate a new Signature Block. If this many seconds have elapsed since the message with the first message number of the Signature Block was sent, a new Signature Block should be generated."; } leaf sig-number-resends { type uint32; default "0"; description "This leaf specifies the number of times a Signature Block is resent. (It is recommended to select a value of greater than 0 in particular when the UDP transport as in RFC 5426 isused.).";used.)"; } leaf sig-resend-delay { type uint32; units "seconds"; default "5"; description "This leaf specifies when to send the next Signature Block transmission based on time. If this many seconds have elapsed since the previous sending of this Signature Block, resend it."; } leaf sig-resend-count { type uint32; default "0"; description "This leaf specifies when to send the next Signature Block transmission based on a count. If this many other syslog messages have been sent since the previous sending of this Signature Block, resend it. A value of 0 means that you don't resend based on the number of messages."; } } } } } } } }<CODE ENDS> ]]></artwork>]]></sourcecode> </figure> </section> </section><section title="Usage Examples"> <section title="Syslog<section> <name>Usage Examples</name> <section> <name>Syslog Configuration for SeverityCritical">Critical</name> <figure> <name>Syslog Configuration for Severity Critical</name> <artwork><![CDATA[ [note: '\' line wrapping for formatting only] <!-- Enable console logging of syslogs of severity critical --> <?xml version="1.0" encoding="UTF-8"?> <syslog xmlns="urn:ietf:params:xml:ns:yang:ietf-syslog"> <actions> <console> <filter> <facility-list> <facility>all</facility> <severity>critical</severity> </facility-list> </filter> </console> </actions></syslog> ]]></artwork></syslog>]]></artwork> </figure> </section><section title="Remote<section> <name>Remote SyslogConfiguration">Configuration</name> <figure> <name>Remote Syslog Configuration</name> <artwork><![CDATA[ [note: '\' line wrapping for formatting only] <!-- Enable remote logging of syslogs to udp destination foo.example.com for facility auth, severity error --> <?xml version="1.0" encoding="UTF-8"?> <syslog xmlns="urn:ietf:params:xml:ns:yang:ietf-syslog"> <actions> <remote> <destination> <name>remote1</name> <udp> <udp> <address>foo.example.com</address> </udp> </udp> <filter> <facility-list> <facility>auth</facility> <severity>error</severity> </facility-list> </filter> </destination> </remote> </actions></syslog> ]]></artwork></syslog>]]></artwork> </figure> </section> </section> <sectionanchor="Acknowledgements" title="Acknowledgements"> <t>The authors wish to thank the following who commented on this proposal:</t> <t>Andy Bierman, Martin Bjorklund, Alex Campbell, Alex Clemm, Francis Dupont, Jim Gibson, Jeffrey Haas, Bob Harold, John Heasley, Giles Heron, Lisa Huang, Mahesh Jethanandani, Warren Kumari, Jeffrey K Lange, Jan Lindblad, Chris Lonvick, Alexey Melnikov, Kathleen Moriarty, Tom Petch, Adam Roach, Juergen Schoenwaelder, Phil Shafer, Yaron Sheffer, Jason Sterne, Peter Van Horne, Kent Watsen, Bert Wijnen, Dale R Worley, and Aleksandr Zhdankin.</t> </section> <!-- Possibly a 'Contributors' section ... --> <section anchor="IANA" title="IANA Considerations"> <section title="Theanchor="IANA"> <name>IANA Considerations</name> <section> <name>The IETF XMLRegistry">Registry</name> <t>This document registers one URI in theIETF"IETF XMLregistry <xref target="RFC3688"/> . FollowingRegistry", following the format defined in <xreftarget="RFC3688"/> , the following registration is requested:</t> <t> <figure> <artwork><![CDATA[ URI: urn:ietf:params:xml:ns:yang:ietf-syslog Registrant Contact: The IESG. XML: N/A,target="RFC3688"/>:</t> <dl newline="false" spacing="compact"> <dt>URI:</dt><dd>urn:ietf:params:xml:ns:yang:ietf-syslog</dd> <dt>Registrant Contact:</dt><dd>The IESG.</dd> <dt>XML:</dt><dd>N/A; the requested URI is an XMLnamespace. ]]></artwork> </figure> </t>namespace.</dd> </dl> </section><section title="The<section> <name>The YANG Module NamesRegistry">Registry</name> <t>This document registers one YANG module in theYANG"YANG ModuleNamesNames" registry <xreftarget="RFC8525"/> . Followingtarget="RFC8525"/>, following the format in <xreftarget="RFC7950"/> , the following registration is requested:</t> <t> <figure> <artwork><![CDATA[ name: ietf-syslog namespace: urn:ietf:params:xml:ns:yang:ietf-syslog prefix: syslog reference: RFC zzzz ]]></artwork> </figure> </t>target="RFC7950"/>:</t> <dl spacing="compact" newline="false"> <dt>Name:</dt><dd>ietf-syslog</dd> <dt>Namespace:</dt><dd>urn:ietf:params:xml:ns:yang:ietf-syslog</dd> <dt>Prefix:</dt><dd>syslog</dd> <dt>Reference:</dt><dd>RFC 9742</dd> </dl> </section> </section><section title="Security Considerations"><section> <name>Security Considerations</name> <t> This section is modeled after the template defined in <xref section="3.7.1" target="RFC8407"/>. </t> <t> <!-- DNE --> The"ietf-syslog"YANG module specified in this document defines a schema for datamodelthat is designed to be accessed viaYANG-basednetwork management protocols such as NETCONF <xref target="RFC6241"/>andor RESTCONF <xref target="RFC8040"/>.These protocols haveThe lowest NETCONF layer is the secure transport layer, and the mandatory-to-implement secure transportlayers (e.g.,is Secure Shell (SSH) <xreftarget="RFC4252"/>, TLS <xref target="RFC8446"/>, and QUIC <xref target="RFC9000"/>)target="RFC4252"/>. The lowest RESTCONF layer is HTTPS, and the mandatory-to-implementmutual authentication.secure transport is TLS <xref target="RFC8446"/>. <!-- End of DNE --> </t> <t> <!-- DNE --> TheNETCONF access control modelNetwork Configuration Access Control Model (NACM) <xref target="RFC8341"/> provides the means to restrict access for particular NETCONF or RESTCONF users to a preconfigured subset of all available NETCONF or RESTCONF protocol operations and content. </t> <!-- End of DNE --> <t> This module imports groupings from ietf-crypto-types YANG module defined in <xreftarget="I-D.ietf-netconf-crypto-types">YANGtarget="RFC9640">YANG Groupings for Crypto Types</xref>. Security considerations described in that document apply to this module also. </t> <t> <!-- DNE --> There are a number of data nodes defined in this YANG module that are writable/creatable/deletable (i.e., config true, which is the default). These data nodes should be considered sensitive or vulnerable in all network environments. <!-- End of DNE --> <!--[rfced] Security Considerations: This text does not exactly match the text provided for security considerations of documents that contain YANG modules: https://wiki.ietf.org/group/ops/yang-security-guidelines Should this document be updated to match those? For example: usage of "all" vs. "some" and the additional sentences in the 5th paragraph (which start with "Logging" and "If logging"). Original: There are a number of data nodes defined in this YANG module that are writable/creatable/deletable (i.e., config true, which is the default). These data nodes should be considered sensitive or vulnerable in all network environments. Logging in particular is used to assess the state of systems and can be used to indicate a network compromise. If logging were to be disabled through malicious means, attacks may not be readily detectable. Therefore write operations (e.g., edit-config) to these data nodes without proper protection can have a negative effect on network operations and on network security. Corresponding text on https://wiki.ietf.org/group/ops/yang-security-guidelines: There are a number of data nodes defined in this YANG module that are writable/creatable/deletable (i.e., config true, which is the default). These data nodes may be considered sensitive or vulnerable in some network environments. Write operations (e.g., edit-config) to these data nodes without proper protection can have a negative effect on network operations. These are the subtrees and data nodes and their sensitivity/vulnerability: --> Logging in particular is used to assess the state of systems and can be used to indicate a network compromise. If logging were to be disabled through malicious means, attacks may not be readily detectable. Therefore, write operations (e.g., edit-config) to these data nodes without proper protection can have a negative effect on network operations and on network security. </t> <t> Inadditionaddition, there are data nodes that require careful analysis and review. These are the subtrees and data nodes and their sensitivity/vulnerability:<list hangIndent="6" style="hanging"> <t hangText=" facility-filter/pattern-match:">When</t> <dl newline="false" spacing="normal"> <dt> facility-filter/pattern-match:</dt> <dd>When writing this node, implementationsMUST<bcp14>MUST</bcp14> ensure that the regular expression pattern match is not constructed to cause a regular expressiondenial of servicedenial-of-service attack due to a pattern that causes the regular expression implementation to work very slowly (exponentially related to input size).</t> <t hangText=" remote/destination/signing/cert-signer:">When</dd> <dt> remote/destination/signing/cert-signer:</dt> <dd>When writing this subtree, implementationsMUST NOT<bcp14>MUST NOT</bcp14> specify a private key that is used for any otherpurpose.</t> </list> </t>purpose.</dd> </dl> <t> <!-- DNE --> Some of the readable data nodes in this YANG module may be considered sensitive or vulnerable in some network environments. It is thus important to control read access (e.g., via get, get-config, or notification) to these data nodes. These are the subtrees and data nodes and their sensitivity/vulnerability:<list hangIndent="6" style="hanging"> <t hangText=" remote/destination/transport:">This<!-- End of DNE --> </t> <dl newline="false" spacing="normal"> <dt> remote/destination/transport:</dt> <dd>This subtree contains information about other hosts in the network, the services available on those hosts, and the TLS transport certificate properties if TLS is selected as the transport protocol. Knowing that a service like syslog (udp/514) is enabled on thehost,host will allow a malicious user to spam the host on that port.</t> <t hangText=" remote/destination/signing:">This</dd> <dt> remote/destination/signing:</dt> <dd>This subtree contains information about the syslog message signingpropertiesproperties, including signing certificate information.</t> </list> </t></dd> </dl> <t> There are no RPC operations defined in this YANG module. </t> </section> </middle> <back><references title="Normative References"> <?rfc include="reference.I-D.ietf-netconf-crypto-types.xml"?> <?rfc include="reference.I-D.ietf-netconf-tls-client-server.xml"?> <?rfc include="reference.RFC.8343.xml"?> <?rfc include="reference.RFC.2119.xml"?> <?rfc include="reference.RFC.3688.xml"?> <?rfc include="reference.RFC.4252.xml"?> <?rfc include="reference.RFC.5424.xml"?> <?rfc include="reference.RFC.5425.xml"?> <?rfc include="reference.RFC.5426.xml"?> <?rfc include="reference.RFC.5848.xml"?> <?rfc include="reference.RFC.6241.xml"?> <?rfc include="reference.RFC.6991.xml"?> <?rfc include="reference.RFC.8525.xml"?> <?rfc include="reference.RFC.7950.xml"?> <?rfc include="reference.RFC.8040.xml"?> <?rfc include="reference.RFC.8089.xml"?> <?rfc include="reference.RFC.8174.xml"?> <?rfc include="reference.RFC.8407.xml"?> <?rfc include="reference.RFC.8341.xml"?> <?rfc include="reference.RFC.8446.xml"?> <?rfc include="reference.RFC.9000.xml"?><references> <name>References</name> <references> <name>Normative References</name> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9640.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9645.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8343.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.3688.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.4252.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.5424.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.5425.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.5426.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.5848.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.6241.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.6991.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8525.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.7950.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8040.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8089.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8407.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8341.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8446.xml"/> <!-- [rfced] References a) We have updated the Security Considerations section to reflect the guidelines shown here: https://wiki.ietf.org/group/ops/yang-security-guidelines. As a result, RFC 9000 has been removed from the Normative References. Please let us know if you prefer to cite it elsewhere. b) Please review the following reference. We note that a newer version of this standard was published in 2024; would you like to update this reference to the most current version? Original: [Std-1003.1-2008] Group, I. A. T. O., ""Chapter 9: Regular Expressions". The Open Group Base Specifications Issue 6, IEEE Std 1003.1-2008, 2016 Edition.", September 2016, <http://pubs.opengroup.org/onlinepubs/9699919799/>. Perhaps: [Std-1003.1-2024] The Open Group, "Chapter 9: Regular Expressions", The Open Group Base Specifications Issue 8, IEEE Std 1003.1-2024, 2024, <https://pubs.opengroup.org/onlinepubs/9799919799/>. --> <reference anchor="Std-1003.1-2008"target="http://pubs.opengroup.org/onlinepubs/9699919799/">target="https://pubs.opengroup.org/onlinepubs/9699919799.2016edition/"> <front> <title>"Chapter 9: RegularExpressions".Expressions" The Open Group Base Specifications Issue 6, IEEE Std 1003.1-2008, 2016Edition.</title> <author fullname="IEEE and The Open Group">Edition</title> <author> <organization>The Open Group</organization> </author> <date month="September" year="2016"/> </front> </reference> </references><references title="Informative References"> <?rfc include="reference.RFC.8340.xml"?> <?rfc include="reference.RFC.8342.xml"?><references> <name>Informative References</name> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8340.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8342.xml"/> </references> </references> <sectionanchor="tree-diagrams" title="Tree Diagrams">anchor="tree-diagrams"> <name>Tree Diagrams</name> <sectionanchor="complete-tree-diagram" title="Completeanchor="complete-tree-diagram"> <name>Complete TreeDiagram"> <figure> <artwork align="left"><![CDATA[Diagram</name> <!-- [rfced] Please review the line wrapping in Appendix A.1. Specifically, the original contained extra line breaks that were apparently not intended (e.g., before "ivate-key?"). We have updated the tree diagram to remove the extraneous line breaks. Please review; see https://www.rfc-editor.org/authors/rfc9742-rfcdiff.html and the examples below. (FYI, two hyphens are changed to one hyphen below for the sake of inclusion as a comment in the XML file.) Original: | | | | | | +-rw cleartext\ -pr ivate-key? | | | | | | binary | | | | | +-:(hidden-privat\ e-k ey) | | | | | | {hidden-p\ riv ate-keys}? Current: | | | | | | +-rw cleartext\ -private-key? | | | | | | binary | | | | | +-:(hidden-privat\ e-key) | | | | | | {hidden-p\ rivate-keys}? --> <sourcecode type="yangtree"><![CDATA[ [note: '\' line wrapping for formatting only] module: ietf-syslog +--rw syslog! +--rw actions +--rw console! {console-action}? | +--rw filter | | +--rw facility-list* [facility severity] | | +--rw facility union | | +--rw severity union | | +--rw advanced-compare {select-adv-compare}? | | +--rw compare? enumeration | | +--rw action? identityref | +--rw pattern-match? string {select-match}? +--rw file {file-action}? | +--rw log-file* [name] | +--rw name inet:uri | +--rw filter | | +--rw facility-list* [facility severity] | | +--rw facility union | | +--rw severity union | | +--rw advanced-compare {select-adv-compare}? | | +--rw compare? enumeration | | +--rw action? identityref | +--rw pattern-match? string {select-match}? | +--rw structured-data? boolean {structured-data}? | +--rw file-rotation | +--rw number-of-files? uint32 {file-limit-size}? | +--rw max-file-size? uint32 {file-limit-size}? | +--rw rollover? uint32 | | {file-limit-duration}? | +--rw retention? uint32 | {file-limit-duration}? +--rw remote {remote-action}? +--rw destination* [name] +--rw name string +--rw (transport) | +--:(udp) | | +--rw udp | | +--rw udp* [address] | | +--rw address inet:host | | +--rw port? inet:port-number | +--:(tls) | +--rw tls | +--rw tls* [address] | +--rw address inet:host | +--rw port? | | inet:port-number | +--rw client-identity! | | +--rw (auth-type) | | +--:(certificate) | | | {client-ident-x509-cert}? | | | +--rw certificate | | | +--rw (inline-or-keystore) | | | +--:(inline) | | | | {inline-definition\s-s upported}?s-supported}? | | | | +--rw inline-definition | | | | +--rw public-key-form\ at? | | | | | identityref | | | | +--rw public-key? | | | | | binary | | | | +--rw private-key-for\mat ?mat? | | | | | identityref | | | | +--rw (private-key-ty\ pe) | | | | | +--:(cleartext-pri\vat e-key)vate-key) | | | | | | {cleartex\t-p rivate-keys}?t-private-keys}? | | | | | | +--rw cleartext\-pr ivate-key?-private-key? | | | | | | binary | | | | | +--:(hidden-privat\e-k ey)e-key) | | | | | | {hidden-p\riv ate-keys}?rivate-keys}? | | | | | | +--rw hidden-pr\iva te-key?ivate-key? | | | | | | empty | | | | | +--:(encrypted-pri\vat e-key)vate-key) | | | | | {encrypte\d-p rivate-keys}?d-private-keys}? | | | | | +--rw encrypted\-pr ivate-key-private-key | | | | | +--rw encryp\ted -byted-by | | | | | +--rw encryp\ted -value-formatted-value-format | | | | | | iden\tit yreftityref | | | | | +--rw encryp\ted -valueted-value | | | | | bina\ ry | | | | +--rw cert-data? | | | | | end-entity-ce\rt- cmsrt-cms | | | | +---n certificate-exp\ira tioniration | | | | | {certificate-\exp iration-notification}?expiration-notification}? | | | | | +-- expiration-dat\ e | | | | | yang:date-\and -timeand-time | | | | +---x generate-csr | | | | {csr-generati\on} ?on}? | | | | +---w input | | | | | +---w csr-forma\ t | | | | | | identit\yre fyref | | | | | +---w csr-info | | | | | csr-inf\ o | | | | +--ro output | | | | +--ro (csr-type\ ) | | | | +--:(p10-csr\ ) | | | | +--ro p10\-cs r?-csr? | | | | p\10- csr10-csr | | | +--:(central-keystore) | | | {central-keystore-\sup ported,asymmetric-keys}?supported,asymmetric-keys}? | | | +--rw central-keystore-r\efe renceeference | | | +--rw asymmetric-key?\ | | | | ks:central-as\ymm etric-key-refymmetric-key-ref | | | | {central-keys\tor e-supported,asymmetric-keys}?tore-supported,asymmetric-keys}? | | | +--rw certificate? | | | leafref | | +--:(raw-public-key) | | | {client-ident-raw-public-ke\ y}? | | | +--rw raw-private-key | | | +--rw (inline-or-keystore) | | | +--:(inline) | | | | {inline-definition\s-s upported}?s-supported}? | | | | +--rw inline-definition | | | | +--rw public-key-form\ at? | | | | | identityref | | | | +--rw public-key? | | | | | binary | | | | +--rw private-key-for\mat ?mat? | | | | | identityref | | | | +--rw (private-key-ty\ pe) | | | | +--:(cleartext-pri\vat e-key)vate-key) | | | | | {cleartex\t-p rivate-keys}?t-private-keys}? | | | | | +--rw cleartext\-pr ivate-key?-private-key? | | | | | binary | | | | +--:(hidden-privat\e-k ey)e-key) | | | | | {hidden-p\riv ate-keys}?rivate-keys}? | | | | | +--rw hidden-pr\iva te-key?ivate-key? | | | | | empty | | | | +--:(encrypted-pri\vat e-key)vate-key) | | | | {encrypte\d-p rivate-keys}?d-private-keys}? | | | | +--rw encrypted\-pr ivate-key-private-key | | | | +--rw encryp\ted -byted-by | | | | +--rw encryp\ted -value-formatted-value-format | | | | | iden\tit yreftityref | | | | +--rw encryp\ted -valueted-value | | | | bina\ ry | | | +--:(central-keystore) | | | {central-keystore-\sup ported,asymmetric-keys}?supported,asymmetric-keys}? | | | +--rw central-keystore-r\efe rence?eference? | | | ks:central-asymm\etr ic-key-refetric-key-ref | | +--:(tls12-psk) | | | {client-ident-tls12-psk}? | | | +--rw tls12-psk | | | +--rw (inline-or-keystore) | | | | +--:(inline) | | | | | {inline-definition\s-s upported}?s-supported}? | | | | | +--rw inline-definition | | | | | +--rw key-format? | | | | | | identityref | | | | | +--rw (key-type) | | | | | +--:(cleartext-sym\met ric-key)metric-key) | | | | | | +--rw cleartext\-sy mmetric-key?-symmetric-key? | | | | | | binary | | | | | | {cleart\ext -symmetric-keys}?ext-symmetric-keys}? | | | | | +--:(hidden-symmet\ric -key)ric-key) | | | | | | {hidden-s\ymm etric-keys}?ymmetric-keys}? | | | | | | +--rw hidden-sy\mme tric-key?mmetric-key? | | | | | | empty | | | | | +--:(encrypted-sym\met ric-key)metric-key) | | | | | {encrypte\d-s ymmetric-keys}?d-symmetric-keys}? | | | | | +--rw encrypted\-sy mmetric-key-symmetric-key | | | | | +--rw encryp\ted -byted-by | | | | | +--rw encryp\ted -value-formatted-value-format | | | | | | iden\tit yreftityref | | | | | +--rw encryp\ted -valueted-value | | | | | bina\ ry | | | | +--:(central-keystore) | | | | {central-keystore-\sup ported,symmetric-keys}?supported,symmetric-keys}? | | | | +--rw central-keystore-r\efe rence?eference? | | | | ks:central-symme\tri c-key-reftric-key-ref | | | +--rw id? | | | string | | +--:(tls13-epsk) | | {client-ident-tls13-epsk}? | | +--rw tls13-epsk | | +--rw (inline-or-keystore) | | | +--:(inline) | | | | {inline-definition\s-s upported}?s-supported}? | | | | +--rw inline-definition | | | | +--rw key-format? | | | | | identityref | | | | +--rw (key-type) | | | | +--:(cleartext-sym\met ric-key)metric-key) | | | | | +--rw cleartext\-sy mmetric-key?-symmetric-key? | | | | | binary | | | | | {cleart\ext -symmetric-keys}?ext-symmetric-keys}? | | | | +--:(hidden-symmet\ric -key)ric-key) | | | | | {hidden-s\ymm etric-keys}?ymmetric-keys}? | | | | | +--rw hidden-sy\mme tric-key?mmetric-key? | | | | | empty | | | | +--:(encrypted-sym\met ric-key)metric-key) | | | | {encrypte\d-s ymmetric-keys}?d-symmetric-keys}? | | | | +--rw encrypted\-sy mmetric-key-symmetric-key | | | | +--rw encryp\ted -byted-by | | | | +--rw encryp\ted -value-formatted-value-format | | | | | iden\tit yreftityref | | | | +--rw encryp\ted -valueted-value | | | | bina\ ry | | | +--:(central-keystore) | | | {central-keystore-\sup ported,symmetric-keys}?supported,symmetric-keys}? | | | +--rw central-keystore-r\efe rence?eference? | | | ks:central-symme\tri c-key-reftric-key-ref | | +--rw external-identity | | | string | | +--rw hash? | | | tlscmn:epsk-supported-\has hhash | | +--rw context? | | | string | | +--rw target-protocol? | | | uint16 | | +--rw target-kdf? | | uint16 | +--rw server-authentication | | +--rw ca-certs! {server-auth-x509-cert}\ ? | | | +--rw (inline-or-truststore) | | | +--:(inline) | | | | {inline-definitions-supp\ort ed}?orted}? | | | | +--rw inline-definition | | | | +--rw certificate* [name] | | | | +--rw name | | | | | string | | | | +--rw cert-data | | | | | trust-anchor-cer\t-c mst-cms | | | | +---n certificate-expira\tio ntion | | | | {certificate-exp\ira tion-notification}?iration-notification}? | | | | +-- expiration-date | | | | yang:date-and\-ti me-time | | | +--:(central-truststore) | | | {central-truststore-supp\ort ed,certificates}?orted,certificates}? | | | +--rw central-truststore-refer\enc e?ence? | | | ts:central-certificate\-ba g-ref-bag-ref | | +--rw ee-certs! {server-auth-x509-cert}\ ? | | | +--rw (inline-or-truststore) | | | +--:(inline) | | | | {inline-definitions-supp\ort ed}?orted}? | | | | +--rw inline-definition | | | | +--rw certificate* [name] | | | | +--rw name | | | | | string | | | | +--rw cert-data | | | | | trust-anchor-cer\t-c mst-cms | | | | +---n certificate-expira\tio ntion | | | | {certificate-exp\ira tion-notification}?iration-notification}? | | | | +-- expiration-date | | | | yang:date-and\-ti me-time | | | +--:(central-truststore) | | | {central-truststore-supp\ort ed,certificates}?orted,certificates}? | | | +--rw central-truststore-refer\enc e?ence? | | | ts:central-certificate\-ba g-ref-bag-ref | | +--rw raw-public-keys! | | | {server-auth-raw-public-key}? | | | +--rw (inline-or-truststore) | | | +--:(inline) | | | | {inline-definitions-supp\ort ed}?orted}? | | | | +--rw inline-definition | | | | +--rw public-key* [name] | | | | +--rw name | | | | | string | | | | +--rw public-key-format | | | | | identityref | | | | +--rw public-key | | | | binary | | | +--:(central-truststore) | | | {central-truststore-supp\ort ed,public-keys}?orted,public-keys}? | | | +--rw central-truststore-refer\enc e?ence? | | | ts:central-public-key-\bag -refbag-ref | | +--rw tls12-psks? empty | | | {server-auth-tls12-psk}? | | +--rw tls13-epsks? empty | | {server-auth-tls13-epsk}? | +--rw hello-params {tlscmn:hello-params}? | | +--rw tls-versions | | | +--rw min? identityref | | | +--rw max? identityref | | +--rw cipher-suites | | +--rw cipher-suite* | | tlscsa:tls-cipher-suite-algo\rit hmrithm | +--rw keepalives {tls-client-keepalives}? | +--rw peer-allowed-to-send? empty | +--rw test-peer-aliveness! | +--rw max-wait? uint16 | +--rw max-attempts? uint8 +--rw filter | +--rw facility-list* [facility severity] | +--rw facility union | +--rw severity union | +--rw advanced-compare {select-adv-compare}? | +--rw compare? enumeration | +--rw action? identityref +--rw pattern-match? string {select-match}? +--rw structured-data? boolean {structured-data}? +--rw facility-override? identityref +--rw source-interface? if:interface-ref | {remote-source-interface}? +--rw signing! {signed-messages}? +--rw cert-signers +--rw cert-signer* [name] | +--rw name string | +--rw cert | | +--rw public-key-format? | | | identityref | | +--rw public-key? binar\ y | | +--rw private-key-format? | | | identityref | | +--rw (private-key-type) | | | +--:(cleartext-private-key) | | | | {cleartext-private-keys}? | | | | +--rw cleartext-private-key? binar\ y | | | +--:(hidden-private-key) | | | | {hidden-private-keys}? | | | | +--rw hidden-private-key? empty\ | | | +--:(encrypted-private-key) | | | {encrypted-private-keys}? | | | +--rw encrypted-private-key | | | +--rw encrypted-by | | | +--rw encrypted-value-format | | | | identityref | | | +--rw encrypted-value | | | binary | | +--rw cert-data? | | | end-entity-cert-cms | | +---n certificate-expiration | | | {certificate-expiration-notificati\on} ?on}? | | | +-- expiration-date | | | yang:date-and-time | | +---x generate-csr {csr-generation}? | | +---w input | | | +---w csr-format identityref | | | +---w csr-info csr-info | | +--ro output | | +--ro (csr-type) | | +--:(p10-csr) | | +--ro p10-csr? p10-csr | +--rw hash-algorithm? enumeration +--rw cert-initial-repeat? uint32 +--rw cert-resend-delay? uint32 +--rw cert-resend-count? uint32 +--rw sig-max-delay? uint32 +--rw sig-number-resends? uint32 +--rw sig-resend-delay? uint32 +--rw sig-resend-count? uint32]]></artwork> </figure>]]></sourcecode> </section> </section> <section> <name>Implementer Guidelines</name> <sectiontitle="Implementer Guidelines"> <section anchor="extending_facilities" title="Extending Facilities">anchor="extending_facilities"> <name>Extending Facilities</name> <t>Many vendors extend the list of facilities available for logging in their implementation. Additional facilities may not work with the syslog protocol as defined in[RFC5424] and hence<xref target="RFC5424"/>. Thus, such facilities apply for local syslog-like logging functionality.</t> <t>The following is an example that shows how additional facilities could be added to the list of available facilities(in this example two(two facilities areadded):</t> <figure> <artwork align="left"><![CDATA[ [note: '\' line wrapping for formatting only]added in this example):</t> <sourcecode type="yang" name="example-vendor-syslog-types@2025-03-03.yang"><![CDATA[ module example-vendor-syslog-types { namespace "http://example.com/ns/vendor-syslog-types"; prefix vendor-syslogtypes; import ietf-syslog { prefix syslog; } organization "Example, Inc."; contact "Example, Inc. Customer ServiceE-mail:Email: syslog-yang@example.com"; description "This module contains a collection of vendor-specific YANG type definitions forSYSLOG.";Syslog."; revision2024-03-192025-03-03 { description "Version 1.0"; reference "VendorSYSLOGSyslog Types:SYSLOGSyslog YANGModel";Module"; } identity vendor_specific_type_1 { base syslog:syslog-facility; description "Addingvendor specificvendor-specific type 1 to syslog-facility"; } identity vendor_specific_type_2 { base syslog:syslog-facility; description "Addingvendor specificvendor-specific type 2 to syslog-facility"; }} ]]></artwork> </figure>}]]></sourcecode> </section><section title="Syslog<section> <name>Syslog TerminalOutput">Output</name> <t>Terminal output with requirements more complex than the console subtree currentlyprovides,provides are expected to be supported via vendor extensions rather than handled via the file subtree.</t> </section><section title="Syslog<section> <name>Syslog File NamingConvention">Convention</name> <t>The syslog/file/log-file/file-rotation container contains configuration parameters for syslog file rotation. This section describes how these fields might be used by an implementer to name syslog files in a rotation process. This information is offered as an informative guide only.</t> <t>When an active syslog file with a name specified bylog-file/name,log-file/name reaches log-file/max-file-size and/or syslog events arrive after the period specified by log-file/rollover, the logging system can close the file,cancompress it, andcanname the archive file <log-file/name>.0.gz.name>.0.gz. The logging system can then open a new active syslog file<log-file/name>.</t><log-file/name>.</t> <t>When the new syslog file reaches either of the size limits referenced above,<log-file/name>.0.gz<log-file/name>.0.gz can be renamed<log-file/name>.1.gz<log-file/name>.1.gz and the new syslog file can be closed,compressedcompressed, and renamed <log-file/name>.0.gz.name>.0.gz. Each time that a new syslog file is closed, each of the prior syslog archive files named<log-file/name>.<n>.gz<log-file/name>.<n>.gz can be renamed to<log-file/name>.<n<log-file/name>.<n +1>.gz.</t> <t>Removal1>.gz.</t> <!--[rfced] FYI, we have updated this list as follows. Please review whether this conveys the intended meaning. Original: Removal of archive log files could occur when either orboth:</t> <t>-both: - log-file/number-of-files specified - the logging system can create up to log-file/number-of-files syslog archive files after which, the contents of the oldest archived file could beoverwritten.</t> <t>-overwritten. - log-file/retention specified - the logging system can remove those syslog archive files whose file expiration time (file creation time plus the specified log-file/retention time) is prior to the currenttime.</t>time. Current: Removal of archive log files could occur when either or both: * log-file/number-of-files is specified. The logging system can create up to log-file/number-of-files syslog archive files, after which the contents of the oldest archived file could be overwritten. * log-file/retention is specified. The logging system can remove those syslog archive files whose file expiration time (file creation time plus the specified log-file/retention time) is prior to the current time. --> <t>Removal of archive log files could occur when either or both:</t> <ul> <li>log-file/number-of-files is specified. The logging system can create up to log-file/number-of-files syslog archive files, after which the contents of the oldest archived file could be overwritten.</li> <li>log-file/retention is specified. The logging system can remove those syslog archive files whose file expiration time (file creation time plus the specified log-file/retention time) is prior to the current time.</li> </ul> </section> </section> <section numbered="false" anchor="Acknowledgements"> <name>Acknowledgements</name> <t>The authors wish to thank the following who commented on this proposal:</t> <t><contact fullname="Andy Bierman"/>, <contact fullname="Martin Bjorklund"/>, <contact fullname="Alex Campbell"/>, <contact fullname="Alex Clemm"/>, <contact fullname="Francis Dupont"/>, <contact fullname="Jim Gibson"/>, <contact fullname="Jeffrey Haas"/>, <contact fullname="Bob Harold"/>, <contact fullname="John Heasley"/>, <contact fullname="Giles Heron"/>, <contact fullname="Lisa Huang"/>, <contact fullname="Mahesh Jethanandani"/>, <contact fullname="Warren Kumari"/>, <contact fullname="Jeffrey K Lange"/>, <contact fullname="Jan Lindblad"/>, <contact fullname="Chris Lonvick"/>, <contact fullname="Alexey Melnikov"/>, <contact fullname="Kathleen Moriarty"/>, <contact fullname="Tom Petch"/>, <contact fullname="Adam Roach"/>, <contact fullname="Juergen Schoenwaelder"/>, <contact fullname="Phil Shafer"/>, <contact fullname="Yaron Sheffer"/>, <contact fullname="Jason Sterne"/>, <contact fullname="Peter Van Horne"/>, <contact fullname="Kent Watsen"/>, <contact fullname="Bert Wijnen"/>, <contact fullname="Dale R Worley"/>, and <contact fullname="Aleksandr Zhdankin"/>.</t> </section> <!-- Possibly a 'Contributors' section ... --> <!-- Change Log v07 2016-03-20 CW Converted the document to XML format and incorporated changes from Martin Bjorklund and Tom Petch. v08 2016-05-07 CW Incorporated changes from Benoit Claise, Tom Petch, and Mahesh Jethanandani. v09 2016-07-08 CW Incorporated changes from Jason Sterne, Tom Petch, and Juergen Schoenwaelder. v10 2016-10-30 CW Incorporated changes from Juergen Schoenwaelder. v11 2016-11-13 CW Incorporated changes from Phil Shafer. v12 2017-02-14 CW Incorporated changes from Andy Bierman and Alex Campbell. v13 2017-03-13 CW Incorporated changes from various contributors. v14 2017-03-27 CW Incorporated changes from various contributors. v15 2017-06-07 CW Incorporated changes from various contributors. v16 2017-08-11 CW Incorporated changes from various contributors. v17 2017-09-08 CW Incorporated changes from various contributors. v18 2017-12-08 CW Incorporated changes from various contributors. v19 2018-01-12 CW Incorporated changes from various contributors. v20 2018-02-09 CW Incorporated changes from various contributors. v21 2018-02-14 CW Incorporated changes from various contributors. v22 2018-02-21 CW Incorporated changes from Yaron Sheffer and Ron Bonica. v23 2018-03-01 CW Incorporated changes from Kent. --> <!-- [rfced] We noticed that the following term is used inconsistently. If there are no objections, we will use the form on the right. leafs vs. leaves --> <!-- [rfced] Please review the "Inclusive Language" portion of the online Style Guide <https://www.rfc-editor.org/styleguide/part2/#inclusive_language> and let us know if any changes are needed. Updates of this nature typically result in more precise language, which is helpful for readers. Note that our script did not flag any words in particular, but this should still be reviewed as a best practice. --> </back> </rfc>