mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2026-04-26 01:26:00 +03:00
[GH-ISSUE #1326] Question: BASE URL environment variable on docker image #3834
Labels
No labels
expected: maybe someday
expected: next release
expected: release after next
expected: unlikely unless contributed
good first ticket
help wanted
pull-request
scope: all users
scope: windows users
size: easy
size: hard
size: medium
size: medium
status: backlog
status: blocked
status: done
status: idea-phase
status: needs followup
status: wip
status: wontfix
touches: API/CLI/Spec
touches: configuration
touches: data/schema/architecture
touches: dependencies/packaging
touches: docs
touches: js
touches: views/replayers/html/css
why: correctness
why: functionality
why: performance
why: security
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ArchiveBox#3834
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @tomasvanagas on GitHub (Jan 17, 2024).
Original GitHub issue: https://github.com/ArchiveBox/ArchiveBox/issues/1326
Hello, I am trying to run archivebox docker container with the base url (For example "domain.com/archivebox") but I can't find how.
Does archivebox have this functionality? If not perhaps you have any experience on how this could be achieved?
Thank you
@pirate commented on GitHub (Jan 17, 2024):
Unfortunately it's not allowed for security reasons: https://github.com/ArchiveBox/ArchiveBox/issues/724#issuecomment-1448573113
Archived JS can access your cookies and anything else hosted on the same domain, so to limit the potential impact it should always be hosted on a separate subdomain or port. You can then serve a redirect from
302 domain.com/archivebox -> archivebox.domain.com.It's the same reason why user-uploaded content is stored on
xxx.googleusercontent.cominstead ofgoogle.com, orraw.githubusercontent.cominstead ofgithub.com, most big companies don't keep arbitrary untrusted web content on the same domain (even subdomain) as trusted application code. https://security.googleblog.com/2012/08/content-hosting-for-modern-web.html(and any other archiving tool that offers this feature should also be scrutinized to make sure they handle this security risk properly, I only know of one or two that do)
@tomasvanagas commented on GitHub (Jan 17, 2024):
Thank you for a quick reply, haven't thought about this