Commit Graph

12197 Commits

Author SHA1 Message Date
Adin Schmahmann
5624e3f707 update bitswap 2021-02-04 11:39:45 -05:00
Adin Schmahmann
d5b59a8445 bigfilestore implements blockstore. bigfilestore moved to avoid import cycle and used in go-ipfs 2021-02-04 10:48:33 -05:00
Petar Maymounkov
58a062367e fix test 2021-02-04 06:03:56 -08:00
Petar Maymounkov
43764989cf make the link: put large files into the big file store on add 2021-02-03 21:46:33 -08:00
Petar Maymounkov
faf37c4f84 add a BigFileStore to the CoreAPI; still needs initialization logic of the big file store (now placeholder) 2021-02-03 20:31:09 -08:00
Adin Schmahmann
50166a586a bump bitswap dep 2021-02-03 21:07:46 -05:00
gammazero
4579f27dff save cid list to datastore 2021-02-03 17:36:43 -08:00
Petar Maymounkov
765e1739be refactor: pull StreamCid outside of ChunkingManifest; streamCid is orthogonal to the chunking manifest 2021-02-03 15:34:16 -08:00
Adin Schmahmann
cd8e37b393 update dep 2021-02-03 17:41:37 -05:00
Adin Schmahmann
6be999ea0a add largeblocks option to ipfs add. calculate streamCid for SHA2_256 2021-02-03 17:39:07 -05:00
Petar Maymounkov
f9f337de20 compute the chunking manifest of a file, on ipfs add; placeholder for inserting the file into a big file datastore 2021-02-02 21:33:40 -08:00
Adin Schmahmann
884a5aebd7 update distpath to version with fs-repo-migrations v1.7.1 2021-01-28 23:22:48 -05:00
Adin Schmahmann
8ed9ffd3a6
Merge pull request #7862 from ipfs/dependabot/go_modules/github.com/stretchr/testify-1.7.0
chore(deps): bump github.com/stretchr/testify from 1.6.1 to 1.7.0
2021-01-28 19:07:00 -05:00
Adin Schmahmann
e5bf4e6c6b
Merge pull request #7861 from ipfs/dependabot/go_modules/github.com/gogo/protobuf-1.3.2
chore(deps): bump github.com/gogo/protobuf from 1.3.1 to 1.3.2
2021-01-28 18:59:33 -05:00
Petar Maymounkov
8794928c31
add remote pinning policy for mfs (#7798)
* remote pinning service MFS policy
* update go-ipfs-config
* hardening secret sanitization in `ipfs config` commands

Co-authored-by: Adin Schmahmann <adin.schmahmann@gmail.com>
Co-authored-by: Marcin Rataj <lidel@lidel.org>
2021-01-28 18:58:44 -05:00
dependabot-preview[bot]
a2f960c12e chore(deps): bump github.com/stretchr/testify from 1.6.1 to 1.7.0
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.6.1 to 1.7.0.
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](https://github.com/stretchr/testify/compare/v1.6.1...v1.7.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-01-28 18:22:00 -05:00
Adin Schmahmann
ae00327c44
Merge pull request #7885 from ipfs/dependabot/go_modules/github.com/ipfs/go-graphsync-0.6.0
chore(deps): bump github.com/ipfs/go-graphsync from 0.5.2 to 0.6.0
2021-01-28 18:17:57 -05:00
dependabot-preview[bot]
eb894dca7b chore(deps): bump github.com/gogo/protobuf from 1.3.1 to 1.3.2
Bumps [github.com/gogo/protobuf](https://github.com/gogo/protobuf) from 1.3.1 to 1.3.2.
- [Release notes](https://github.com/gogo/protobuf/releases)
- [Commits](https://github.com/gogo/protobuf/compare/v1.3.1...v1.3.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-01-28 18:14:16 -05:00
dependabot-preview[bot]
50f066f05e chore(deps): bump github.com/ipfs/go-graphsync from 0.5.2 to 0.6.0
Bumps [github.com/ipfs/go-graphsync](https://github.com/ipfs/go-graphsync) from 0.5.2 to 0.6.0.
- [Release notes](https://github.com/ipfs/go-graphsync/releases)
- [Changelog](https://github.com/ipfs/go-graphsync/blob/master/CHANGELOG.md)
- [Commits](https://github.com/ipfs/go-graphsync/compare/v0.5.2...v0.6.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-01-28 15:33:05 -05:00
@RubenKelevra
dd295e4560
show the domain name with the error (#7886)
* show the domain name if DNSLink failed to resolve a domain because it wasn't a valid domain name

Original author: @AluisioASG
2021-01-28 15:22:36 -05:00
Andrew Gillis
6f6f04543b
Improve error message when running key command that locks repo (#7821)
* Improve error message when running key commands that must be run when the daemon is not already running

Fixes Issue #7814

`ipfs key export` now does a PreRun check like `ipfs key rotate` was to give a better error to the user then "someone else has the lock" in the event that the daemon is running while trying to execute these offline-only commands.

While unlikely the "someone else has the lock" error can still be shown if two processes try and grab the repo lock at the same time.

This PreRun function is also exported so it can be used by `ipfs init` where it was originally copied from.

* Added more `ipfs key` command tests

When daemon is running:
- Test that import works
- Test that export fails
- Test that rotate fails
2021-01-28 15:15:49 -05:00
Adin Schmahmann
3e7a105676
Merge pull request #7887 from ipfs/docs/clarify-repeated-options
docs: comma delimited options in pin remote --help
2021-01-28 13:31:24 -05:00
Marcin Rataj
3bca93787a
docs: comma delimited options in pin remote --help
This adds clarification suggested in
https://github.com/ipfs/go-ipfs/pull/7823#pullrequestreview-577889138
2021-01-28 17:23:46 +01:00
Adin Schmahmann
89ef0d1956
Merge pull request #7828 from ipfs/fix/normalize-service-endpoint
fix: normalize remote service endpoint
2021-01-28 11:17:40 -05:00
Adin Schmahmann
61f3a2f3a2 fix: restrict remote pinning service endpoint URIs to HTTP/HTTPS 2021-01-27 19:28:58 -05:00
Adin Schmahmann
e0d484431a test: add sharness tests for remote pinning service endpoints that are not http(s) URIs 2021-01-27 19:28:58 -05:00
Marcin Rataj
fc4095cfb3 refactor: url → endpoint
https://github.com/ipfs/go-ipfs/pull/7828#discussion_r543520089
2021-01-27 19:28:58 -05:00
Marcin Rataj
7313a45bc7 fix: url.RawFragment does not work in go1.14
I don't think we need to worry about #hash, so just removed it
2021-01-27 19:28:58 -05:00
Marcin Rataj
6851ede8eb refactor: normalization with path.Clean 2021-01-27 19:28:58 -05:00
Marcin Rataj
5f692a76de fix: normalize remote service endpoint
Closes #7826
2021-01-27 19:28:54 -05:00
Adin Schmahmann
c23ea34652
Merge pull request #7823 from ipfs/docs/pin-remote-cli
docs: improved --help for pin remote commands
2021-01-27 19:24:25 -05:00
Marcin Rataj
0b6912e3b3 refactor: cleanup arg params 2021-01-27 23:55:09 +01:00
Marcin Rataj
1cb90d7109 docs: pin remote readability
Co-authored-by: Jessica Schilling <jessica@protocol.ai>
2021-01-27 23:55:07 +01:00
Marcin Rataj
3b82dd8e55 docs: CLI docs for pin remote commands
This adds docs in form of longer description that is displayed
when --help is passes on the CLI.

While at it, unified some language to match fields in the config file
and other places + included some tips and best practices which should
improve onboarding experience.
2021-01-27 23:53:41 +01:00
Adin Schmahmann
b0ff6dbd41
Merge pull request #7859 from ipfs/dependabot/go_modules/github.com/libp2p/go-libp2p-pubsub-0.4.1
chore(deps): bump github.com/libp2p/go-libp2p-pubsub from 0.4.0 to 0.4.1
2021-01-27 15:49:54 -05:00
Adin Schmahmann
8f3ae679ba
Merge pull request #7884 from ipfs/chore/update-pinner-dep
chore: update go-ipfs-pinner dep
2021-01-27 15:49:10 -05:00
gammazero
d2442956a4 Update deps to latest pinner 2021-01-27 11:57:01 -08:00
dependabot-preview[bot]
1e260f2f9d chore(deps): bump github.com/libp2p/go-libp2p-pubsub from 0.4.0 to 0.4.1
Bumps [github.com/libp2p/go-libp2p-pubsub](https://github.com/libp2p/go-libp2p-pubsub) from 0.4.0 to 0.4.1.
- [Release notes](https://github.com/libp2p/go-libp2p-pubsub/releases)
- [Commits](https://github.com/libp2p/go-libp2p-pubsub/compare/v0.4.0...v0.4.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-01-27 14:51:25 -05:00
Adin Schmahmann
b9b15feebf
Merge pull request #7822 from ipfs/dependabot/go_modules/github.com/ipfs/go-graphsync-0.5.2
chore(deps): bump github.com/ipfs/go-graphsync from 0.5.1 to 0.5.2
2021-01-27 12:43:22 -05:00
Adin Schmahmann
98eb7328cc
Merge pull request #7863 from ipfs/feat/stringsOptionDelim
pin remote commands are comma delimited on the CLI only
2021-01-27 12:42:13 -05:00
Adin Schmahmann
a95a86ed54 feat: ipfs pin remote ls commands are comma delimited on the CLI only 2021-01-27 12:07:44 -05:00
Adin Schmahmann
7588a6a52a
Merge pull request #7829 from ipfs/fix/pin-remote-service-ls-json
fix: remote services ls always return a list
2021-01-14 17:37:40 -05:00
Adin Schmahmann
651e3ccafd
Merge pull request #7807 from ipfs/fix/broken-cidv0-ux
fix: improved error message on broken CIDv0
2021-01-14 15:31:39 -05:00
Adin Schmahmann
b5079b03cd
Merge pull request #7802 from dennis-tra/issue-7686
feat(gw): URI router for Web API navigator.registerProtocolHandler
2021-01-14 15:25:22 -05:00
Marcin Rataj
216b858f8a
test: JSON response on empty remote service ls 2021-01-14 21:07:23 +01:00
Marcin Rataj
a0f90d3a14 test: cover 2 remaining lines 2021-01-14 20:53:20 +01:00
Marcin Rataj
cdad39479c test: sharness for ?uri= router
Additional tests to ensure there are no regressions, as this will be
used by browser vendors in the future.
2021-01-14 20:53:17 +01:00
Marcin Rataj
abb25a1cfc refactor: remove redundant urlescape
URL.Query() will already decode the query parameters
2021-01-14 20:52:04 +01:00
Marcin Rataj
3de5b14e0c fix: ?uri= url-decode and preserve query
This makes ?uri= param able to process URIs passed by web browsers
https://developer.mozilla.org/en-US/docs/Web/API/Navigator/registerProtocolHandler
2021-01-14 20:52:04 +01:00
Dennis Trautwein
36368ee4dd feat: support requests from registerProtocolHandler
This commit adds support for requests produced by navigator.registerProtocolHandler on gateways. Now one can register `dweb.link` as an URI handler for `ipfs://`:

```
navigator.registerProtocolHandler('ipfs', 'https://dweb.link/ipfs/?uri=%s', 'ipfs resolver')
```

Then opening `ipfs://QmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR` will produce an HTTP GET call to:

```
https://dweb.link/ipfs?uri=ipfs%3A%2F%2FQmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR
```

The query parameter `uri` will now be parsed and the given content identifier resolved via:

`https://dweb.link/ipfs/QmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR`
2021-01-14 20:52:04 +01:00