summaryrefslogtreecommitdiff
path: root/src/libgit2
Commit message (Collapse)AuthorAgeFilesLines
...
| * | repo: dump backends on oid type changeEdward Thomson2023-02-121-1/+18
| | |
| * | transport: teach transports about oid types and SHA256Edward Thomson2023-02-1211-83/+273
| | |
| * | clone: support sha256Edward Thomson2023-02-123-22/+109
| | |
| * | revparse: don't assume SHA1Edward Thomson2023-02-121-6/+13
| | |
| * | refdb: teach filesystem refdb about sha256Edward Thomson2023-02-123-48/+78
| | |
| * | object: lookup sha256 objectsEdward Thomson2023-02-1215-101/+238
| | | | | | | | | | | | | | | This is much of the plumbing for the object database to support SHA256, and for objects to be able to parse SHA256 versions of themselves.
| * | packfile: handle sha256 packfilesEdward Thomson2023-02-129-138/+238
| | | | | | | | | | | | Teach the packfile machinery to cope with SHA256.
| * | repo: don't overwrite repo format version on reinitEdward Thomson2023-02-121-8/+16
| | | | | | | | | | | | | | | Ensure that we maintain the `core.repositoryFormatVersion` value instead of always overwriting it with the default.
| * | repo: internal setter for `objectformat`Edward Thomson2023-02-122-0/+38
| | | | | | | | | | | | | | | Provide an internal function to set the repository's `objectformat`, both in the internal object and in the configuration.
| * | repo: understand the `objectformat` extensionEdward Thomson2023-02-122-5/+46
| | | | | | | | | | | | | | | | | | Teach the repository about the `objectformat` extension, supporting `sha1` always and `sha256` when the experimental sha256 support is active.
| * | oid: provide type lookups by enum value or nameEdward Thomson2023-02-091-0/+41
| | |
* | | Merge pull request #6455 from libgit2/ethomson/sysdirEdward Thomson2023-02-147-73/+408
|\ \ \ | | | | | | | | Support the notion of a home directory separately from global configuration directory
| * | | Set all SSH hostkey preferences that are availableEric Huss2023-02-091-43/+42
| | | |
| * | | core: allow users to configure home directoryEdward Thomson2023-02-091-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some callers -- like our test suite and the test suites of our language bindings -- want to isolate the home directory to avoid accidentally including the executing user's actual home directory data. Previously, we combined the notion of a home directory and global configuration -- now that this is separated, we provide users the ability to configure both.
| * | | config: use home directory for `~` includesEdward Thomson2023-02-092-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Users can specify a config file to be included in the home directory using `~/filename` syntax. Instead of looking in the global configuration location (which may be overridden), use the user's _actual_ home directory. This allows callers to change the global configuration location separately from the home directory.
| * | | attr: use home directory for `~` includesEdward Thomson2023-02-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Users can specify an attribute file to be included in the home directory using `~/filename` syntax. Instead of looking in the global configuration location (which may be overridden), use the user's _actual_ home directory. This allows callers to change the global configuration location separately from the home directory.
| * | | ssh: give a realistic error messageEdward Thomson2023-02-091-2/+2
| | | | | | | | | | | | | | | | | | | | I spent an hour banging my head against this, when it was because the remote didn't trust my key.
| * | | ssh: support windows `known_hosts` filesEdward Thomson2023-02-091-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Use `git_sysdir_find_homedir_file` to identify the path to the home directory's `.ssh/known_hosts`; this takes Windows paths into account by preferring `HOME`, then falling back to `HOMEPATH` and `USERPROFILE` directories.
| * | | sysdir: provide actual home directoryEdward Thomson2023-02-092-10/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Provide a mechanism to look up the user's home directory, using the same mechanism that we use for locating the global configuration path (a fancy name for saying "the home directory"). SSH known hosts lookups now use this, instead of simply looking at the HOME environment variable, to support Windows-style home directory lookups in `HOME`, `HOMEPATH`, or `USERPROFILE`.
| * | | sysdir: move windows sysdir functions out of shared utilEdward Thomson2023-02-092-6/+275
| |/ / | | | | | | | | | | | | | | | The windows sysdir functions are libgit2-specific and for git compatibility only; remove them from the shared util directory and bring them into the libgit2 source tree.
* | | Merge pull request #6423 from cavaquinho/fix/6422-revwalk_push_glob-dangling-refEdward Thomson2023-02-141-1/+5
|\ \ \ | | | | | | | | #6422: handle dangling symbolic refs gracefully
| * | | #6422: handle dangling symbolic refs gracefullyMiguel Arroz2022-11-031-1/+5
| | | |
* | | | Merge branch 'revparse'Edward Thomson2023-02-141-1/+10
|\ \ \ \
| * | | | revparse: comment reflog HEAD@{n} parsingEdward Thomson2023-02-141-5/+10
| | | | |
| * | | | Fix parsing rev with reflog of HEAD (e.g., HEAD@{3})Sven Strickroth2023-02-141-1/+5
| | |/ / | |/| | | | | | | | | | | | | | | | | | Fixes issue #6156. Signed-off-by: Sven Strickroth <email@cs-ware.de>
* | | | Merge pull request #6374 from vicr123/embed-sshEdward Thomson2023-02-141-10/+2
|\ \ \ \ | | | | | | | | | | Fix build failure with -DEMBED_SSH_PATH
| * | | | Fix EMBED_SSH_PATHVictor Tran2022-08-081-10/+2
| | |_|/ | |/| |
* | | | Merge pull request #6475 from jorio/fix_diff_empty_untracked_fileEdward Thomson2023-02-141-0/+7
|\ \ \ \ | | | | | | | | | | diff_file: Fix crash when freeing a patch representing an empty untracked file
| * | | | diff_file: don't mmap/readbuffer empty filesIliyas Jorio2023-02-131-0/+7
| | |/ / | |/| | | | | | | | | | This prevents GIT_MMAP_VALIDATE from failing. This also prevents git_diff_file_content__unload from attempting to free git_str__initstr.
* | | | openssl: support OpenSSL 3 in dynamic modeEdward Thomson2023-02-101-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Try to load OpenSSL 3 libraries when compiled with OpenSSL-Dynamic support. Handle the deprecated symbol renaming of SSL_get_peer_certificate to SSL_get1_peer_certificate -- try to load the old name and if it fails, use the new one.
* | | | openssl: retry initialization on failureEdward Thomson2023-02-101-1/+1
|/ / / | | | | | | | | | | | | | | | When we fail to initialize the OpenSSL subsystem, don't assume that we're "initialized". Subsequent initialization requests -- if there are any -- should replay initialization and fail again.
* | | Merge pull request #6444 from abizjak/mainEdward Thomson2023-01-261-1/+1
|\ \ \
| * | | Use `git_clone__submodule` to avoid file checks in workdirAleš Bizjak2023-01-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | `git_clone` checks for existence of (non-empty) directories that would clash with what is about to be cloned. This is problematic when cloning submodules since they make sense in the context of a parent module, so they should not use the current working dir. Since in `git_submodule_update` we clone the submodule only when it is not yet initialized we do not need to perform directory checks.
* | | | push: use resolved oid as the sourceEdward Thomson2023-01-201-1/+1
| | | | | | | | | | | | | | | | | | | | 211c97195e2ebcf68e27782715eb756823ad5a91 attempts to use the parsed OID but inverted the arguments to `git_oid_cpy`.
* | | | Merge pull request #6362 from sven-of-cord/mainEdward Thomson2023-01-201-3/+10
|\ \ \ \ | | | | | | | | | | push: revparse refspec source, so you can push things that are not refs
| * | | | push: revparse refspec source, so you can push things that are not refsSven Over2022-07-201-3/+10
| | |/ / | |/| | | | | | | | | | I want to push a commit by OID to a remote branch. Currently, push parses the refspecs such that the source must be the name of a ref (it uses git_reference_name_to_id to resolve it). This commit changes it so push uses git_revparse_single to resolve the source of the refspec. This allows for OIDs or other revs (e.g. `HEAD~2`) to be pushed.
* | | | Merge pull request #6435 from russell/capabilities-typoEdward Thomson2023-01-201-2/+2
|\ \ \ \ | | | | | | | | | | transport: fix capabilities calculation
| * | | | transport: fix capabilities calculationRussell Sim2022-11-251-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This looks like a typo to me, from what i can see these lines were added at the same time and because of how capabilities are calculated, it's likely that this code will work in situations where these capabilities were the last ones.
* | | | | Merge commit 'e33d7c068' into ssh_key_checkingEdward Thomson2023-01-201-91/+326
|\ \ \ \ \ | |_|_|/ / |/| | | |
| * | | | ssh: look for a key in known_hosts to set the key type for the handshakeCarlos Martín Nieto2022-11-041-53/+153
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The server and client negotiate a single hostkey, but the "best" cipher may not be the one for which we have an entry in `known_hosts`. This can lead to us not finding the key in known_hosts even though we should be connecting. Instead here we look up the hostname with a nonsense key to perform a lookup in the known hosts and set that. This is roughly what the OpenSSH client does as well.
| * | | | ssh: verify the remote's host key against known_hosts if it existsCarlos Martín Nieto2022-11-021-87/+222
| | |_|/ | |/| | | | | | | | | | | | | | It turns out this has been available in libssh2 for a long time and we should have been verifying this the whole time.
* | | | submodule: Do not try to update a missing submoduletagesuhu2022-11-251-1/+5
| |/ / |/| | | | | | | | | | | If a submodule has been configured but not yet added, do not try to update it. Issue #6433: git_submodule_update fails to update configured but missing submodule
* | | Merge pull request #6429 from csware/safe.directory-wildcardEdward Thomson2022-11-231-1/+3
|\ \ \ | | | | | | | | Add support for "safe.directory *"
| * | | Add support for "safe.directory *"Sven Strickroth2022-11-191-1/+3
| | | | | | | | | | | | | | | | Signed-off-by: Sven Strickroth <email@cs-ware.de>
* | | | Merge pull request #6416 from slackner/httpclient_update_optionsEdward Thomson2022-11-233-7/+27
|\ \ \ \ | |/ / / |/| | | http: Update httpclient options when reusing an existing connection.
| * | | http: Update httpclient options when reusing an existing connection.Sebastian Lackner2022-10-203-7/+27
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | Httpclient internally stores a copy of the certificate_check callback and payload. When connecting via HTTPS, and if the server sends back "Connection: close" after the first request, the following request would attempt to re-use the httpclient and call the (now outdated) callback. In particular for pygit2 this is a problem, since callbacks / payloads are only valid for the duration of a libgit2 call, leading to a ffi.from_handle() error and crashing the Python interpreter.
* | | Merge pull request #6421 from ↵Edward Thomson2022-11-181-2/+7
|\ \ \ | | | | | | | | | | | | | | | | julianmesa-gitkraken/fix-leak-git_tag_create_from_buffer Fix leak in git_tag_create_from_buffer
| * | | Missing dispose in git_tag_create__internalJulian Mesa2022-11-031-1/+3
| | | |
| * | | Missing disposeJulian Mesa2022-11-031-1/+3
| | | |
| * | | Fix leak in git_tag_create_from_bufferJulian Mesa2022-11-031-0/+1
| |/ / | | | | | | | | | If the tag already exists and we are not forcing overwrite we need to free ref_name buffer before return the "tag already exists" error.