Skip to content

Commit 3d6993d

Browse files
authored
Merge pull request #20500 from cgranleese-r7/fixes-docker-invalid-uri-error
Fixes database name stripping
2 parents e0fec0e + 5a3195d commit 3d6993d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lib/msf/core/db_connector.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,7 @@ def self.db_parse_db_uri_postgresql(path)
247247
targ,name = dest.split('/')
248248
(name = targ and targ = nil) if not name
249249
res[:host],res[:port] = targ.split(':') if targ
250+
name = name&.split('?')&.first
250251
end
251252
res[:name] = name || 'metasploit3'
252253
res

0 commit comments

Comments
 (0)