Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
dms3
go-dms3
Commits
e980e68f
Commit
e980e68f
authored
Jan 30, 2018
by
Dirk McCormick
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Comment fixes
License: MIT Signed-off-by:
Dirk McCormick
<
dirkmdev@gmail.com
>
parent
dafa140e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
namesys/selector.go
namesys/selector.go
+2
-2
namesys/validator.go
namesys/validator.go
+1
-1
No files found.
namesys/selector.go
View file @
e980e68f
...
...
@@ -10,8 +10,8 @@ import (
proto
"gx/ipfs/QmZ4Qi3GaRbjcx28Sme5eMH7RQjGkt8wHxt2a65oLaeFEV/gogo-protobuf/proto"
)
// Select
s
best record by checking which has the highest
sequence number
// and latest EOL
//
Ipns
Select
orFunc selects the
best record by checking which has the highest
//
sequence number
and latest EOL
func
IpnsSelectorFunc
(
k
string
,
vals
[][]
byte
)
(
int
,
error
)
{
var
recs
[]
*
pb
.
IpnsEntry
for
_
,
v
:=
range
vals
{
...
...
namesys/validator.go
View file @
e980e68f
...
...
@@ -29,7 +29,7 @@ var ErrInvalidPath = errors.New("record path invalid")
// signature verification
var
ErrSignature
=
errors
.
New
(
"record signature verification failed"
)
//
R
eturns a ValidChecker for IPNS records
//
NewIpnsRecordValidator r
eturns a ValidChecker for IPNS records
// The validator function will get a public key from the KeyBook
// to verify the record's signature
func
NewIpnsRecordValidator
(
kbook
pstore
.
KeyBook
)
*
record
.
ValidChecker
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment