Application Log Coding via Conversion Appenders for Secure Output

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing Java application logging frameworks require explicit preprocessing for sensitive information, leading to changes in programming habits and potential failures due to negligence, and cannot autonomously process logs within third-party class libraries.

Innovation Solution

Introduce a conversion appender between the native logger and native appender, utilizing log sub-converters like Regex, Json, and Base64 converters, which are configured via an extension mechanism, allowing secure log coding without application retrofitting.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If explicit preprocessing is performed before calling the logging framework to code sensitive information, then coding output of sensitive information is achieved, but the application's API changes requiring retrofitting and developers' programming habits are significantly changed

Engineering Contradiction:
Improvecoding output of sensitive informationVSAvoidprogramming habits
Core Design Contradiction:
ReliabilityVSEase of operation

Solution Approach 1:

The patent introduces a conversion appender as an intermediary component between the native logger and the output destination. This conversion appender automatically performs the coding preprocessing of sensitive information without requiring changes to the application's logging API or developers' programming habits, thus resolving the contradiction between achieving reliable coding output and maintaining ease of operation

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The conversion appender is configured in advance with coding rules and sensitivity level thresholds. When logs are generated, the preprocessing and coding of sensitive information is automatically performed based on these pre-configured rules, eliminating the need for explicit preprocessing by developers and maintaining their original programming habits

Inventive Principle:
Principle #10Preliminary action

2Reliability

If explicit preprocessing is performed before calling the logging framework to code sensitive information, then coding output of sensitive information is achieved, but additional coding preprocessing steps are required each time before calling the logging framework

Engineering Contradiction:
Improvecoding output of sensitive informationVSAvoidcoding preprocessing steps
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The conversion appender serves as an automatic intermediary that intercepts log messages between the native logger and the output destination. It automatically performs sensitivity detection and coding preprocessing without requiring additional explicit preprocessing steps in the application code, thus reducing system complexity while ensuring reliable coding output

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The conversion appender autonomously performs the coding preprocessing task by detecting sensitive information in log messages and applying appropriate coding rules automatically. This self-service mechanism eliminates the need for developers to manually perform preprocessing steps, thereby reducing the complexity of the logging system

Inventive Principle:
Principle #25Self-service

3Ease of operation

If preprocessing is omitted due to negligence before calling certain log printing, then the desired coding effects are not achieved, but the application code remains unchanged

Engineering Contradiction:
Improveprogramming habitsVSAvoidcoding effects
Core Design Contradiction:
Ease of operationVSReliability

Solution Approach 1:

The conversion appender acts as a safety intermediary that automatically performs coding preprocessing even when developers omit explicit preprocessing steps. By intercepting log messages and applying coding rules based on sensitivity levels, it ensures reliable coding effects are achieved regardless of whether developers follow the preprocessing requirement, thus maintaining both ease of operation and reliability

Inventive Principle:
Principle #24Intermediary (Mediator)

4Adaptability or versatility

If a conversion appender is introduced between the native logger and native appender to enable automatic log coding, then diversified log coding outputs are achieved without retrofitting application code, but the logging framework structure becomes more complex

Engineering Contradiction:
Improvelog coding outputsVSAvoidlogging framework structure
Core Design Contradiction:
Adaptability or versatilityVSDevice complexity

Solution Approach 1:

The conversion appender is designed as a universal component that can handle multiple types of sensitive information (different sensitivity levels) and apply various coding rules. It provides diversified log coding outputs for different scenarios while maintaining a unified interface, thus achieving adaptability without proportionally increasing structural complexity

Inventive Principle:
Principle #6Universality (Multi-functionality)

Solution Approach 2:

The conversion appender internally segments the logging process into distinct stages: sensitivity detection, sensitivity level judgment, and coding rule application. This segmentation allows the system to handle diverse coding requirements through a modular structure, achieving versatility while keeping the overall framework complexity manageable through organized functional divisions

Inventive Principle:
Principle #1Segmentation

Data Source

PatentUS12517863B2Application log coding method and device and computer readable storage medium
Publication Date: 2026.01.06 CHINA UNIONPAY
  • US12517863B2 patent drawing
  • US12517863B2 patent drawing

AI summary

The present disclosure provides an application log coding output method, a device, a system, and a computer readable storage medium. The method comprises: loading a conversion appender using an extension mechanism of a native logger, loading a log converter and a native appender for outputting a log message using the conversion appender, the log converter comprising one or more log sub-converters, and loading the log sub-converters specified by an initialization parameter using the log converter; receiving the log message sent by the native logger using the conversion appender, scheduling the log sub-converters specified by the initialization parameter to execute log coding, and sending the processed log to the native appender for secure output. By using the method, diversified log coding output can be achieved without retrofitting an application, and the method is more friendly to developers.