Commit Graph

15848 Commits

Author SHA1 Message Date
Edward Thomson
dc95ee2712 ssl: restore tls v1.0 support temporarily
Removing TLS v1.0 and v1.1 support is a bit of a breaking change; making
that change without any announcement or preparation is rather unkind.

Defer the TLS v1.2 requirement to the next version, but update the
cipher selection to the Mozilla backward compatibility list.
2024-12-18 21:04:07 +00:00
Edward Thomson
5576e8f6a9 docs: add "benchmarks" section to changelog 2024-12-16 10:56:31 +00:00
Edward Thomson
ab0e1606b4 docs: include v1.8.4 changelog 2024-12-16 10:56:31 +00:00
Edward Thomson
0c48276448 Merge pull request #6960 from libgit2/ethomson/tls
TLS: v1.2 and updated cipher list
2024-12-16 10:39:23 +00:00
Edward Thomson
e014b10e78 security: improve the default TLS ciphers
Update our default cipher list to the most recent "intermediate"
configuration from Mozilla's SSL cipher list, which is "recommended
cnofiguration for a general-purpose server".

https://wiki.mozilla.org/Security/Server_Side_TLS

This removes many outdated ciphers that are no longer practically
supported by servers, including GitHub, GitLab, and Bitbucket.
2024-12-16 10:07:10 +00:00
Edward Thomson
833224964a security: require TLSv1.2 or higher 2024-12-16 10:03:54 +00:00
Edward Thomson
8049f00e3b Merge remote-tracking branch 'origin/main' into ssh 2024-12-13 23:32:32 +00:00
Edward Thomson
bef4b73871 transport: only clear data when not in rpc mode
In RPC mode (https), we need to resend the data so that the remote
endpoint keeps context. In non-RPC mode, we need not (and should not)
resend it. Clear that buffer data in non-RPC mode to prevent this.
2024-12-13 23:13:52 +00:00
Edward Thomson
c642ef9d4c Merge pull request #6959 from libgit2/ethomson/pathspec_tests
pathspec: additional pathspec wildcard tests
2024-12-13 22:49:57 +00:00
Edward Thomson
0bb7d45897 Merge pull request #6944 from mathworks/pr_6724
object: git_object_short_id fails with core.abbrev string values
2024-12-12 16:09:41 +00:00
lmcglash
d363cc8fee Apply PR feedback. 2024-12-11 19:55:54 +00:00
Edward Thomson
8ad1eb9c72 Merge pull request #6958 from libgit2/ethomson/init-docs
docs: remind people about `git_libgit2_init`
2024-12-11 12:40:29 +00:00
Edward Thomson
48820e6c74 pathspec: additional pathspec wildcard tests
We did not have (obvious) pathspec wildcard tests for `**/foo` behavior.
Add some based on git's observed behavior.
2024-12-11 10:58:03 +00:00
Edward Thomson
f675ea3cd7 docs: remind people about git_libgit2_init
Currently `git_libgit2_init` must be called before you can work with the
library. Remind people about this as they read the documentation.
2024-12-11 10:54:21 +00:00
Edward Thomson
1738f891a1 Merge pull request #6951 from ryan-ph/ryanpham/negative-refspec/parse
refs: Handle normalizing negative refspecs
2024-12-11 00:59:53 +00:00
Edward Thomson
7668c13552 refs: remove obsolete validity test with carat prefix
Refs can now be prefixed with a ^ (indicating a negative ref). Remove a
now-obsolete validity test.
2024-12-11 00:38:17 +00:00
Edward Thomson
27d82f15cd Merge pull request #6957 from libgit2/ethomson/docs-ci
Documentation: clean up old documentation
2024-12-10 23:59:36 +00:00
Edward Thomson
03e0bf3ba2 Documentation generation: verbose generation 2024-12-10 23:41:15 +00:00
Edward Thomson
0f1cb81a0c Documentation: clean up old documentation
Clean up the outdated documentation folder before re-generating it in
place. This accomodates a deleted API.
2024-12-10 23:22:35 +00:00
lmcglash
4fef2bd289 Move abbrev_length from object to repository. 2024-12-10 20:44:04 +00:00
Edward Thomson
6821bde736 Merge pull request #6940 from libgit2/ethomson/win32
Make `GIT_WIN32` an internal declaration
2024-12-10 07:57:49 +00:00
Edward Thomson
455ce40994 Make GIT_WIN32 an internal declaration
The `GIT_WIN32` macro should only be used internally; keep it as such.
2024-12-09 23:36:34 +00:00
Edward Thomson
f54d4601ce odb: fix mempack cast 2024-12-09 23:36:34 +00:00
Edward Thomson
4282cbd6d8 Merge remote-tracking branch 'main' into mempack_empty 2024-12-09 22:38:29 +00:00
Edward Thomson
4bb69b0827 odb_mempack: use an out param 2024-12-09 22:36:10 +00:00
Edward Thomson
2b74d4be1a Merge pull request #6955 from libgit2/ethomson/docs
Documentation: update refdb_backend docs
2024-12-09 22:17:45 +00:00
Edward Thomson
88fee7af56 Documentation: update refdb_backend docs
Parameters are documented by `@param`, not `@arg`
2024-12-09 21:52:44 +00:00
Edward Thomson
ce01bb30fc Merge pull request #6954 from libgit2/ethomson/docs
Documentation: don't resort versions
2024-12-09 17:28:56 +00:00
Edward Thomson
8ae0a22bf9 Documentation: don't resort versions
Array.sort() mutates the array _and_ returns it; don't mutate the
version array.
2024-12-09 17:02:37 +00:00
Edward Thomson
cd8f2730f1 Merge pull request #6953 from libgit2/ethomson/docs-search
Add search functionality to our docs generator
2024-12-09 13:13:15 +00:00
Edward Thomson
5efc00612c Generate search page in documentation generation 2024-12-09 12:39:21 +00:00
Edward Thomson
6297b6195c Add search capabilities to docs
Include "minisearch" which is a straightforward client-side search tool;
and a script to generate the search index for minisearch for each
version of libgit2.
2024-12-09 12:39:21 +00:00
Edward Thomson
1da67ef096 Allow documentation (re)generation in CI build
Provide a mechanism to allow the documentation to be force rebuilt.
2024-12-09 12:39:21 +00:00
Ryan Pham
2adb7bc3f5 refs: Handle normalizing negative refspecs
Negative refspecs were added in Git v2.29.0 which allows refspecs to be
prefixed with `^`[^1]. Currently, the library is unable to normalize
negative refspecs which causes errors in different tools that rely on
`libgit2`. Specifically, when the library attempts to parse and
normalize a negative refspec, it returns a `GIT_EINVALIDSPEC` code.

