Commits

nass...@NASSEREB-PC.ultragenda.com  committed 117ec7f

BUGFIX:
Creating an Uri with authentication fails when username or password has special
chars like '@'

  • Participants
  • Parent commits e6f5df5

Comments (0)

Files changed (1)

File src/BitbucketBackup/RepositoryUpdater.cs

             this.localfolder = localFolder;
             this.config = config;
 
-            string uriWithAuth = repoUri.ToString().Replace("://", string.Format("://{0}:{1}@", config.UserName, config.PassWord));
+            string uriWithAuth = repoUri.ToString().Replace("://", string.Format("://{0}:{1}@", Uri.EscapeDataString(config.UserName), Uri.EscapeDataString(config.PassWord)));
             this.repouriwithauth = new Uri(uriWithAuth);
         }