Skip to content

Identify masked variable output clearly

Manuel Grabowski requested to merge mg-consistent-masking-20240719 into master

What does this MR do and why?

Masked variables are being replaced with [MASKED] or with xxxxxxxx depending on where the masking is happening (Runner vs. Rails). That is confusing, and currently neither method is explained in the docs explicitly.

A masked variable has to be 8 characters or longer, which is exactly the length of [MASKED]. That means we can replace the first eight x in each variable that is being masked on the Rails side with [MASKED] and have slightly more consistent output that we can document for users.

(Based on !49004 (merged) my understanding is that it's important that the length of the string remains the same, so we can't replace it with only [MASKED] on the Rails side.)

Motivation for this change was my realization in this comment.


Putting it behind a FF (rollout issue) just to be extra cautious. As far as I could tell I can only make it an instance FF, as there seems to be no project/group/user available in the context of this code. Might be my lack of testing experience, though – happy to learn in that case.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After
image image

How to set up and validate locally

Fairly involved – follow the steps outlined in this MR to get a setup that triggers an error message where the changed behavior is observable.

Edited by Manuel Grabowski

Merge request reports

Loading