Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
client
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
elixxir
client
Commits
03b3a596
Commit
03b3a596
authored
Jul 19, 2019
by
Benjamin Wenger
Browse files
Options
Downloads
Plain Diff
Merge remote-tracking branch 'origin/dispatch' into dispatch
# Conflicts: # cmd/root.go
parents
9c1f5a91
cb8b03d7
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.md
+1
-1
1 addition, 1 deletion
README.md
cmd/root.go
+12
-17
12 additions, 17 deletions
cmd/root.go
with
13 additions
and
18 deletions
README.md
+
1
−
1
View file @
03b3a596
...
...
@@ -59,7 +59,7 @@ Optional args:
|--nick| |Nickname to register for User Discovery (default "Default")||
|--ndfPubKey|-p|Path to the public key for the network definition JSON file|
|--ndf|-n|Path to the network definition JSON file|
|--
ndfVerifySignature
| |Specifies if the NDF should be loaded without the signature
.
default
s to true
|
|--
skipNDFVerification
| |Specifies if the NDF should be loaded without the signature
(
default
false)
|
|--ndfRegistration| |Overwrite the Registration values for the NDF|
|--ndfUDB| |Overwrite the UDB values for the NDF|
...
...
...
...
This diff is collapsed.
Click to expand it.
cmd/root.go
+
12
−
17
View file @
03b3a596
...
...
@@ -52,7 +52,7 @@ var userNick string
var
end2end
bool
var
keyParams
[]
string
var
ndfPath
string
var
ndfVerifySignature
bool
var
skipNDFVerification
bool
var
ndfRegistration
[]
string
var
ndfUDB
[]
string
var
ndfPubKey
string
...
...
@@ -80,7 +80,7 @@ func sessionInitialization() (*id.User, *api.Client) {
}
// Check if the NDF verify flag is set
if
!
ndfVerifySignature
{
if
skipNDFVerification
{
ndfPubKey
=
""
globals
.
Log
.
WARN
.
Println
(
"Skipping NDF verification"
)
}
else
if
ndfPubKey
==
""
{
...
...
@@ -134,18 +134,13 @@ func sessionInitialization() (*id.User, *api.Client) {
client
.
SetRateLimiting
(
rateLimiting
)
// Handle parsing gateway addresses from the config file
gateways
:=
viper
.
GetStringSlice
(
"gateways"
)
if
len
(
gwAddresses
)
<
1
{
gateways
:=
ndfJSON
.
Gateways
// If gwAddr was not passed via command line, check config file
if
len
(
gateways
)
<
1
{
// No gateways in config file or passed via command line
globals
.
Log
.
ERROR
.
Printf
(
"Error: No gateway specified! Add to"
+
" configuration file or pass via command line using -g!
\n
"
)
return
id
.
ZeroID
,
nil
}
else
{
// List of gateways found in config file
gwAddresses
=
gateways
}
}
// Connect to gateways and reg server
...
...
@@ -539,9 +534,9 @@ func init() {
"ndf.json"
,
"Path to the network definition JSON file"
)
rootCmd
.
PersistentFlags
()
.
BoolVar
(
&
ndfVerifySignature
,
"
ndfVerifySignature
"
,
tru
e
,
rootCmd
.
PersistentFlags
()
.
BoolVar
(
&
skipNDFVerification
,
"
skipNDFVerification
"
,
fals
e
,
"Specifies if the NDF should be loaded without the signature"
)
rootCmd
.
PersistentFlags
()
.
StringSliceVar
(
&
ndfRegistration
,
...
...
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
sign in
to comment