Security News
Introducing the Socket Python SDK
The initial version of the Socket Python SDK is now on PyPI, enabling developers to more easily interact with the Socket REST API in Python projects.
io.github.c-a-services:log4j2-sftp-appender
Advanced tools
Append the log-output from log4j2.xml to sftp server
log4j2.xml
file:
Add the import to the root element:
<Configuration status="warn" packages="io.github.c_a_services.log4j2">
Add the appender:
<Appenders>
<DailyFileSftpAppender
name="sftpAppender"
filePattern="${date:HHmmssSSS}-mule.log"
hostName="ftp.yourdnsservername.com"
pathName="/${sys:stage.name:-nostage}/"
userName="ftpUserName"
publicKeyResource="secret/ftpUserName.pub"
privateKeyResource="secret/ftpUserName"
passPhrase="yourPassPhrase">
<PatternLayout pattern="%d %-5p %c{1} - %m [%t]%n" />
<DefaultRolloverStrategy max="10"/>
</DailyFileSftpAppender>
</Appenders>
<AppenderRef ref="sftpAppender" />
later in the filestage.name
)ssh-keygen -f ftpUserName -t rsa -b 4092 -N yourPassPhrase
)for above example the resourepath looks like:
/your-mule-application/src/main/resources/secret/ftpUserName
/your-mule-application/src/main/resources/secret/ftpUserName.pub
Further details, see log4j2-configuration
Dependencies are marked provided
and so either needs to be available in your server or added manually:
<dependency>
<groupId>io.github.c-a-services</groupId>
<artifactId>log4j2-sftp-appender</artifactId>
<version>2018.11.1</version>
</dependency>
(for newest Version see pom.xml)
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>2.11.1</version>
</dependency>
(for newest Version see log4j2-maven-artifacts)
<dependency>
<groupId>com.hierynomus</groupId>
<artifactId>sshj</artifactId>
<version>0.26.0</version>
</dependency>
(for newest Version see sshj)
For changing this file see Markdown-Cheatsheet
FAQs
SFTP appender for log4j2
We found that io.github.c-a-services:log4j2-sftp-appender demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The initial version of the Socket Python SDK is now on PyPI, enabling developers to more easily interact with the Socket REST API in Python projects.
Security News
Floating dependency ranges in npm can introduce instability and security risks into your project by allowing unverified or incompatible versions to be installed automatically, leading to unpredictable behavior and potential conflicts.
Security News
A new Rust RFC proposes "Trusted Publishing" for Crates.io, introducing short-lived access tokens via OIDC to improve security and reduce risks associated with long-lived API tokens.