1
0
mirror of https://github.com/ipfs/kubo.git synced 2025-12-19 01:30:17 +08:00
Commit Graph

103 Commits

Author SHA1 Message Date
Jorropo
40d7f2fecc chore: bump go-libipfs v0.6.1
This does nothing, just move from an untagged commit to a tagged commit but contain the same things.
2023-03-08 12:00:58 +01:00
Jorropo
fea25f7ab1 chore: update golang.org/x/net to v0.7.0
Include fix for https://pkg.go.dev/vuln/GO-2023-1571 (this impact us in the DOH handler).
2023-03-03 12:54:20 +01:00
Jorropo
23379d8d60 chore: update go-unixfs v0.4.4
Include missing error handling.
2023-03-03 12:54:20 +01:00
Marten Seemann
68f4dd4427 chore: update go-libp2p to v0.26.2 2023-03-02 08:48:23 +01:00
Marten Seemann
56b9962103 chore: update go-libp2p to v0.26.1 2023-02-28 02:48:17 +01:00
Henrique Dias
1794649bf2 feat(gateway): error handling improvements (500, 502, 504) (#9660)
* fix(gateway): return 500 for all /ip[nf]s/id failures
* fix: replace deprecated structs
* chore: bump go-libipfs to version from main
2023-02-28 02:21:50 +01:00
Henrique Dias
4283b9d98f chore: bump go-libp2p-kad-dht to v0.21.1 (#9663) 2023-02-24 11:49:31 +01:00
Marten Seemann
a3366c522a chore: update go-libp2p to v0.26 (#9656)
Co-authored-by: Henrique Dias <hacdias@gmail.com>
2023-02-24 10:34:10 +01:00
Jorropo
f73cd19220 chore: bump go-unixfs to v0.4.3 (#9643)
Co-authored-by: Henrique Dias <hacdias@gmail.com>
2023-02-23 09:17:01 +01:00
Michael Muré
86da181f7f feat(pinning): connect some missing go context (#9557)
Co-authored-by: Henrique Dias <hacdias@gmail.com>
2023-02-22 16:56:59 +01:00
Henrique Dias
4db6ae1772 fix(gateway): return HTTP 500 on ErrResolveFailed (#9589) 2023-02-22 03:22:03 +01:00
Jorropo
19feb15833 chore: bump go-libipfs v0.6.0 2023-02-17 22:23:47 +01:00
Jorropo
0ff406170d fix: update rcmgr for go-libp2p v0.25 2023-02-14 22:19:46 +01:00
Jorropo
82ede56636 chore: bump go-libp2p-routing-helpers to v0.6.1
This include a fix where FindProvidersAsync with the parallel composer would not close the channel ASAP when the count was reached, this save finality time when count is reached.
2023-02-09 19:37:56 +01:00
Henrique Dias
af0fe194f5 chore: update iface with routing tests 2023-02-09 14:35:54 +01:00
Henrique Dias
799e5ac0a5 chore: update go-libipfs for more gateway metrics (#9626) 2023-02-08 04:21:06 +01:00
Henrique Dias
b58356939e refactor(gw): move Host (DNSLink and subdomain) handling to go-libipfs (#9624)
Co-authored-by: Marcin Rataj <lidel@lidel.org>
2023-02-07 03:44:24 +01:00
Henrique Dias
14649aa8ba refactor: new go-libipfs/gateway API, deprecate Gateway.Writable (#9616) 2023-02-02 02:50:46 +01:00
Henrique Dias
8d3b3154c9 refactor: use gateway from go-libipfs (#9588) 2023-01-31 11:02:31 +01:00
Jorropo
b3c98bb085 chore: bump go-libipfs remove go-bitswap 2023-01-27 23:07:01 +01:00
Henrique Dias
a3c70a11e6 feat(gateway): IPNS record response format (IPIP-351) (#9399)
* feat(gateway): IPNS record response format
* docs(rpc): mark as experimental: routing provide, get, put

Co-authored-by: Marcin Rataj <lidel@lidel.org>
2023-01-27 04:46:50 +01:00
Henrique Dias
94e7f79805 fix(ipns): honour --ttl flag in 'ipfs name publish' (#9471)
* fix: honour --ttl flag in 'ipfs name publish'
* docs(cli): ipfs name inspect --help

Co-authored-by: Marcin Rataj <lidel@lidel.org>
2023-01-27 02:33:13 +01:00
Mohsin Zaidi
9652f24f6c feat: Pubsub.SeenMessagesStrategy (#9543)
* feat: expire messages from the cache based on last seen time
* docs: Pubsub.SeenMessagesStrategy

Ref. https://github.com/libp2p/go-libp2p-pubsub/pull/513

Co-authored-by: Marcin Rataj <lidel@lidel.org>
2023-01-27 00:24:35 +01:00
Jorropo
f20c980f2d chore: bump go-libipfs to replace go-block-format
Includes changes from:
- https://github.com/ipfs/go-block-format/pull/37
- https://github.com/ipfs/go-libipfs/pull/58
2023-01-26 16:55:48 +01:00
Marcin Rataj
1fa3a789d4 fix: User-Agent sent to HTTP routers
See https://github.com/ipfs/go-libipfs/issues/17
and https://github.com/ipfs/go-libipfs/pull/31
2023-01-19 00:49:46 +01:00
Henrique Dias
255e64e49e chore: migrate from go-ipfs-files to go-libipfs/files (#9535) 2023-01-13 14:27:03 +01:00
Antonio Navarro Perez
3bc9b675a0 fix: stats dht command when Routing.Type=auto (#9538)
Fixes default auto mode, but Routing.Type=custom needs more work.
Continued in https://github.com/ipfs/kubo/issues/9482
2023-01-13 00:38:38 +01:00
Antonio Navarro Perez
8cdc86d8c4 fix: disable provide over HTTP with Routing.Type=auto (#9511)
Closes https://github.com/ipfs/kubo/issues/9504
2023-01-04 13:56:15 +01:00
Marten Seemann
d6921c6d03 fix: update go-libp2p to v0.24.2 (#9522)
https://github.com/libp2p/go-libp2p/releases/tag/v0.24.2
2023-01-02 13:53:58 +01:00
Henrique Dias
7bdb341132 feat: fast directory listings with DAG Size column (#9481)
Co-authored-by: Marcin Rataj <lidel@lidel.org>
2022-12-12 21:45:13 +01:00
Marcin Rataj
3a3a97100c feat: go-libp2p-kad-dht with expiration 48h
https://github.com/libp2p/go-libp2p-kad-dht/releases/tag/v0.20.0
(cherry picked from commit f31d524d14)
2022-12-12 03:47:17 +01:00
Jorropo
deacafd178 chore: update go-libp2p to v0.24.1 2022-12-12 03:47:17 +01:00
Jorropo
f08b439d48 update go-libp2p to v0.24.0 2022-12-12 03:47:17 +01:00
Gus Eggert
5e5d15ae1e chore: upgrade libipfs for routing HTTP API schema changes (#9477) 2022-12-07 17:34:00 -05:00
Antonio Navarro Perez
3185dee22a Update libipfs dependency. 2022-12-07 16:34:59 +01:00
Antonio Navarro Perez
f0d720cd55 Update go-libipfs dep
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2022-12-07 16:34:59 +01:00
Antonio Navarro Perez
df828c0a47 feature: delegated-routing: Add HTTP delegated routing.
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2022-12-07 16:34:59 +01:00
Gus Eggert
b9a4d4592d chore: migrate ipfs/tar-utils to libipfs 2022-12-05 21:28:30 -05:00
Jorropo
4d4841f41c Merge pull request #9318 from ipfs/rvagg/go-merkledag-0.8 2022-12-05 15:15:12 +01:00
Antonio Navarro Perez
5283c6f8b5 chore: Update go-routing-helpers dependency
It will avoid a deadlock when using parallel router to compose routers.

Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2022-12-02 13:42:28 -05:00
Rod Vagg
7d0ea08289 deps: go-merkledag@v0.8.1 2022-12-02 10:16:15 +11:00
Mohsin Zaidi
51f60ea05a feat(config): Pubsub.SeenMessagesTTL (#9372)
Co-authored-by: Marcin Rataj <lidel@lidel.org>
2022-11-29 00:05:44 +01:00
Antonio Navarro Perez
6f5e226de6 fix: update go-unixfs lib to v0.4.1
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2022-11-15 21:51:43 +01:00
Antonio Navarro Perez
9da7f3a02d Update to v0.23.4
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2022-11-10 10:49:08 -05:00
Antonio Navarro Perez
3550758035 chore: Update go-libp2p to v0.23.3
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2022-11-10 10:48:07 -05:00
Antonio Navarro Perez
254d81a9d5 feat: Improve ResourceManager UX (#9338)
This PR adds several new functionalities to make easier the usage of ResourceManager:

- Now resource manager logs when resources are exceeded are on ERROR instead of warning.
- The resources exceeded error now shows what kind of limit was reached and the scope.
- When there was no limit exceeded, we print a message for the user saying that limits are not exceeded anymore.
- Added `swarm limit all` command to show all set limits with the same format as `swarm stats all`
- Added `min-used-limit-perc` option to `swarm stats all` to only show stats that are above a specific percentage
- Simplify a lot default values.
- **Enable ResourceManager by default.**

Output example:
```
2022-11-09T10:51:40.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:51:50.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 483095 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:51:50.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:52:00.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 455294 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:52:00.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:52:10.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 471384 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:52:10.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:52:20.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 8 times with error "peer:12D3KooWKqcaBtcmZKLKCCoDPBuA6AXGJMNrLQUPPMsA5Q6D1eG6: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:52:20.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 192 times with error "peer:12D3KooWPjetWPGQUih9LZTGHdyAM9fKaXtUxDyBhA93E3JAWCXj: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:52:20.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 469746 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:52:20.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:52:30.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 484137 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:52:30.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 29 times with error "peer:12D3KooWPjetWPGQUih9LZTGHdyAM9fKaXtUxDyBhA93E3JAWCXj: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:52:30.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:52:40.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 468843 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:52:40.566+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:52:50.566+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 366638 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:52:50.566+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:53:00.566+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 405526 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:53:00.566+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 107 times with error "peer:12D3KooWQZQCwevTDGhkE9iGYk5sBzWRDUSX68oyrcfM9tXyrs2Q: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:53:00.566+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:53:10.566+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 336923 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:53:10.566+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:53:20.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:55      Resource limits were exceeded 71 times with error "transient: cannot reserve inbound stream: resource limit exceeded".
2022-11-09T10:53:20.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:59      Consider inspecting logs and raising the resource manager limits. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgr
2022-11-09T10:53:30.565+0100    ERROR   resourcemanager libp2p/rcmgr_logging.go:64      Resrouce limits are no longer being exceeded.

```
## Validation tests

- Accelerated DHT client runs with no errors when ResourceManager is active. No problems were observed.
- Running an attack with 200 connections and 1M streams using yamux protocol. Node was usable during the attack. With ResourceManager deactivated, the node was killed by the OS because of the amount of memory consumed.
	- Actions done when the attack was active:
		- Add files 
		- Force a reprovide
		- Use the gateway to resolve an IPNS address.

It closes #9001 
It closes #9351
It closes #9322
2022-11-10 12:25:57 +01:00
Henrique Dias
a210abd743 feat(gateway): TAR response format (#9029)
Implementation of IPIP-288 (https://github.com/ipfs/specs/pull/288)

Co-authored-by: Marcin Rataj <lidel@lidel.org>
2022-11-09 19:20:33 +01:00
Marcin Rataj
d69f7a5ac9 chore: go-multicodec v0.7.0
https://github.com/multiformats/go-multicodec/releases/tag/v0.7.0
2022-11-08 18:33:36 +01:00
Gus Eggert
8c72ea909a feat: add delegated routing metrics (#9354) 2022-10-19 09:50:30 -04:00
Rod Vagg
9e3745ebeb deps: upgrade go-ipld-prime to v0.19.0
Ref: https://github.com/ipld/go-ipld-prime/releases/tag/v0.19.0
2022-10-14 05:23:43 +02:00