You might found base64 string somehow looks like always ends with "=". In fact, "=" is a padding when the base64 string length is not times 4.
for example, "errong.win" string convert to base64 will be "ZXJyb25nLndpbg==". The last two "=" are called padding.
issue with command "echo xxx | base64"
in k8s, the opaque Secret is encoding the secret value with base64. But it is not safe, better to use SealedSecret.
Encrypt your Secret into a SealedSecret, which is safe to store - even inside a public repository.
One of my colleagues encountered a wired issue. She create a opaque secret for a spring data source password value(base64 string via command "echo springdatasourcepassword | base64"). Then convert this secret to a sealed secret.
The sealed secret revealed value looks exactly same as the plain password. But her app always faced login issue. The root cause is the padding. The command didn't appended padding for the encoded password base64 string.