Interface SafeLogger
- All Superinterfaces:
org.slf4j.Logger
- All Known Implementing Classes:
Log
public interface SafeLogger
extends org.slf4j.Logger
A logger that provides conditional logging for expensive log argument like logSafe(),
string concatenation
-
Field Summary
Fields inherited from interface org.slf4j.Logger
ROOT_LOGGER_NAME -
Method Summary
Modifier and TypeMethodDescriptionvoiddebugSafely(String s, Object... objects) Logs debug message by encoding any special character in the argumentvoiderrorSafely(String s, Object... objects) Logs error message by encoding any special character in the argumentvoidinfoSafely(String s, Object... objects) Logs info message by encoding any special character in the argumentvoidtraceSafely(String s, Object... objects) Logs trace message by encoding any special character in the argumentvoidwarnSafely(String s, Object... objects) Logs warn message by encoding any special character in the argumentMethods inherited from interface org.slf4j.Logger
debug, debug, debug, debug, debug, debug, debug, debug, debug, debug, error, error, error, error, error, error, error, error, error, error, getName, info, info, info, info, info, info, info, info, info, info, isDebugEnabled, isDebugEnabled, isErrorEnabled, isErrorEnabled, isInfoEnabled, isInfoEnabled, isTraceEnabled, isTraceEnabled, isWarnEnabled, isWarnEnabled, trace, trace, trace, trace, trace, trace, trace, trace, trace, trace, warn, warn, warn, warn, warn, warn, warn, warn, warn, warn
-
Method Details
-
traceSafely
Logs trace message by encoding any special character in the argument- Parameters:
s- log messageobjects- vulnerable log arugments
-
debugSafely
Logs debug message by encoding any special character in the argument- Parameters:
s- log messageobjects- vulnerable log arugments
-
infoSafely
Logs info message by encoding any special character in the argument- Parameters:
s- log messageobjects- vulnerable log arugments
-
warnSafely
Logs warn message by encoding any special character in the argument- Parameters:
s- log messageobjects- vulnerable log arugments
-
errorSafely
Logs error message by encoding any special character in the argument- Parameters:
s- log messageobjects- vulnerable log arugments
-