Commit Graph

219 Commits

Author SHA1 Message Date
Prithvi Shahi
eada9891cc
Update README.md (#42) 2023-01-06 22:38:31 -08:00
web3-bot
00b60808a1
sync: update CI config files (#34) 2022-09-21 18:15:22 +00:00
libp2p-mgmt-read-write[bot]
176c5cdd28
chore: Update .github/workflows/stale.yml [skip ci] 2022-09-19 13:43:21 +00:00
Marten Seemann
6f749a6656
release v0.1.0 (#31) 2022-08-18 04:04:02 -07:00
Oleg Jukovec
46d44e1dfd
Fix build with OpenSSL 3.0 (#25)
* Fix build with OpenSSL 3.0

- FIPS_mode_set() does not exist in OpenSSL 3.0 [1]
- X509_check_* functions declarated in openssl/x509v3.h instead of openssl/x509.h [2]
- X509_chack_* functions have const char arg inserad of const unsigned char [2]
- skip MD4 tests if it is unsupported by OpenSSL
- the patch does not change behavior under OpenSSL version != 3
- the patch just fixes build under OpenSSL 3.0 and doesn't update deprecated code
or behavior

1. https://wiki.openssl.org/index.php/OpenSSL_3.0#Upgrading_from_the_OpenSSL_2.0_FIPS_Object_Module
2. https://www.openssl.org/docs/man3.0/man3/X509_check_host.html

* Add Ubuntu 22.04 runner to GitHub Actions go test workflow

* Fix flaky tests on Ubuntu 22.04

It is necessary to handle OpenSSL errors very carefully. Otherwise,
errors may appear in unexpected places. For example, we didn't catch
an error from EVP_DigestInit_ex() and it appears sometimes in conn.go:

func (c *Conn) getErrorHandler(rv C.int, errno error) func() error {
	errcode := C.SSL_get_error(c.ssl, rv) // <- here
2022-08-18 11:29:19 +03:00
Piotr Galar
d09e3c50a0
Merge pull request #24 from libp2p/web3-bot/sync
sync: update CI config files
2022-06-06 15:49:52 +02:00
galargh
32392545a8 chore: go fmt 2022-06-06 15:38:07 +02:00
galargh
0250c31eb1 Merge remote-tracking branch 'origin/master' into web3-bot/sync 2022-06-06 15:37:54 +02:00
Piotr Galar
53894525e5
Merge pull request #30 from libp2p/galargh-patch-2
Install mingw toolchain on windows machines for go test
2022-06-06 15:27:09 +02:00
Piotr Galar
8ff2bb06d5
Update action.yml 2022-06-06 15:15:38 +02:00
Piotr Galar
831aceee97
Update action.yml 2022-06-06 15:00:14 +02:00
Piotr Galar
7de17e1452
Update action.yml 2022-06-06 14:46:33 +02:00
Piotr Galar
54131cd06f
Update action.yml 2022-06-06 13:50:32 +02:00
Marco Munizaga
e25825bbd7
Merge pull request #26 from oleg-jukovec/openssl-dialtimeout-call
Add openssl.DialTimeout(network, addr, timeout, ctx, flags) call
2022-06-03 16:05:13 -07:00
Marco Munizaga
6a218fb8eb
Merge pull request #27 from oleg-jukovec/SSL_CTX_set_min_max_proto_version
Add Ctx.SetMinProtoVersion and Ctx.SetMaxProtoVersion wrappers
2022-06-03 15:18:42 -07:00
web3-bot
de18fa1620 update .github/workflows/go-check.yml 2022-06-01 08:57:20 +00:00
web3-bot
4939bdc0a5 update .github/workflows/go-test.yml 2022-06-01 08:57:20 +00:00
web3-bot
42190170f2 update .github/workflows/automerge.yml 2022-06-01 08:57:20 +00:00
web3-bot
8b7f1f93c7 bump go.mod to Go 1.17 and run go fix 2022-06-01 08:57:19 +00:00
Oleg Jukovec
2a664981b2 Add Ctx.SetMinProtoVersion and Ctx.SetMaxProtoVersion wrappers
- Ctx.SetMinProtoVersion wraps SSL_CTX_set_min_proto_version
- Ctx.SetMaxProtoVersion wraps SSL_CTX_set_max_proto_version
2022-04-15 12:58:08 +03:00
Oleg Jukovec
fa2d6fa67e Add openssl.DialTimeout(network, addr, timeout, ctx, flags) call
- this is an analog for net.DialTimeout call
- the timeout is only for net.Dial call
- the timeout does not include OpenSSL calls
2022-04-15 10:09:42 +03:00
Piotr Galar
0fadeb4d38
Merge pull request #17 from libp2p/web3-bot/sync
sync: update CI config files
2022-02-01 09:53:28 +01:00
Piotr Galar
1cac8defac
Merge pull request #20 from libp2p/web3-bot/sync-msys2
ci: add go-test-setup action
2022-02-01 09:44:24 +01:00
galargh
b84a4bc4e9 add go-test-setup action 2022-01-31 13:12:23 +01:00
galargh
77c1db38da update .github/workflows/go-test.yml 2022-01-31 13:12:13 +01:00
web3-bot
0e129fb7c4 add .github/workflows/tagpush.yml 2021-12-10 11:50:47 +00:00
web3-bot
e7bb135bd6 add .github/workflows/release-check.yml 2021-12-10 11:50:47 +00:00
web3-bot
4ce5b67757 add .github/workflows/releaser.yml 2021-12-10 11:50:47 +00:00
web3-bot
0ce1691392 add .github/workflows/go-check.yml 2021-12-10 11:50:47 +00:00
web3-bot
f0bfe9c369 add .github/workflows/go-test.yml 2021-12-10 11:50:47 +00:00
web3-bot
ed6a5ab6c1 add .github/workflows/automerge.yml 2021-12-10 11:50:47 +00:00
web3-bot
19eed5d76f run gofmt -s 2021-12-10 11:50:47 +00:00
web3-bot
55c3c00979 bump go.mod to Go 1.16 and run go fix 2021-12-10 11:50:44 +00:00
web3-bot
523a9c8afd add version.json file 2021-12-10 11:49:19 +00:00
Steven Allen
a04acfd1f4
Merge pull request #18 from libp2p/fix/pointer-passing
fix: unsafe pointer passing
2021-08-27 14:49:53 -07:00
Steven Allen
ecfa88cc5b fix: unsafe pointer passing
Use github.com/mattn/go-pointer to save/restore "pointers" across FFI
bounderies. Go reserves the right to move pointers, so using
`unsafe.Pointer` for this is not safe.
2021-08-27 10:46:42 -07:00
Marten Seemann
8e95e0f113
Merge pull request #15 from jbouwman/update-cert-md
Update test RSA cert
2021-08-27 17:33:36 +01:00
Steven Allen
cfeec8e4f5
Merge pull request #16 from libp2p/fix/tests
Fix tests
2021-08-27 09:17:34 -07:00
Steven Allen
d2721d9a71 test: handle closing quirks
Closing may need to write, which will cause it to fail if the other side
has already closed. The correct fix is to use shutdown to half-close,
then wait for the other side, but that's honestly not worth it right
now. So I just fixed the tests to pass.
2021-08-27 09:04:59 -07:00
Steven Allen
f5ecaf4460 test: don't try to marshal ed25519 to PEM 2021-08-27 08:39:08 -07:00
Jesse Bouwman
5bb7e0e4fa Update test RSA cert
Tests fail due to weak MD on self-signed RSA cert: update from SHA-1 to SHA-2
2021-08-14 11:27:17 -07:00
Steven Allen
219d074952
Merge pull request #14 from libp2p/fix-lint-issues-pre-ci
Address `staticcheck` issues
2021-07-19 21:35:46 -07:00
Masih H. Derkani
597b8983b0
Address staticcheck issues
Fix `staticcheck` issues:
- S1028 use `fmt.Errorf` to construct formatted errors
- ST1017 yoda conditions
- ST1005 error message capitalization
- ST1006 avoid `self` as receiver name
- S1030 use `buf.String`
- S1011 avoid redundant loop when `append` suffices
- SA4006 unused value
- S1019 remove redundant capacity on `make` call
- SA2002 `t.Fatal` called outside of test

Exported error violates ST1012, which is ignored by this PR since rename may cause breaking changes.

Remove redundant parentheses wrapping, and use CamelCase naming while at it.
2021-07-19 16:53:28 +01:00
Adin Schmahmann
6f65c2c3af
Merge pull request #11 from stephaneberle9/master
Enabled PEM files with CRLF line endings to be used (#10)
2020-10-16 13:09:40 -04:00
Stephan Eberle
6d00a81776 Enabled PEM files with CRLF line endings to be used (#10); made PEM file splitter tolerant of trailing whitespace in PEM block delimiter lines 2020-10-09 19:23:19 +02:00
Adin Schmahmann
d9b6402828
Merge pull request #7 from libp2p/refactor/ed25519-less-special
make ed25519 less special
2020-07-29 16:52:07 -04:00
Adin Schmahmann
f4030af720 refactor: make Ed25519 keys less special cased 2020-07-29 16:49:19 -04:00
Steven Allen
ab3d2c3342
Merge pull request #6 from balajijinnah/balaji/tls
Add required bindings to support openssl in libp2p-tls
2020-06-15 11:03:10 -07:00
Tiger
38a6bec6d1 fix comments
Signed-off-by: Tiger <rbalajis25@gmail.com>
2020-06-13 14:12:43 +05:30
Tiger
1fdf237b98 remove unwanted
Signed-off-by: Tiger <rbalajis25@gmail.com>
2020-05-23 17:28:22 +05:30