Internet Printing Protocol Working Group Tom Hastings INTERNET DRAFT Xerox Expires 10 April 2000 Ira McDonald High North 10 October 1999 Internet Printing Protocol/1.1: Notifications over SNMP Copyright (C) The Internet Society (1999). All Rights Reserved. Status of this Memo This document is an Internet-Draft and is in full conformance with all provisions of Section 10 of RFC2026. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF), its areas, and its working groups. Note that other groups may also distribute working documents as Internet-Drafts. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." To view the list of Internet-Draft Shadow Directories, see http://www.ietf.org/shadow.html. Abstract This document is a submission to the Internet Printing Protocol Working Group of the Internet Engineering Task Force (IETF). Comments should be submitted to the ipp@pwg.org mailing list. This document proposes a mapping of IPP notifications over SNMP, using new Printer Event and Job Event traps (to be added to the PWG Job Monitoring MIB [PWG-JOB]). This mapping may be used to deliver printer notifications for any printer (not just IPP-capable ones) and also job notifications for any job (not just ones submitted via IPP). This document proposes: (2) SNMP traps; (1) SNMP textual convention; and (4) SNMP leaf objects (for use in trap bindings). Hastings, McDonald Expires 10 April 2000 [Page 1] Internet Draft IPP Notifications over SNMP 10 October 1999 Table of Contents 1. Introduction ............................................... 3 1.1. Terminology for Conformance ............................ 3 2. SNMP Network Management Framework .......................... 3 3. Managed Object Mapping ..................................... 3 3.1. SNMP Mapping for IPP Printer Events .................... 3 3.2. SNMP Mapping for IPP Job Events ........................ 4 3.3. Rules for Encoding Notifications ....................... 4 3.4. Registration for IPP Notifications ..................... 5 3.4.1. Registration via IPP ............................... 5 3.4.2. Registration via SNMP .............................. 5 3.5. Relationship to other MIBs ............................. 6 3.5.1. IETF Host Resources MIB (RFC 1514) ................. 6 3.5.2. IETF Printer MIB (RFC 1759) ........................ 6 3.5.3. Printer MIB v2 (work-in-progress) .................. 6 4. Managed Object Definitions ................................. 8 4.1. Printer Event Trap ..................................... 8 4.1.1. jmPrinterEventV2Event (notification) ............... 8 4.2. Job Event Trap ......................................... 9 4.2.1. jmJobEventV2Event (notification) ................... 9 4.3. Trigger Events ......................................... 10 4.3.1. JmTriggerEventTC (textual convention) .............. 10 4.4. Event Objects .......................................... 11 4.4.1. jmEventTriggerEvent (object) ....................... 11 4.4.2. jmEventSubscriptionID (object) ..................... 11 4.4.3. jmEventSubscriberUserName (object) ................. 12 4.4.4. jmEventSubscriberUserData (object) ................. 12 5. IANA Considerations ........................................ 13 6. Internationalization Considerations ........................ 13 7. Security Considerations .................................... 13 8. References ................................................. 14 9. Intellectual Property Notice ............................... 14 10. Authors' Addresses ........................................ 14 11. Full Copyright Statement .................................. 15 Hastings, McDonald Expires 10 April 2000 [Page 2] Internet Draft IPP Notifications over SNMP 10 October 1999 1. Introduction The IPP protocol [IPP-PRO] supports passive monitoring of IPP Printer and Job objects, via client polling of IPP object attributes using the 'Get-Printer-Attributes' and 'Get-Job-Attributes' operations. This IPP Notifications over SNMP mapping supports dynamic monitoring of IPP Printer and Job objects, via server generation of SNMP traps. 1.1. Terminology for Conformance The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted per [RFC-2119]. 2. SNMP Network Management Framework See: Section 1 'Introduction' and section 2 'Management Information' of IETF Coexistence between SNMPv1 and SNMPv2 [RFC-1908]. See: Section 1.1 'SNMPv1', section 1.2 'SNMPv2', and section 1.3 'SNMPv3' of IETF Coexistence between SNMP Versions [V3-COEX]. 3. Managed Object Mapping 3.1. SNMP Mapping for IPP Printer Events IPP Printer event attribute Printer/Job MIB object mapping --------------------------- ------------------------------ version-number [no mapping - not useful] status-code [implicit in generated trap] request-id [request-id in SNMP trap header] attributes-charset [no mapping - strings are UTF-8] attributes-natural-language [no mapping - no text bindings] printer-uri [prtChannelInformation in PMv2] printer-name [prtGeneralPrinterName in PMv2] job-id jmJobIndex in OID instance suffix job-name jobName trigger-event jmEventTriggerEvent trigger-time [time-stamp in SNMP trap header] trigger-date-time hrSystemDate in Host Res MIB subscription-id jmEventSubscriptionID subscriber-user-name jmEventSubscriberUserName subscriber-user-data jmEventSubscriberUserData Hastings, McDonald Expires 10 April 2000 [Page 3] Internet Draft IPP Notifications over SNMP 10 October 1999 printer-state hrDeviceStatus in Host Res MIB hrPrinterStatus in Host Res MIB printer-state-reasons hrPrinterDetectedErrorState in Host Res MIB printer-is-accepting-jobs [no mapping] 3.2. SNMP Mapping for IPP Job Events IPP Job event attribute Printer/Job MIB object mapping ----------------------- ------------------------------ version-number [no mapping - not useful] status-code [implicit in generated trap] request-id [request-id in SNMP trap header] attributes-charset [no mapping - strings are UTF-8] attributes-natural-language [no mapping - no text bindings] printer-uri [prtChannelInformation in PMv2] printer-name [prtGeneralPrinterName in PMv2] job-id jmJobIndex in OID instance suffix job-name jobName trigger-event jmEventTriggerEvent trigger-time [time-stamp in SNMP trap header] trigger-date-time hrSystemDate in Host Res MIB subscription-id jmEventSubscriptionID subscriber-user-name jmEventSubscriberUserName subscriber-user-data jmEventSubscriberUserData job-state jmJobState job-state-reasons jmJobStateReasons1 jmJobStateReasons2 jmJobStateReasons3 jmJobStateReasons4 [job-completed|state-changed|purged - extra bindings] job-k-octets-processed jmJobKOctetsProcessed job-impressions-completed jmJobImpressionsCompleted job-media-sheets-completed sheetsCompleted [job-progress - extra bindings] job-collation-type jobCollationType sheet-completed-copy-number sheetCompletedCopyNumber sheet-completed-document-number sheetCompletedDocumentNumber impressions-interpreted impressionsInterpreted impressions-completed-current-copy impressionsCompletedCurrentCopy 3.3. Rules for Encoding Notifications Over some transports and/or media, the variable-bindings of these SNMP traps MAY not fit the MTU (maximum transmission unit) size. Conforming IPP Notification generators SHALL perform this procedure to ensure that all variable-bindings of these SNMP traps are always Hastings, McDonald Expires 10 April 2000 [Page 4] Internet Draft IPP Notifications over SNMP 10 October 1999 included in the generated SNMP trap packet: 1) Truncate all strings specified for variable-bindings to the reduced maximum sizes that are specified in their corresponding OBJECT clauses in their MODULE-COMPLIANCE. 1a) If all variable-bindings now fit within the MTU, then exit this procedure and generate the SNMP trap. 2) Truncate the next one of the following string objects to the empty string (zero length in the ASN.1 BER encoding), in the order listed: - 'prtChannelInformation' (from Printer MIB v2 [PRT-MIB2]) - 'prtGeneralPrinterName' (from Printer MIB v2 [PRT-MIB2]) - 'jmEventSubscriberUserName' - 'jmEventSubscriberUserData' - 'jmAttributeValue...jobName.1' 2a) If all variable-bindings now fit within the MTU, then exit this procedure and generate the SNMP trap. 2b) If all variable-bindings do NOT fit within the MTU, then repeat step (2) for next string object. 3) If all variable-bindings do NOT fit within the MTU, then -> logic error (variable-bindings MUST now fit). 3.4. Registration for IPP Notifications IPP Clients may register for IPP Notifications delivered via SNMP by either of the following methods: 3.4.1. Registration via IPP IPP Create-Subscription and Job creation (Create-Job, Print-Job, Print-URI) operations MAY be used to create per-Printer or per-Job IPP Subscription objects and MAY specify 'notify-recipient' = 'ipp-snmp://hostname[.port]' 3.4.2. Registration via SNMP SNMP Set-Request operations MAY be used to create appropriate rows in the SNMP Notification MIB defined in [RFC-2573] and MAY specify: 1) 'snmpNotifyTag' - tag of this notification - see 'snmpTargetAddrTagList' below - example "jmPrinterEventV2Event" or "jmJobEventV2Event" 2) 'snmpNotifyType' - notification sent using either SNMP Trap (unacknowledged) or SNMP Inform-Request (acknowledged) 3) 'snmpNotifyStorageType' - row persistence of this registration Hastings, McDonald Expires 10 April 2000 [Page 5] Internet Draft IPP Notifications over SNMP 10 October 1999 SNMP Set-Request operations MAY be used to create appropriate rows in the SNMP Target MIB defined in [RFC-2573] and MAY specify: 1) 'snmpTargetAddrTDomain' and 'snmpTargetAddrTAddress' - target transport protocol and address (equivalent to URI) 2) 'snmpTargetAddressTimeout' and 'snmpTargetAddrRetryCount' - retry timeout and limit (for acknowledged notifications delivered using SNMP Inform-Request rather than SNMP Trap) 3) 'snmpTargetAddrTagList' - tags of notifications to be sent to this target (client) - example value "jmPrinterEventV2Event jmJobEventV2Event" 4) 'snmpTargetAddrParamsEntry' - notification security and SNMP protocol version 5) 'snmpTargetAddrStorageType' - row persistence of this registration 3.5. Relationship to other MIBs 3.5.1. IETF Host Resources MIB (RFC 1514) The 'jmPrinterEventV2Event' trap defined in this document includes a 'hrDeviceStatus' object for a device of type 'hrDevicePrinter'. The 'jmPrinterEventV2Event' trap defined in this document includes four objects from the IETF HR MIB [RFC-1514] in the variable-bindings: - 'hrDeviceStatus' --> IPP 'printer-state' - 'hrPrinterStatus' --> IPP 'printer-state' - 'hrPrinterDetectedErrorState' --> IPP 'printer-state-reasons' - 'hrSystemDate' --> IPP 'printer-current-time' 3.5.2. IETF Printer MIB (RFC 1759) The 'jmPrinterEventV2Event' trap defined in this document includes a 'hrDeviceStatus' object for a device of type 'hrDevicePrinter'. The appropriate 'hrDeviceIndex' to use in the companion IETF Printer MIB [RFC-1759] is indicated by the instance suffix of the variable's OID. 3.5.3. Printer MIB v2 (work-in-progress) The 'jmPrinterEventV2Event' trap defined in this document includes two objects from the (work-in-progress) Printer MIB v2 [PRT-MIB2] in the variable-bindings: Hastings, McDonald Expires 10 April 2000 [Page 6] Internet Draft IPP Notifications over SNMP 10 October 1999 - 'prtGeneralPrinterName' --> IPP 'printer-name' - 'prtChannelInformation' --> IPP 'printer-uri' Hastings, McDonald Expires 10 April 2000 [Page 7] Internet Draft IPP Notifications over SNMP 10 October 1999 4. Managed Object Definitions 4.1. Printer Event Trap -- Printer Event Group (Cond Mandatory) -- -- Implementation of this group is conditionally mandatory; -- mandatory for systems which send this Printer event via SNMP. jmPrinterEventV1Enterprise OBJECT-IDENTITY STATUS current DESCRIPTION "The value of the enterprise-specific OID in an SNMPv1 trap for a 'basic-printer-event' sent by this managed system." ::= { jobmonMIBNotifications 1 } jmPrinterEventV2EventPrefix OBJECT IDENTIFIER ::= { jmPrinterEventV1Enterprise 0 } jmPrinterEventV2Event NOTIFICATION-TYPE OBJECTS { jmEventTriggerEvent, jmEventSubscriptionID, jmEventSubscriberUserName, jmEventSubscriberUserData, hrDeviceStatus, hrPrinterStatus, hrPrinterDetectedErrorState } STATUS current DESCRIPTION "This SMIv2 trap corresponds to an IPP 'basic-printer-event'. This trap is sent when requested by a prior subscription for the included printer-level 'jmEventTriggerEvent'. Additional variable-bindings SHALL be appended to this trap for all printer-level events: - Systems that support 'jobName' SHALL add 'jmAttributeValue...jobName.1' (if job-level subscription) - Systems that support 'hrSystemDate' defined in the IETF Host Resources MIB (RFC 1514) SHALL add 'hrSystemDate' (corresponds to IPP 'printer-current-time') Additional variable-bindings SHOULD be appended to this trap for all printer-level events: - Systems that support 'prtChannelInformation' defined in Hastings, McDonald Expires 10 April 2000 [Page 8] Internet Draft IPP Notifications over SNMP 10 October 1999 the (work-in-progress) Printer MIB v2 [PRT-MIB2] SHOULD add 'prtChannelInformation' (corresponds to IPP 'printer-uri') - Systems that support 'prtGeneralPrinterName' defined in the (work-in-progress) Printer MIB v2 [PRT-MIB2] SHOULD add 'prtGeneralPrinterName' (corresponds to IPP 'printer-name') Systems MAY add other variable-bindings from any MIB." ::= { jmPrinterEventV2EventPrefix 1 } 4.2. Job Event Trap -- Job Event Group (Cond Mandatory) -- -- Implementation of this group is conditionally mandatory; -- mandatory for systems which send this Job event via SNMP. jmJobEventV1Enterprise OBJECT-IDENTITY STATUS current DESCRIPTION "The value of the enterprise-specific OID in an SNMPv1 trap for a 'basic-job-event' sent by this managed system." ::= { jobmonMIBNotifications 2 } jmJobEventV2EventPrefix OBJECT IDENTIFIER ::= { jmJobEventV1Enterprise 0 } jmJobEventV2Event NOTIFICATION-TYPE OBJECTS { jmEventTriggerEvent, jmEventSubscriptionID, jmEventSubscriberUserName, jmEventSubscriberUserData, jmJobState, jmJobStateReasons1 } STATUS current DESCRIPTION "This SMIv2 trap corresponds to an IPP 'basic-job-event'. This trap is sent when requested by a prior subscription for the included job-level 'jmEventTriggerEvent'. Additional variable-bindings SHALL be appended to this trap for all job-level events: - Systems that support 'jobName' SHALL add 'jmAttributeValue...jobName.1' - Systems that support 'jobStateReasonsN' SHALL add 'jmAttributeValue...jobStateReasonsN.1' - Systems that support 'hrSystemDate' defined in the IETF Host Resources MIB (RFC 1514) SHALL add Hastings, McDonald Expires 10 April 2000 [Page 9] Internet Draft IPP Notifications over SNMP 10 October 1999 'hrSystemDate' (corresponds to IPP 'printer-current-time') Additional variable-bindings SHOULD be appended to this trap for all job-level events: - Systems that support 'prtChannelInformation' defined in the (work-in-progress) Printer MIB v2 [PRT-MIB2] SHOULD add 'prtChannelInformation' (corresponds to IPP 'printer-uri') - Systems that support 'prtGeneralPrinterName' defined in the (work-in-progress) Printer MIB v2 [PRT-MIB2] SHOULD add 'prtGeneralPrinterName' (corresponds to IPP 'printer-name') Additional variable-bindings SHALL be appended to this trap for 'jobCompleted', 'jobStateChanged', or 'jobPurged': - Systems SHALL add 'jmJobKOctetsProcessed' 'jmJobImpressionsCompleted' - Systems that support 'sheetsCompleted' SHALL add 'jmAttributeValue...sheetsCompleted.1' Additional variable-bindings SHALL be appended to this trap for 'jobProgress': - Systems that support the respective attributes SHALL add 'jmAttributeValue...jobCollationType.1' 'jmAttributeValue...sheetCompletedCopyNumber.1' 'jmAttributeValue...sheetCompletedDocumentNumber.1' 'jmAttributeValue...impressionsInterpreted.1' 'jmAttributeValue...impressionsCompletedCurrentCopy.1' Systems MAY add other variable-bindings from any MIB." ::= { jmJobEventV2EventPrefix 1 } 4.3. Trigger Events JmTriggerEventTC ::= TEXTUAL-CONVENTION STATUS current DESCRIPTION "The trigger event type associated with this event. See: Section 5.2 'notify-events' and Section 7 'Notification Content' in [IPP-NOT]." SYNTAX INTEGER { other(1), unknown(2), none(3), -- SHOULD not be used printerRestarted(11), -- 'printer-restarted' printerShutdown(12), -- 'printer-shutdown' printerStateChanged(13), -- 'printer-state-changed' printerMediaChanged(14), -- 'printer-media-changed' printerConfigChanged(15), -- 'printer-config-changed' printerQueueChanged(16), -- 'printer-queue-changed' Hastings, McDonald Expires 10 April 2000 [Page 10] Internet Draft IPP Notifications over SNMP 10 October 1999 printerNoLongerFull(17), -- 'printer-no-longer-full' printerAlmostIdle(18), -- 'printer-almost-idle' jobCreated(21), -- 'job-created' jobCompleted(22), -- 'job-completed' jobStateChanged(23), -- 'job-state-changed' jobConfigChanged(24), -- 'job-config-changed' jobPurged(25), -- 'job-purged' jobProgress(26) -- 'job-progress' } 4.4. Event Objects -- Event Group (Cond Mandatory) -- -- Implementation of this group is conditionally mandatory; -- mandatory for systems which support Job events via SNMP. jmEvent OBJECT IDENTIFIER ::= { jobmonMIBObjects 5 } jmEventTriggerEvent OBJECT-TYPE SYNTAX JmTriggerEventTC MAX-ACCESS read-only STATUS current DESCRIPTION "The trigger event type associated with this event. Conformance: This trigger event type SHALL be valid and consistent with [IPP-NOT]. See: Section 5.2 'notify-events' and Section 7 'Notification Content' in [IPP-NOT]." -- DEFVAL intentionally omitted - trigger event SHALL be valid ::= { jmEvent 1 } jmEventSubscriptionID OBJECT-TYPE SYNTAX Integer32 (0..2147483647) MAX-ACCESS read-only STATUS current DESCRIPTION "The subscription identifier associated with this event or zero (if none). Conformance: This subscription identifier SHALL be valid and non-zero, if available on this managed system. See: Section 5.8 'subscription-id' and Section 7 'Notification Content' in [IPP-NOT]." DEFVAL { 0 } -- no subscription ID ::= { jmEvent 2 } Hastings, McDonald Expires 10 April 2000 [Page 11] Internet Draft IPP Notifications over SNMP 10 October 1999 jmEventSubscriberUserName OBJECT-TYPE SYNTAX JmUTF8StringTC (SIZE (0..63)) -- 1023 in [IPP-MOD] MAX-ACCESS read-only STATUS current DESCRIPTION "The subscriber user name associated with this event or the empty string (if none). Note: The natural language appropriate for text-to-speech of subscriber user name is orthogonal to the localized text context in IPP 'attributes-natural-language'. The subscriber user name MAY include an in-line 'language tag' using Plane 14 'language tag' characters proposed for ISO 10646/Unicode. Conformance: This subscriber user name SHALL be valid and non-empty, if available on this managed system. See: Section 4.3.6 'job-originating-user-name' and Section 4.4.2 'uri-authentication-supported' (usage of 'requesting-user-name') in [IPP-MOD]; Section 5.11 'subscriber-user-name' and Section 7 'Notification Content' in [IPP-NOT]." DEFVAL { ''H } -- no subscriber user name ::= { jmEvent 3 } jmEventSubscriberUserData OBJECT-TYPE SYNTAX OCTET STRING (SIZE (0..63)) -- 63 in [IPP-NOT] MAX-ACCESS read-only STATUS current DESCRIPTION "The subscriber user data associated with this event or the empty string (if none). Conformance: This subscriber user data SHALL be valid and conserved, if available on this managed system. See: Section 5.4 'subscriber-user-data' and Section 7 'Notification Content' in [IPP-NOT]." DEFVAL { ''H } -- no subscriber user data ::= { jmEvent 4 } Hastings, McDonald Expires 10 April 2000 [Page 12] Internet Draft IPP Notifications over SNMP 10 October 1999 5. IANA Considerations None - the only enumerated textual convention defined in this documen is proposed for addition to the PWG Job Monitoring MIB which is not a IETF standards track document. The PWG does maintain a registration process for updates to the PWG Job Monitoring MIB. 6. Internationalization Considerations The 'jmEventSubscriberUserName' text string defined in this document of type 'JmUTF8StringTC' (UTF-8 stream-encoded ISO 10646/Unicode text defined in the PWG Job Monitoring MIB [PWG-JOB]. The natural languag of this object is inherently ambiguous (as it usually contains some transform of a personal name). 7. Security Considerations This IPP Notifications over SNMP mapping defines only 'read-only' objects. It is suitable for use with any version of SNMP, as no upda security is required (because no configuration updates are supported) No sensitive information is available via IPP Notifications over SNMP Hastings, McDonald Expires 10 April 2000 [Page 13] Internet Draft IPP Notifications over SNMP 10 October 1999 8. References To be supplied. 9. Intellectual Property Notice The IETF takes no position regarding the validity or scope of any intellectual property or other rights that might be claimed to pertain to the implementation or use of the technology described in this document or the extent to which any license under such rights might or might not be available; neither does it represent that it has made any effort to identify any such rights. Information on the IETF's procedures with respect to rights in standards-track and standards-related documentation can be found in BCP-11. Copies of claims of rights made available for publication and any assurances of licenses to be made available, or the result of an attempt made to obtain a general license or permission for the use of such proprietary rights by implementers or users of this specification can be obtained from the IETF Secretariat. The IETF invites any interested party to bring to its attention any copyrights, patents or patent applications, or other proprietary rights which may cover technology that may be required to practice this standard. Please address the information to the IETF Executive Director. 10. Authors' Addresses Tom Hastings Xerox Corporation 701 S Aviation Blvd, MS 834-03E El Segundo, CA 90245 Phone: +1 310-333-6413 Email: hastings@cp10.es.xerox.com Ira McDonald High North Inc 221 Ridge Ave Grand Marais, MI 49839 Phone: +1 906-494-2434 or +1 906-494-2697 Email: imcdonal@sdsp.mc.xerox.com Hastings, McDonald Expires 10 April 2000 [Page 14] Internet Draft IPP Notifications over SNMP 10 October 1999 11. Full Copyright Statement Copyright (C) The Internet Society (1999). All Rights Reserved. This document and translations of it may be copied and furnished to others, and derivative works that comment on or otherwise explain it or assist in its implementation may be prepared, copied, published and distributed, in whole or in part, without restriction of any kind, provided that the above copyright notice and this paragraph are included on all such copies and derivative works. However, this document itself may not be modified in any way, such as by removing the copyright notice or references to the Internet Society or other Internet organizations, except as needed for the purpose of developing Internet standards in which case the procedures for copyrights defined in the Internet Standards process must be followed, or as required to translate it into languages other than English. The limited permissions granted above are perpetual and will not be revoked by the Internet Society or its successors or assigns. This document and the information contained herein is provided on an "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Hastings, McDonald Expires 10 April 2000 [Page 15]