Package com.verisign.epp.util
Class EPPRawSendReceiveLogger
- java.lang.Object
-
- com.verisign.epp.util.EPPRawSendReceiveLogger
-
- All Implemented Interfaces:
EPPSendReceiveLogger
public class EPPRawSendReceiveLogger extends java.lang.Object implements EPPSendReceiveLogger
A concreteEPPSendReceiveLogger
that logs the messages in raw form to the Log4J com.verisign.epp.util.EPPXMLStream category. This logging category is used for backward compatibility to logging configurations when theEPPXMLStream
logged the packets directly.
-
-
Constructor Summary
Constructors Constructor Description EPPRawSendReceiveLogger()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
logReceive(byte[] aPacket, EPPMessage aMessage)
Log the raw receiving of a message.void
logSend(byte[] aPacket, EPPMessage aMessage)
Log the raw sending of a message.EPPCodecComponent
maskMessage(EPPCodecComponent aMessage)
Utility method used to optionally mask specific message attributes based on the concreteEPPSendReceiveLogger
.java.lang.String
maskString(java.lang.String aString)
Mask a general string of sensitive information.
-
-
-
Method Detail
-
logSend
public void logSend(byte[] aPacket, EPPMessage aMessage)
Log the raw sending of a message. No filtering or alterations are done to the attributes of the message.- Specified by:
logSend
in interfaceEPPSendReceiveLogger
- Parameters:
aPacket
- Packet to send. This may benull
if the packet has not been encoded yet.aMessage
- The message that is being sent, which could be any concreteEPPMessage
, including aEPPCommand
, anEPPGreeting
, anEPPHello
, or anEPPResponse
. This may benull
if theEPPMessage
is not available.
-
logReceive
public void logReceive(byte[] aPacket, EPPMessage aMessage)
Log the raw receiving of a message. No filtering or alterations are done to the attributes of the message.- Specified by:
logReceive
in interfaceEPPSendReceiveLogger
- Parameters:
aPacket
- Packet received. This may benull
if the packet is not available.aMessage
- The message received, which could be any concreteEPPMessage
, including aEPPCommand
, anEPPGreeting
, anEPPHello
, or anEPPResponse
. This may benull
if theEPPMessage
is not available.
-
maskMessage
public EPPCodecComponent maskMessage(EPPCodecComponent aMessage)
Utility method used to optionally mask specific message attributes based on the concreteEPPSendReceiveLogger
.EPPRawSendReceiveLogger
does not perform any masking, so theaMessage
parameter is directly returned.- Specified by:
maskMessage
in interfaceEPPSendReceiveLogger
- Parameters:
aMessage
- Message to mask.EPPRawSendReceiveLogger
does not perform any masking, so theaMessage
parameter is directly returned.- Returns:
- Matches the
aMessage
parameter.
-
maskString
public java.lang.String maskString(java.lang.String aString)
Mask a general string of sensitive information. Specific string regular expressions are checked and matching strings are masked by this method for inclusion in exceptions and logs.- Specified by:
maskString
in interfaceEPPSendReceiveLogger
- Parameters:
aString
-String
to scan for masking- Returns:
- Masked
String
.
-
-