Commit 357650451183d04a5aacb03459e8dc5a5ebd2150
Fix serving URLs containing single-quotes
cel committed on 8/29/2018, 8:04:17 PMParent: 8909e72fe6179f29cca330d5163443a25931621c
Files changed
dat.dpi | changed |
dat.dpi | ||
---|---|---|
@@ -388,9 +388,9 @@ | ||
388 | 388 … | if (!this.authed) { |
389 | 389 … | console.error('[dat dpi] un-authed request from', this.getAddress()) |
390 | 390 … | return this.socket.end() |
391 | 391 … | } |
392 | - this.url = m[1] | |
392 … | + this.url = m[1].replace(/''/g, '\'') | |
393 | 393 … | if (this.url.startsWith('dat:')) return this.serveDat() |
394 | 394 … | if (this.url.startsWith('dpi:/dat/')) return this.serveInternal() |
395 | 395 … | this.serveError('Not found') |
396 | 396 … | } |
Built with git-ssb-web