mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-11-09 00:40:11 +01:00
Don't try and parse username/password out of repo address except for svn
This commit is contained in:
parent
381bbb60ac
commit
8f8360fcf6
@ -53,8 +53,9 @@ class vcs:
|
|||||||
self.sdk_path = sdk_path
|
self.sdk_path = sdk_path
|
||||||
|
|
||||||
# It's possible to sneak a username and password in with
|
# It's possible to sneak a username and password in with
|
||||||
# the remote address... (this really only applies to svn
|
# the remote address for svn...
|
||||||
# and we should probably be more specific!)
|
self.username = None
|
||||||
|
if self.repotype() == 'svn':
|
||||||
index = remote.find('@')
|
index = remote.find('@')
|
||||||
if index != -1:
|
if index != -1:
|
||||||
self.username = remote[:index]
|
self.username = remote[:index]
|
||||||
@ -64,8 +65,6 @@ class vcs:
|
|||||||
raise VCSException("Password required with username")
|
raise VCSException("Password required with username")
|
||||||
self.password = self.username[index+1:]
|
self.password = self.username[index+1:]
|
||||||
self.username = self.username[:index]
|
self.username = self.username[:index]
|
||||||
else:
|
|
||||||
self.username = None
|
|
||||||
|
|
||||||
self.remote = remote
|
self.remote = remote
|
||||||
self.local = local
|
self.local = local
|
||||||
|
Loading…
Reference in New Issue
Block a user