-
Notifications
You must be signed in to change notification settings - Fork 931
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
lxc: Prevent accept-certificate flag when using trust token #14149
Commits on Oct 14, 2024
-
lxc/remote: Fix interactive question about remote fingerprint
Do not exit if incorrect input is provided when asking to accept remote certificate. Instead, ask the question again. Exit only if user entered 'n' (answered with no) or has provided the incorrect fingerprint to prevent scripts from hanging in such case. This issue was found because previously returned error ended with colon (':'), indicating the error was not meant to terminate interaction, but rather ask user again for valid answer. Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for 4c85e35 - Browse repository at this point
Copy the full SHA 4c85e35View commit details -
lxc/remote: Add validation for mutually exclusive flags
Prevents usage of flag --token with flags --oidc and --public. Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for 30c9f50 - Browse repository at this point
Copy the full SHA 30c9f50View commit details -
lxc/remote: Prevent accept-certificate flag when using trust token
When trust token is provided, certificate cannot be blindly accepted. Trust token contains certificate fingerprint, which has to be compared with the remote certificate fingerprint. If those do not match, we should never accept the remote certificate. Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for d83ac8f - Browse repository at this point
Copy the full SHA d83ac8fView commit details -
lxd/certificates: Invalidate trust token when adding client certificate
If certificate add request is sent from a trusted client and the trust token is provided, first ensure the provided token is valid, then invalidate it by canceling the corresponding token operation, and finally return the conflict error because the client certificate is already present in the trust store. Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for 693409b - Browse repository at this point
Copy the full SHA 693409bView commit details -
lxc/remote: Always send token to remote to invalidate it
Even if the remote already trust us, send the token to the remote to invalidate it. Ignore conflict error, which indicates that the remote already trust us. Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for 99b40da - Browse repository at this point
Copy the full SHA 99b40daView commit details -
test: Remove accept-certificate flag where token is used
Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for 5577379 - Browse repository at this point
Copy the full SHA 5577379View commit details -
test/pki: Do not use invalid token as it will always fail
Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for 82d0683 - Browse repository at this point
Copy the full SHA 82d0683View commit details -
test/clustering: Remove unused token
Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for 1521aa2 - Browse repository at this point
Copy the full SHA 1521aa2View commit details -
test/clustering: Do not use token when adding public remote
Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for db59e89 - Browse repository at this point
Copy the full SHA db59e89View commit details -
test: Ensure token cannot be used with --accept-certificate flag
Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for 0098b7f - Browse repository at this point
Copy the full SHA 0098b7fView commit details -
i18n: Update translation templates.
Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for b77e4a3 - Browse repository at this point
Copy the full SHA b77e4a3View commit details -
Signed-off-by: Din Music <din.music@canonical.com>
Configuration menu - View commit details
-
Copy full SHA for 88f5b75 - Browse repository at this point
Copy the full SHA 88f5b75View commit details