Add the ability to correctly normalize negative refspecs. While this PR
will not update the behavior of `fetch`, or other actions that rely on
negative refspecs, this allows us to be able to successfully parse and
normalize them. A future change will handle updating the individual
actions.

[^1]: c0192df630
2024-11-28 13:11:40 +09:00
Edward Thomson
c86842f0a5 Merge pull request #6938 from mathworks/lrm29-ssh-hostkey-check
ssh: Include rsa-sha2-256 and rsa-sha2-512 in the list of hostkey types
2024-11-26 22:32:07 +00:00
Edward Thomson
b8ad17faf5 Merge pull request #6949 from libgit2/ethomson/docs
Improve documentation and validate during CI
2024-11-26 22:14:51 +00:00
Edward Thomson
338ceb93b6 Improve documentation 2024-11-26 21:44:09 +00:00
Edward Thomson
5353a2cc20 reflog: remove unused sys functions
The `git_reflog_entry__alloc` function is not actually defined, nor
used. Remove references to it in the headers. It is not clear why the
corresponding `__free` is, or should be, exported. Make it internal to
the library.
2024-11-26 21:22:10 +00:00
Edward Thomson
8e516778ce Add CI step to validate documentation changes
Run our documentation generator in "validate only" mode to ensure that
new changes coming in to the repository have documented our changes
fully.
2024-11-26 21:22:10 +00:00
Edward Thomson
0bd5e479b2 Introduce a "validate only" mode for docs generation
The API documentation generation is useful (in `--strict` mode) to
determine whether all our APIs have sufficient documentation. Add a
`--validate-only` mode that will run the validation without emitting the
API JSON. This is useful for ensuring that the documentation is
complete.
2024-11-26 21:22:10 +00:00
Edward Thomson
e74b9c64a1 Merge pull request #6948 from libgit2/ethomson/docs-ci
Update documentation generation workflow
2024-11-26 20:24:01 +00:00
Edward Thomson
9321800612 Update documentation generation workflow
Ensure that workflows where the main branch exists (eg, anything except
PR workflows) don't try to recreate the main branch. Add a concurrency
token so that we don't have conflicts generating documentation.
2024-11-26 20:00:15 +00:00
Edward Thomson
07c77d497b Merge pull request #6945 from libgit2/ethomson/docs-ci
Include documentation generator
2024-11-25 23:00:49 +00:00
Edward Thomson
89cc5ef8e8 Include documentation generator
libgit2 has a new documentation generator that generates API schema from
our headers, then produces reference documentation that is included into
the website directly.
2024-11-25 23:00:07 +00:00
lmcglash
eb84531575 Clear data after negotiation 2024-11-25 21:55:43 +00:00
Edward Thomson
0a6051c624 Merge pull request #6927 from Caleb-T-Owens/merge-base-many-docs
Update documentation of `merge_base_many`
2024-11-24 22:30:22 +00:00
lmcglash
98fee5212f Cast size_t to int 2024-11-20 21:46:20 +00:00
lmcglash
6ee06ca737 Remove unnecessary comment. 2024-11-20 21:32:24 +00:00
lmcglash
27549bdcce object: core.abbrev accepts string values 2024-11-20 21:27:45 +00:00
Laurence McGlashan
728e63f092 ssh: Include rsa-sha2-256 and rsa-sha2-512 in the list of preferred hostkey types 2024-11-15 09:30:09 +00:00