Skip to main content

HS.IHE.ATNA.SecureApplication.Syslog.Common

class HS.IHE.ATNA.SecureApplication.Syslog.Common extends %Library.RegisteredObject

Create a Syslog message based on RFC5424.

The syslog header has the following ABNF [RFC5234] definition:
  • SYSLOG-MSG = HEADER SP STRUCTURED-DATA [SP MSG]
  • HEADER = PRI VERSION SP TIMESTAMP SP HOSTNAME SP APP-NAME SP PROCID SP MSGID

    The syslog field values have the following ABNF [RFC5234] definition:
  • PRI = "<" PRIVAL ">"
  • PRIVAL = 1*3DIGIT ; range 0 .. 191
  • VERSION = NONZERO-DIGIT 0*2DIGIT
  • HOSTNAME = NILVALUE / 1*255PRINTUSASCII
  • APP-NAME = NILVALUE / 1*48PRINTUSASCII
  • PROCID = NILVALUE / 1*128PRINTUSASCII
  • MSGID = NILVALUE / 1*32PRINTUSASCII
  • TIMESTAMP = NILVALUE / FULL-DATE "T" FULL-TIME
  • FULL-DATE = DATE-FULLYEAR "-" DATE-MONTH "-" DATE-MDAY
  • DATE-FULLYEAR = 4DIGIT
  • DATE-MONTH = 2DIGIT ; 01-12
  • DATE-MDAY = 2DIGIT ; 01-28, 01-29, 01-30, 01-31 based on month/year
  • FULL-TIME = PARTIAL-TIME TIME-OFFSET
  • PARTIAL-TIME = TIME-HOUR ":" TIME-MINUTE ":" TIME-SECOND [TIME-SECFRAC]
  • TIME-HOUR = 2DIGIT ; 00-23
  • TIME-MINUTE = 2DIGIT ; 00-59
  • TIME-SECOND = 2DIGIT ; 00-59
  • TIME-SECFRAC = "." 1*6DIGIT
  • TIME-OFFSET = "Z" / TIME-NUMOFFSET
  • TIME-NUMOFFSET = ("+" / "-") TIME-HOUR ":" TIME-MINUTE
  • STRUCTURED-DATA = NILVALUE / 1*SD-ELEMENT
  • SD-ELEMENT = "[" SD-ID *(SP SD-PARAM) "]"
  • SD-PARAM = PARAM-NAME "=" %d34 PARAM-VALUE %d34
  • SD-ID = SD-NAME
  • PARAM-NAME = SD-NAME
  • PARAM-VALUE = UTF-8-STRING ; characters '"', '\' and ']' MUST be escaped.
  • SD-NAME = 1*32PRINTUSASCII except '=', SP, ']', %d34 (")
  • MSG = MSG-ANY / MSG-UTF8
  • MSG-ANY = *OCTET ; not starting with BOM
  • MSG-UTF8 = BOM UTF-8-STRING
  • BOM = %xEF.BB.BF
  • UTF-8-STRING = *OCTET ; UTF-8 string as specified in RFC 3629
  • OCTET = %d00-255
  • SP = %d32
  • PRINTUSASCII = %d33-126
  • NONZERO-DIGIT = %d49-57
  • DIGIT = %d48 / NONZERO-DIGIT
  • NILVALUE = "-"

    Property Inventory

    Method Inventory

    Parameters

    parameter SETTINGS = SyslogFacility,SyslogSeverity,ApplicationName,IncludeByteOrderMark,StripWhitespace;

    Properties

    property ApplicationName as %String [ InitialExpression = "InterSystems_HealthShare" ];
    The name of the application to include in the syslog header. Whitespace is not allowed, and will be stripped out of the name entered here before submitting over the wire.
    Property methods: ApplicationNameDisplayToLogical(), ApplicationNameGet(), ApplicationNameIsValid(), ApplicationNameLogicalToDisplay(), ApplicationNameLogicalToOdbc(), ApplicationNameNormalize(), ApplicationNameSet()
    property IncludeByteOrderMark as %Boolean [ InitialExpression = "0" ];
    An optional argument to the syslog header is the Byte Order Mark (BOM). This setting governs whether or not the BOM should be included.
    Property methods: IncludeByteOrderMarkDisplayToLogical(), IncludeByteOrderMarkGet(), IncludeByteOrderMarkIsValid(), IncludeByteOrderMarkLogicalToDisplay(), IncludeByteOrderMarkNormalize(), IncludeByteOrderMarkSet()
    property StripWhitespace as %Boolean [ InitialExpression = "1" ];
    Most ATNA repositories won't handle CR, LF, and TAB characters within the audit event. This setting allows you to filter these characters out.
    Property methods: StripWhitespaceDisplayToLogical(), StripWhitespaceGet(), StripWhitespaceIsValid(), StripWhitespaceLogicalToDisplay(), StripWhitespaceNormalize(), StripWhitespaceSet()
    property SyslogFacility as %String (DISPLAYLIST = ",kernel,user,mail,system,security1,syslogd,printer,news,UUCP,clock1,security2,FTP,NTP,audit,alert,clock2,local0,local1,local2,local3,local4,local5,local6,local7", VALUELIST = ",0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23") [ InitialExpression = "13" ];
    Facilities:
  • 0 kernel messages
  • 1 user-level messages
  • 2 mail system
  • 3 system daemons
  • 4 security/authorization messages (note 1)
  • 5 messages generated internally by syslogd
  • 6 line printer subsystem
  • 7 network news subsystem
  • 8 UUCP subsystem
  • 9 clock daemon (note 2)
  • 10 security/authorization messages (note 1)
  • 11 FTP daemon
  • 12 NTP subsystem
  • 13 log audit (note 1)
  • 14 log alert (note 1)
  • 15 clock daemon (note 2)
  • 16 local use 0 (local0)
  • 17 local use 1 (local1)
  • 18 local use 2 (local2)
  • 19 local use 3 (local3)
  • 20 local use 4 (local4)
  • 21 local use 5 (local5)
  • 22 local use 6 (local6)
  • 23 local use 7 (local7)
    Property methods: SyslogFacilityDisplayToLogical(), SyslogFacilityGet(), SyslogFacilityIsValid(), SyslogFacilityLogicalToDisplay(), SyslogFacilityLogicalToOdbc(), SyslogFacilityNormalize(), SyslogFacilitySet()
  • property SyslogSeverity as %String (DISPLAYLIST = ",Alert,Critical,Debug,Emergency,Error,Informational,Notice,Warning", VALUELIST = ",1,2,7,0,3,6,5,4") [ InitialExpression = "6" ];
    Severities:
  • 0 Emergency: system is unusable
  • 1 Alert: action must be taken immediately
  • 2 Critical: critical conditions
  • 3 Error: error conditions
  • 4 Warning: warning conditions
  • 5 Notice: normal but significant condition
  • 6 Informational: informational messages
  • 7 Debug: debug-level messages
    Property methods: SyslogSeverityDisplayToLogical(), SyslogSeverityGet(), SyslogSeverityIsValid(), SyslogSeverityLogicalToDisplay(), SyslogSeverityLogicalToOdbc(), SyslogSeverityNormalize(), SyslogSeveritySet()
  • Methods

    method GetByteOrderMark() as %Binary
    method GetSyslogHeader() as %String

    Inherited Members

    Inherited Methods

    Subclasses

  • FeedbackOpens in a new tab