In a Quarkus application i do some http calls where username and password are in the URL as query parameters (3rd party, I can't change this). The problem is, that the JBoss logger in DEBUG mode prints the call to the logfile and/or console with username and password as plain text.
Is there a way to filter or mask this output before the logger prints these information to the console or log file (or any other destination)?
As I found out, logback is not supported in Quarkus (at the moment).
The main point is, that Quarkus prints in debug-log-mode everything from the http call in plaintext to the log out. I think I need to grab the log output at very low level to filter it.
Related
I'm building a Java application with Quarkus/Camel which generates some logstatements here and there. I want to be able to verify if the correct logstatements are generated so I have a need to intercept the logmessages. The problem is that I have a logtemplate specified in the Quarkus application.properties file, but this template is not used when running tests. As a result, I cannot verify the correctness of the logstatements.
I have tried to copy the logtemplate to the testbranch but it is nog picked up by Quarkus. Does somebody know how I can pursuade my tests to use the proper logtemplate?
I am trying to access the console log from the perl module Selenium::Remote::Driver to no avail.
According to the documentation, this should be very simple, by calling the get_log method with the log type as a parameter, which as I figure should be browser. However, the get_log_types method returns only the server log type as available, while the documentation says "every driver should have client,driver, browser, and server types".
I believe some parameters should be passed to the constructor (in chromeOptions maybe?) that switches on capturing the console log. Unfortunately, all examples I find for this are for other languages, and this perl module is too much different to port those solutions.
Any ideas?
I have deployed my ASP.NET Core application to GKE and I am now seeing output logged in Stackdriver. However for some reason all of the log entries have severity of INFO. It doesn't matter if it's exception log (with severity ERROR) or something else... everything is logged as INFO.
How can I instruct Stackdriver Logger to tag log entries from .NET Core application with appropriate severity types?
Well, first things first, that configuration should be done inside the log generator of your .NET application, like this:
Sometimes the application logs have some (some times none) string, such as stderr or stdout, that Stackdriver reads as the severity, so you could add a "Severity" field to your logs with the proper value and, this way, Stackdriver would read it as you specify, check the values here.
or in the GKE cluster with Fluentd, you can refer to this documentation for that. Also this could work.
In general your logs are missing the severity field or have other strings.
I see on the page Settings Encryption a section about the MSBuild.SonarQube.Runner configuration file.
But the documented portion has a format which doesn't match the example SonarQube.Analysis.xml file.
However, I have tried putting these properties in the SonarQube.Analysis.xml file, in a format corresponding to the current one. Long story made short, the msbuild.sonarqube.runner puts the {aes}encrypted password in the Basic authorization field of the HttpRequest sent to SonarQube.
I guess that the client should unencrypt the password before putting it in the Authentication header. Otherwise, the sonarQube server won't allow the user to query the properties Uri (something like /api/properties?resource=projectKey)
You're right, I've fixed the documentation to reflect the effective format of the SonarQube Scanner for MSBuild.
Regarding the encryption of the sonar.password property, this is currently not supported by the MSBuild Scanner: It does not (yet?) know about the encryption logic, and therefore sees the raw encrypted value only. However, some other properties can be encrypted: the ones that are read during the end step of the SonarQube Scanner for MSBuild, which is under the hood launching the sonar-runner.
I've created the following ticket to keep track of this limitation: https://jira.sonarsource.com/browse/SONARMSBRU-192
I'm using ActiveMQ 5.10 and would like to create a user that has read-only access through the web console.
Red Hat published this article, mentioning that it's not really read only due to a bug in ActiveMQ.
According to the bug report AMQ-4567, the bug is fixed as of ActiveMQ 5.9. However, I'm not seeing it work appropriately.
I have tried a number of different configurations, with the most recent being two separate JAAS implementations, one for Jetty and one for ActiveMQ. The relevant property files are excerpted below.
I can mostly log in to the web console using the "system" user. But the guest user doesn't work at all. The application user (appuser) doesn't need access to the web console at all.
My authN/authZ needs are pretty trivial: one admin user, one application account, and one read-only monitoring account.
Is there any good way to get this working with a recent version of ActiveMQ (>= 5.9.0)?
groups.properties
admins=system
users=appuser,admin
guests=guest
users.properties
system={password redacted}
appuser=appuser
guest=guest
jetty-realm.properties
system: MD5:46cf1b5451345f5176cd70713e0c9e07,user,admin
guest: guest,guest
As an aside, I used the Jetty tutorial and the Rundeck instructions to figure out the jetty-realm.properties file and chapter 6 of ActiveMQ in Action to work out the ActiveMQ JAAS.
I was finally able to get to what I wanted by deploying the web console to an external Tomcat instance. I assume that when it runs out of process, it can't bypass security and so has to use whatever credentials you provide. In this case, I gave the Tomcat instance the read-only JMX user credentials.
It's not great, as there is no security trimmed UI. You can still attempt to create new destinations, delete destinations, etc. When you try with a read-only user, you get an error. That gets a "D" for UX, but a "B" for security.