You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Mask query parameter values in repository URLs shown in output, particularly access_token #1316
I noticed this while improving how we support Hex in ... there's a potential security risk here that I'm manually working around in Dependabot, but it would be more secure if Hex masked these values (or offered a flag to mask these values) itself.
Problem
Repository URLs can contain authentication values in query parameters, for example:
When a package fetch fails without a cached copy, Hex.SCM includes the generated tarball URL in the Mix.Error message. The current prune_uri_userinfo/1 helper masks URI userinfo, but leaves query parameter values unchanged, so the token can appear in terminal output, CI logs, and captured exceptions.
The same URL can also be emitted in debug output after a successful fetch.
This behavior is present on the current main branch in Hex.SCM.tarball_url/3 and prune_uri_userinfo/1.
Requested behavior
Mask query parameter values whenever a repository URL is rendered for output, while preserving parameter names for debugging. For example:
Masking all query values would avoid relying on a fixed list of sensitive parameter names.
Notes
No real credentials are included in this report. This is a request for defensive redaction of repository URLs that may contain query-string authentication values.
changed the title [-]Mask query parameter values in repository URLs shown in output[/-][+]Mask query parameter values in repository URLs shown in output, particularly `access_token`[/+]on Nov 18, 2026
Putting this value into the repo URL will lead to lots of places "leaking" this information. For example, if you create an SBoM using mix_sbom, that URL will be written into the JSON.
Do you have an idea who configures hex like this? If any commercial providers like Artifactory do this, we should tell them to stop doing that.
Activity
[-]Mask query parameter values in repository URLs shown in output[/-][+]Mask query parameter values in repository URLs shown in output, particularly `access_token`[/+]maennchen commentedon Nov 18, 2026
Putting authentication is not something hex ever recommended as far as I'm aware. Hex does have means to do authentication, for example Oban Pro:
mix hex.repo add oban https://repo.oban.pro \ --fetch-public-key SHA256:4/OSKi0NRF91QVVXlGAhb/BIMLnK8NHcx/EWs+aIWPc \ --auth-key $OBAN_LICENSE_KEYPutting this value into the repo URL will lead to lots of places "leaking" this information. For example, if you create an SBoM using
mix_sbom, that URL will be written into the JSON.Do you have an idea who configures hex like this? If any commercial providers like Artifactory do this, we should tell them to stop doing that.