|
dbccfc20
|
2022-01-26T13:57:48
|
|
odb: accept an oid type in options
Allow the object database to take an oid type that it supports. This
oid type will be used to validate the objects that the backends provide.
|
|
3eba9181
|
2022-01-26T13:02:49
|
|
odb: add git_odb_options
Users will need to be able to specify the object id type for the given
object database; add a new `git_odb_options` with that option.
|
|
c50b280f
|
2022-01-26T13:08:24
|
|
oid: provide an oid type to hash type map
We intentionally separate oid types from hash types; a hash is a generic
hunk of bytes, an object id has meaning and backs an object on disk. As
a result of this separation, we need a 1:1 mapping.
|
|
3fbf580c
|
2022-01-23T09:47:01
|
|
oid: give oids a type
`git_oid`s now have a type, and we require the oid type when creating
the object id from creation functions.
|
|
14798060
|
2022-01-26T13:10:36
|
|
oid: specify a default implementation
libgit2's current default oid type is SHA1, set a public macro for that.
|
|
8444b6dc
|
2022-01-26T13:07:28
|
|
odb_hash*: accept the oid type to hash into
The git_odb_hash helper functions should not assume SHA1, and instead
should be given the oid type that they're producing.
|
|
81732413
|
2022-01-27T15:02:27
|
|
clar: format sha256 in cl_assert_equal_oid
|
|
0db1c57c
|
2022-01-25T10:32:47
|
|
oid: add sha256 typed oids
|
|
61838295
|
2022-01-26T16:22:04
|
|
object: move oid header printing to object
|
|
b7a46fa8
|
2022-01-23T12:25:03
|
|
object: move oid header parsing to object
|
|
c4360116
|
2021-12-12T09:56:28
|
|
oid: include maximum oid raw/hex sizes
|
|
0b068214
|
2021-12-11T15:34:27
|
|
oid: add functions to inspect oid information
Provide helper functions to provide information about the object id size
given its type.
|
|
74ffce20
|
2021-12-11T12:00:26
|
|
oid: introduce `git_oid_t`
We require an enumeration to help us identify the different types of
object IDs. Currently, we only support SHA1 but we will support SHA256
in the future.
|
|
0acaf3a8
|
2022-01-17T13:40:37
|
|
oid: define GIT_OID_SHA1_ZERO
Callers should not assume the layout of the oid structure; provide them
a macro that defines the null / zero sha1 object id.
|
|
dbc4ac1c
|
2022-01-22T23:10:03
|
|
oid: `GIT_OID_*SZ` is now `GIT_OID_SHA1_*SIZE`
In preparation for SHA256 support, `GIT_OID_RAWSZ` and `GIT_OID_HEXSZ`
need to indicate that they're the size of _SHA1_ OIDs.
|
|
f98dd543
|
2022-06-13T22:14:37
|
|
Merge pull request #6321 from libgit2/ethomson/ownership
repo: allow administrator to own the configuration
|
|
05f21154
|
2022-06-13T21:56:01
|
|
Merge pull request #6322 from libgit2/ethomson/stat
status: update documentation for default options
|
|
fb68f180
|
2022-06-13T21:44:05
|
|
status: update documentation for default options
|
|
70a182c6
|
2022-06-13T21:38:32
|
|
Merge pull request #6320 from libgit2/ethomson/config-docs
config: update config entry iteration lifecycle
|
|
cdff2f02
|
2022-06-13T21:34:01
|
|
repo: allow administrator to own the configuration
Update our ownership checks that were introduced in libgit2 v1.4.3
(to combat CVE 2022-24765). These were not compatible with git's; git
itself allows administrators to own the path. Our checks now match
this behavior.
|
|
1ed1e19a
|
2022-06-13T21:23:42
|
|
config: update config entry iteration lifecycle
|
|
96c61174
|
2022-06-13T11:19:55
|
|
cmake: only use `getloadavg` where it exists
|
|
3809ab0e
|
2022-06-13T10:50:40
|
|
cmake: add `gnu` library for Haiku
|
|
9bc82c8f
|
2022-06-13T10:46:21
|
|
cmake: detect `getentropy`
Look for `getentropy` and flag its existence.
|
|
7eb7edd4
|
2022-06-12T10:51:13
|
|
Merge pull request #6278 from lhchavez/git_transport_smart_remote_connect_options
transport: introduce `git_transport_smart_remote_connect_options`
|
|
cc4c37ca
|
2022-06-12T10:50:43
|
|
transport: remove `git_transport_smart_proxy_options`
Snuck in during refactoring; let's get rid of it.
|
|
d333dbea
|
2022-06-12T10:40:12
|
|
Merge pull request #6288 from libgit2/cmn/mwindow-simplifications
A couple of simplications around mwindow
|
|
660e6bd5
|
2022-06-11T21:21:01
|
|
Merge pull request #6023 from libgit2/ethomson/clang-format
Add a .clang-format with our style
|
|
0a7c00be
|
2022-06-11T14:31:16
|
|
Merge remote-tracking branch 'origin/main' into main
|
|
a7541676
|
2022-06-11T14:29:15
|
|
Apply suggestions from code review
Co-authored-by: Edward Thomson <ethomson@github.com>
|
|
2b28ee77
|
2022-06-11T16:51:04
|
|
Merge pull request #6319 from libgit2/ethomson/progress_32bit
CLI: progress updates
|
|
28d2ea1d
|
2022-06-11T16:50:56
|
|
Merge pull request #6305 from zawata/fix_refdb_error_msg
refs: fix missing error message
|
|
3b8a06c0
|
2022-06-11T16:50:35
|
|
Merge pull request #6287 from SkinnyMind/docs-typos
docs: fix couple of typos
|
|
565a3317
|
2022-06-11T16:28:12
|
|
Merge pull request #6299 from dongcarl/patch-1
revparse: Remove error-prone, redundant test
|
|
4f7b568d
|
2022-06-11T16:26:50
|
|
Merge pull request #6291 from libgit2/cmn/midx-no-hash
midx: do not verify the checksum on load
|
|
3a737169
|
2022-06-11T16:14:11
|
|
progress: fewer updates about throughput
Avoid too much flashing on the console with updates about throughput.
Only update throughput once a second.
|
|
286e7f0a
|
2022-06-11T16:08:28
|
|
cli: show progress on 32 bit machines
|
|
4f0ee02f
|
2022-06-11T15:40:10
|
|
Merge pull request #6306 from libgit2/ethomson/ci_test
Include test results data in CI
|
|
6bd024aa
|
2022-06-11T15:38:33
|
|
Merge pull request #6309 from ccstolley/ccs_fix_midx_offset
midx: fix large offset table check.
|
|
11b81717
|
2022-06-11T15:36:37
|
|
Merge pull request #6318 from apnadkarni/patch-3
Add link to Tcl bindings for libgit2
|
|
529aa173
|
2022-06-11T15:35:42
|
|
Merge pull request #6310 from theseion/add-pharo-to-language-bindings
chore(docs): Add Pharo to language bindings
|
|
f140f69b
|
2022-06-02T16:15:42
|
|
Add link to Tcl bindings for libgit2
|
|
25830642
|
2022-05-22T14:08:34
|
|
chore(docs): add Pharo to language bindings
|
|
97954ee5
|
2022-05-20T09:06:50
|
|
Replace bitwise AND 0x7fffffff with XOR 0x80000000.
Though both are correct, this makes it clear that we're dealing with
the same value.
|
|
8a765c72
|
2022-05-19T16:33:57
|
|
midx: fix large object offset table check.
It's insufficient to only check if the offset high order bit is set, we
must also check to see if object_large_offsets are in use.
This bug is causing objects to appear missing because they can't be
found in the index.
|
|
3fada669
|
2022-05-17T17:15:34
|
|
ci: show test results summary
|
|
8747c004
|
2022-05-17T14:41:02
|
|
ci: upload test result data as artifacts
|
|
fd8d3673
|
2022-05-17T16:23:14
|
|
ci: use uid/gid of actions runner
Avoid mismatches between the container uid/gid and the actions runner,
build the container with the actions runner's uid/gid
|
|
640e8a63
|
2022-05-17T11:01:43
|
|
fix missing error message
|
|
7f53d7b6
|
2022-05-09T12:09:08
|
|
revparse: Remove error-prone, redundant test
Originally introduced in: 776a6a8e5f8e258d31aded73c0ce38df6ac7bdc4
This test case has recently been fixed in bdab22384cc61d315005a65456a9f9563bb27c8f, but that fix will only last for a year. Next year the same problem will crop up and the test will need to be re-edited.
This is not ideal as
- This test case becomes an unnecessary burden for developers
- Downstream distros or even just users who want to build older versions of libgit2 are guaranteed to have this test fail
Furthermore, this test case is entirely unnecessary, as the functionality that was originally (see 776a6a8e5f8e258d31aded73c0ce38df6ac7bdc4) intended to be tested is well-covered by subsequent tests which specify a date instead of a "x ago" specification.
|
|
a3f9617b
|
2022-05-03T14:09:40
|
|
midx: do not verify the checksum on load
This is something we only want to do during explicit verification rather than on
every load.
Verifying does not seem like a big deal when we're running with test workloads
but once your `multi-pack-index` reaches gigabytes, we spend more time hashing
this than doing any work.
|
|
bdab2238
|
2022-05-03T09:28:43
|
|
revparse: adjust reflog test as we move away from the dates
The dates we use in `refs::revparse::date` has just passed the ten years, so
now everything is beyond ten years, leading to an unexpected commit being
returned.
Adjust it to 11 years so it all looks fine again.
|
|
0f594445
|
2022-04-29T10:50:02
|
|
mwindow: use multiplication instesad of conditionals
This is a very verbose way of performing a comparison where we already
have the identity value with both signs. Instead of chainging several
conditions, we can rely on the maths working out.
|
|
55c84333
|
2022-04-29T10:32:45
|
|
mwindow: include both the offset and the extra in the same call
This makes it a bit easier to read while letting the caller specify
how big the hash size is for this particular call.
|
|
9af5db9a
|
2022-04-28T17:06:54
|
|
docs: fix couple of typos
|
|
13502d9e
|
2022-04-25T09:22:02
|
|
Merge pull request #6274 from libgit2/ethomson/cli_clone
cli: clone
|
|
a1c94e94
|
2022-04-25T09:15:59
|
|
Merge pull request #6277 from cschlack/sys_transport_missing_include
Fix missing include
|
|
70506171
|
2022-04-25T09:15:11
|
|
Merge pull request #6276 from lhchavez/delete-git_transport_smart_proxy_options
remote: Delete a now-inexistent API declaration
|
|
c6416100
|
2022-04-20T09:11:29
|
|
ci: map the build folder in container builds
Now that the containers all set the user id of the libgit2 build user to
the user id of the host runner, we can write to a shared build output
volume.
|
|
06b32a3f
|
2022-04-20T14:45:44
|
|
ci: move centos8 to centos stream
CentOS 8 is no longer supported; use CentOS stream.
|
|
926efbd2
|
2022-04-20T14:20:39
|
|
ci: use the runner's uid/gid
Use the runner's uid/gid for the containers for sanity when sharing
files across volumes.
|
|
00612f79
|
2022-04-19T12:09:00
|
|
ci: move to ghcr.io instead of deprecated github packages urls
|
|
2ee753a2
|
2022-04-19T11:55:49
|
|
ci: some debugging output for containers
|
|
3b52e5f5
|
2022-04-18T17:12:27
|
|
Merge pull request #6265 from libgit2/ethomson/sha256_two
sha256: refactoring in preparation for sha256
|
|
1d88605c
|
2022-04-16T08:19:38
|
|
transport: introduce `git_transport_smart_remote_connect_options`
6fc6eeb66c40310086c8f059cae41de69ad4c6da removed
`git_transport_smart_proxy_option`, and there was nothing added to
replace it. That made it hard for custom transports / smart
subtransports to know what remote connect options to use (e.g. proxy
options).
This change introduces `git_transport_smart_remote_connect_options` to
replace it.
|
|
a6fb41ff
|
2022-04-16T14:56:23
|
|
Fix missing include
|
|
88f24384
|
2022-04-14T07:18:06
|
|
remote: Delete a now-inexistent API declaration
6fc6eeb66c40310086c8f059cae41de69ad4c6da replaced the remote options
with `git_remote_connect_options`. The function definitions were
removed, but one function declaration remained, causing linker errors if
one tried to use it.
This change removes the declaration of
`git_transport_smart_proxy_option` to better reflect reality.
|
|
8a757ae2
|
2020-04-04T18:31:00
|
|
cli: introduce a clone command
|
|
7babe76f
|
2020-05-12T08:56:55
|
|
cli: introduce signal handler
Provide a mechanism to add a signal handler for Unix or Win32.
|
|
48506f2b
|
2020-04-04T18:29:34
|
|
cli: introduce a progress class
Provide a class that will display progress information to the console.
Initially, it contains callbacks for fetch progress and checkout
progress.
|
|
63970244
|
2022-04-12T14:11:54
|
|
Merge pull request #6266 from libgit2/ethomson/ownership
Validate repository directory ownership
|
|
4161ebdd
|
2022-04-11T21:31:25
|
|
repo: make ownership checks optional
Introduce the `GIT_OPT_SET_OWNER_VALIDATION` option, so that users can
disable repository ownership validation.
|
|
fa366921
|
2022-04-11T15:18:44
|
|
repo: honor safe.directory during ownership checks
Obey the `safe.directory` configuration variable if it is set in the
global or system configuration. (Do not try to load this from the
repository configuration - to avoid malicious repositories that then
mark themselves as safe.)
|
|
f7f7e835
|
2022-04-11T13:04:26
|
|
repo: refactor global config loader function
Pull the global configuration loader out of the symlink check so that it
can be re-used.
|
|
90d2b619
|
2022-04-11T17:07:20
|
|
repo: test configuration ownership validation
Test that we prevent opening directories that are not owned by
ourselves.
|
|
c0b7f88e
|
2022-04-11T17:06:55
|
|
fs_path: mock ownership checks
Provide a mock for file ownership for testability.
|
|
c0dfd1ad
|
2022-04-11T09:56:26
|
|
repo: ensure that repo dir is owned by current user
Ensure that the repository directory is owned by the current user; this
prevents us from opening configuration files that may have been created
by an attacker.
|
|
bf2620bc
|
2022-04-10T21:29:43
|
|
fs_path: refactor ownership checks into current user and system
Provide individual file ownership checks for both the current user and
the system user, as well as a combined current user and system user
check.
|
|
f8821405
|
2022-01-27T15:19:09
|
|
fuzzer: use raw oid data
The indexer expects raw oid data, provide it.
|
|
71049b4a
|
2022-01-22T09:03:34
|
|
midx: use raw oid data
A multi-pack index uses raw oid data, use a byte array to index
into them.
|
|
41d4ac51
|
2022-01-22T08:49:06
|
|
index: use raw oid data
The index contains entries with raw oid data, use a byte array for the
raw entry data.
|
|
4fc3ce15
|
2022-01-22T07:46:41
|
|
pack: use raw oid data
A packfile contains arrays of raw oid data, use a byte array to index
into them.
|
|
c2b3b0d8
|
2022-01-21T19:38:13
|
|
commit_graph: use raw oid data
The commit graph contains arrays of raw oid data, use a byte array to
index into them.
|
|
9ffa33a1
|
2022-01-22T08:48:43
|
|
oid: introduce `git_oid_raw_cpy`
Now that oids are type-aware, they use their type to understand how many
bytes to copy. Some callers may need to copy the raw bytes of the
object id.
This is equivalent to a memcpy that is a little more semantic.
|
|
6d8c7cab
|
2022-01-21T19:37:53
|
|
oid: introduce `git_oid_raw_ncmp`
|
|
526e8869
|
2022-01-21T19:17:40
|
|
oid: `hashcmp` is now `raw_cmp`
We will talk about "raw" oids as untyped blobs of data; use a name for
the comparison function that is in keeping with that.
|
|
7367a9d5
|
2022-01-22T09:07:26
|
|
tests: don't cast raw data to a `git_oid``
Create an object id from raw data instead of casting.
|
|
c569738c
|
2022-01-22T08:55:41
|
|
indexer: write raw id data
Don't write the object id structure, write its raw oid data.
|
|
563751d1
|
2022-01-22T06:42:50
|
|
treecache: write the raw id not the object
We explicitly want to write on the id data, not the beginning of the
object data, which may contain other information in the future.
|
|
831e20ac
|
2022-01-22T06:39:38
|
|
oidmap: hash on the id, not the object
We explicitly want to hash on the id data, not the beginning of the
object data, which may contain other information in the future.
|
|
590ff981
|
2022-01-21T19:49:09
|
|
oid: don't assume the size of an oid
Don't assume that a `git_oid` is a particular size; allocate
`sizeof(git_oid)` instead.
|
|
ab042161
|
2022-01-18T08:12:18
|
|
tree: move git_oid into tree entry
A tree entry previously pointed directly into the object id within the
tree object itself; this is useful to avoid any unnecessary memory copy
(and an unnecessary use of 40 bytes per tree entry) but difficult if we
change the underlying `git_oid` object to not simply be a raw object id
but have additional structure.
This commit moves the `git_oid` directly into the tree entry; this
simplifies the tree entry creation from user data. We now copy the
`git_oid` into place when parsing.
|
|
7e8d9be0
|
2022-04-10T09:45:51
|
|
Merge pull request #6260 from lhchavez/midx-fix-ub
midx: Fix an undefined behavior (left-shift signed overflow)
|
|
606afeda
|
2022-04-10T09:44:41
|
|
Merge pull request #6244 from jorio/fix-diff_delta_format_path-crash
Fix crash when regenerating a patch with unquoted spaces in filename
|
|
71bb92b5
|
2022-04-10T09:25:54
|
|
Update src/libgit2/diff_print.c
|
|
2fc0fcb5
|
2022-04-06T15:54:14
|
|
Merge pull request #6262 from libgit2/ethomson/zero_stat
tests: support flaky stat
|
|
e7fce1b5
|
2022-04-06T10:22:29
|
|
tests: support flaky stat
The 32-bit ARM QEMU builds are flaky when running `lstat`. Disable those
testing `lstat`'s `st_size` temporarily.
|
|
4e85b4fc
|
2022-04-05T22:40:43
|
|
Merge pull request #6259 from libgit2/ethomson/diff_arm32
diff: don't stat empty file on arm32 (flaky test)
|
|
cd8fde82
|
2022-04-05T22:40:28
|
|
Merge pull request #6258 from libgit2/ethomson/sha256_openssl_dynamic
sha256: support dynamically loaded openssl
|
|
33b1d3fd
|
2022-04-05T13:10:33
|
|
[midx] Fix an undefined behavior (left-shift signed overflow)
There was a missing check to ensure that the `off64_t` (which is a
signed value) didn't overflow when parsing it from the midx file. This
shouldn't have huge repercusions since the parsed value is immediately
validated afterwards, but then again, there is no such thing as "benign"
undefined behavior.
This change makes all the bitwise arithmetic happen with unsigned types
and is only casted to `off64_t` until the very end.
Thanks to Taotao Gu for finding and reporting this!
|