Enabling engine traffic logging - PingAccess - 7.0

PingAccess

bundle
pingaccess-70
ft:publication_title
PingAccess
Product_Version_ce
PingAccess 7.0
category
Product
pa-70
pingaccess
ContentType_ce

Enable engine audit logging, including requests and responses.

  1. Edit the <PA_HOME>/conf/log4j2.xml file.
  2. In the Logger section, uncomment the AppenderRef element for the engine audit log HAR file.
           <!-- Audit Log Configuration-->
            ...
            <Logger name="engineaudit" level="INFO" additivity="false">
                <AppenderRef ref="EngineAuditLog-File"/>
                <!--<AppenderRef ref="EngineAuditLog-Database-Failover"/>-->
                <!--<AppenderRef ref="EngineAuditLog-SQLServer-Database-Failover"/>-->
                <!--<AppenderRef ref="EngineAuditLog-PostgreSQL"/>-->
                <!--<AppenderRef ref="EngineAudit2Splunk"/>-->
                <AppenderRef ref="EngineAuditLog-HarFile"/>
            </Logger>
    
  3. In the Appenders section, uncomment the RollingFile element for the engine audit log HAR file.
        <Appenders>
            ...
            <RollingFile name="EngineAuditLog-HarFile"
                                fileName="${sys:pa.home}/log/pingaccess_engine_audit_har.log"
                                filePattern="${sys:pa.home}/log/pingaccess_engine_audit_har.%d{yyyy-MM-dd}.log"
                                ignoreExceptions="false">
                <StatusCodeRegExFilter regex=".*"/>
                <HarLogLayout>
                    <KeyValuePair key="AUDIT.metadata" value="true"/>
                    <KeyValuePair key="AUDIT.http-client" value="true"/>
                    <KeyValuePair key="AUDIT.http-app" value="true"/>
                </HarLogLayout>
                <Policies>
                    <TimeBasedTriggeringPolicy />
                </Policies>
            </RollingFile>
    
  4. Optional: To filter the entries to add to the log file, edit the value in the StatusCodeRegExFilter element.
  5. Optional: To specify what information to log, add or edit the values in the HarLogLayout section of the RollingFile element.

    You can add or edit metadata, client response, and app response values. See Traffic logging reference for more information.

Logging begins when the configuration is reloaded. The configuration is reloaded at regular intervals according to the monitorInterval value.