-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Metricbeat] MSSQL module cannot parse username if domain is included within the host string #13364
Comments
Pinging @elastic/integrations (Team:Integrations) |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Please try out the below:
and ignore the |
@geekpete Any update on the above suggestion? |
@geekpete Any Update here? |
Sorry, I'm still working to follow up on this one. |
@geekpete Any update on the suggested method? |
@geekpete Any inputs so that we can proceed with the further about this? |
So in the original testing for this issue it looks like we'd tried everything except the way you're suggesting:
but not with two forward slashes after the
I'll see if I can get this tested and report back. |
Thank you @geekpete |
The issue here is that the diff --git a/metricbeat/mb/parse/url.go b/metricbeat/mb/parse/url.go
index c0b23f421d..5c2ff19e86 100644
--- a/metricbeat/mb/parse/url.go
+++ b/metricbeat/mb/parse/url.go
@@ -71,6 +71,8 @@ func (b URLHostParserBuilder) Build() mb.HostParser {
} else {
user = b.DefaultUsername
}
+ user = url.PathEscape(user)
+
t, ok = conf["password"]
if ok {
pass, ok = t.(string) |
Until the codebase is adjusted to automatically escape/encode the slash, it's also likely you can configure the string without the slash by manually passing the encoded value ie for domain user: |
Related issue to sanitize input in Kibana elastic/integrations#5213 |
Please include configurations and logs if available.
For confirmed bugs, please report:
Using a domain within the username in credentials doesn't seem to parse regardless of escaping.
Typical configuration example might look like:
But when attempting to use an Active Domain user rather than the
SA
service account, there doesn't seem to be a way to specify the domain within the hosts connection string and have it work.Examples of what doesn't work:
Example errors
When trying with domain:
If leaving the domain out, the error is that the native user with that name cannot log in as the user with access is the domain user with that name not a native user:
Interestingly the domain credentials can be made to work if set separately via:
Related:
The text was updated successfully, but these errors were encountered: