[PD2] Relatorio inicio

Co-authored-by: tsousa111 <tiagao2001@hotmail.com>
This commit is contained in:
Afonso Franco 2024-05-31 23:14:06 +01:00
parent 6f8219d991
commit b86992a10a
Signed by: afonso
SSH key fingerprint: SHA256:PQTRDHPH3yALEGtHXnXBp3Orfcn21pK20t0tS1kHg54
10 changed files with 192 additions and 289 deletions

View file

@ -137,7 +137,7 @@ func Run() {
os.Exit(1)
}
err := registerUser(myUID, password, clientKeyStore)
err := registerUser(password, clientKeyStore)
if err != nil {
printError(err.Error())
os.Exit(1)
@ -188,8 +188,8 @@ func getHTTPClient(tlsConfig *tls.Config) *http.Client {
return &http.Client{Transport: transport}
}
func registerUser(userId string, password string, clientKeyStore cryptoUtils.KeyStore) error {
postRegister := protocol.NewPostRegister(userId, password, clientKeyStore.GetCert().Raw)
func registerUser(password string, clientKeyStore cryptoUtils.KeyStore) error {
postRegister := protocol.NewPostRegister(password, clientKeyStore.GetCert().Raw)
jsonData, err := json.Marshal(postRegister)
if err != nil {