- Commits:
-
Summary ID Author e60f11824ab0a686ea7657cc9e61dbdf0ae511c2 Andre Klitzing dffeb56c7a24f40d322717071229c171a3f52574 Andre Klitzing - Diff:
-
Revision 2 (+10)
Deny invalid path
Review Request #2422 — Created April 4, 2023 and submitted
If an authenticated user calls
hg init hg.host.com/dummy/../../../etc
it will create the repository in another root directory if the process of
hgkeeper has permissions for this.
This could be an attack to the server.Also hgkeeper admin repository can be overriden like this.
hg init ssh://hg.host.com/dummy/../hgkeeper/keys
Summary | ID | Author |
---|---|---|
2003064d3ef00d9fa0eb452880164e1c8e26facb | Andre Klitzing |
Description | From | Last Updated |
---|---|---|
mh, that is a bad fix... let's retry... |
aklitzing@gmail.com | |
we probably want to use filepath.Clean here on repoName at a minimum. |
grim | |
not really a fan of a security related function being duplicated. I know this is because there's no good place … |
grim |
- Description:
-
~ If an authenticated user calls "hg init hg.host.com/dummy/../../../etc"
~ If an authenticated user calls
hg init hg.host.com/dummy/../../../etc
it will create the repository in another root directory if the process of hgkeeper has permissions for this. This could be an attack to the server. + + Also hgkeeper admin repository can be overriden like this.
+ hg init ssh://hg.host.com/dummy/../hgkeeper/keys
- Summary:
-
Deny "hg init" for invalid pathDeny invalid path
- Commits:
-
Summary ID Author dffeb56c7a24f40d322717071229c171a3f52574 Andre Klitzing c5f114c462eda7aeb347a68541c8d53c28e6a168 Andre Klitzing
- Commits:
-
Summary ID Author c5f114c462eda7aeb347a68541c8d53c28e6a168 Andre Klitzing 6e762c86354f760c1707fff79dd802aacdd0a815 Andre Klitzing
- Commits:
-
Summary ID Author 6e762c86354f760c1707fff79dd802aacdd0a815 Andre Klitzing 2d7cd54a56663e707bd230b08460c4f325d87779 Andre Klitzing
- Commits:
-
Summary ID Author 2d7cd54a56663e707bd230b08460c4f325d87779 Andre Klitzing 4027c61d978cbcc913536121dc5764d8ead24476 Andre Klitzing
- Commits:
-
Summary ID Author 4027c61d978cbcc913536121dc5764d8ead24476 Andre Klitzing 59a61ba161ddcd6d2de505eb1458a027bb509fdd Andre Klitzing
- Commits:
-
Summary ID Author 59a61ba161ddcd6d2de505eb1458a027bb509fdd Andre Klitzing 135c74678a57f46cdfcdf8b95f77eb304172cea8 Andre Klitzing
- Commits:
-
Summary ID Author 135c74678a57f46cdfcdf8b95f77eb304172cea8 Andre Klitzing 01c4b79434d4b4aeabbb46a024251b6a7bdd1f35 Andre Klitzing