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
Motivation
----------
`ImageReference` does not check for illegal characters in parsed image
references. This means that `containertool` will send illegal image
names to the registry. The registry will reject them, but the error
message might not explain why, so a generic error message will be
printed. Runtimes reject illegal image references immediately, without
sending them to the registry.
Modifications
-------------
* Introduce a `Repository` wrapper type
* Check validity when constructing the `Repository`
* Change the low-level API functions to accept `Repository` instead of
`String`.
Result
------
It is impossible to create a `Repository` object containing a malformed
name, because the constructor checks the string value. It is impossible
to send a malformed name to the registry because the API wrappers only
accept `Repository` objects.
Fixesapple#135
Test Plan
---------
Existing tests continue to pass.
New tests exercise additional checks which were previously missing.
0 commit comments