Skip to content

Commit

Permalink
Bump NetVersionNum
Browse files Browse the repository at this point in the history
Signed-off-by: Yilun <[email protected]>
  • Loading branch information
yilunzhang committed Mar 3, 2023
1 parent 96826ae commit 19bb78a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
7 changes: 1 addition & 6 deletions api/websocket/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,6 @@ func (ws *WsServer) registryMethod() {
return api.RespPacking(nil, errcode.INVALID_PARAMS)
}

// TODO: use signature (or better, with one-time challenge) to verify identity

localNode := s.GetNetNode()

isTlsClient := cmd["IsTls"].(bool)
Expand Down Expand Up @@ -231,13 +229,10 @@ func (ws *WsServer) registryMethod() {
time.Sleep(3 * time.Second) // sleep several second, let response reach client
ws.SessionList.CloseSession(sess) // close this session
}()

return api.RespPacking(nil, errcode.INVALID_SIGNATURE)
} else {
log.Infof("client auth pass")
}
} else {
log.Infof("client doesn't send signature, it should be old version sdk")
log.Debugf("client didn't send signature")
}

newSessionID := hex.EncodeToString(clientID)
Expand Down
4 changes: 2 additions & 2 deletions cmd/nknd/commands/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import (
"encoding/json"
"errors"
"fmt"
"github.com/nknorg/nkn/v2/pb"
"io"
"math"
"math/rand"
Expand All @@ -32,6 +31,7 @@ import (
"github.com/nknorg/nkn/v2/dashboard"
serviceConfig "github.com/nknorg/nkn/v2/dashboard/config"
"github.com/nknorg/nkn/v2/lnode"
"github.com/nknorg/nkn/v2/pb"
"github.com/nknorg/nkn/v2/por"
"github.com/nknorg/nkn/v2/transaction"
"github.com/nknorg/nkn/v2/util"
Expand All @@ -47,7 +47,7 @@ import (
)

const (
NetVersionNum = 30 // This is temporary and will be removed soon after mainnet is stabilized
NetVersionNum = 31 // This is temporary and will be removed soon after mainnet is stabilized
)

// rootCmd represents the base command when called without any subcommands
Expand Down

0 comments on commit 19bb78a

Please sign in to comment.