SSH HostKeys are not verified with git commands permitting MITM attacks (GitRepo)
Hello,
src/robusta/integrations/git/git_repo.py contains the following code:
os.system(f"ssh-keyscan -H github.com bitbucket.org >> {SSH_ROOT_DIR}/known_hosts")
While this makes it easy to connect via SSH it also completely bypasses hostkey checks.
This should not be the default! From what I can see it's also not documented.
While testing git_audit_change I also didn't find a way to specify additional hostkeys; in my case to connect to a non-Github git server.
Best, Simon
Thanks for reporting it @rudis
Your description of the problem is accurate. We will add host keys configuration option, and will change the default behavior
Is the host key config option being worked on?
Hi @llavin No one is working on it at the moment
@llavin @rudis https://github.com/robusta-dev/robusta/pull/1313