Commit graph

12 commits

Author SHA1 Message Date
Lars Kiesow
4a125276b3
Restrict Library Paths
This patch introduces the new environment variable `MEDIA_BASE_PATH`
allowing to restrict the media paths that can be added to libraries and
therefore limiting which sections of the filesystem audiobookshelf will
scan and potentially serve to the web.

This means, you can, for example, specify that all media are in
`/audiobooks`, preventing users to access file system paths not starting
with this.

This also prevents things like users specifying `/` as a library path
which seems to be a good way for a denial of service attack right now.

The patch also adds the new environment variable to the example Docker
commands and docker-compose files, matching the media file specified in
those examples.
2023-01-16 22:15:07 +01:00
Lars Kiesow
128796bd36 Fix undefined string assignment
Assigning something to `process.env.profile`, Node stringifies the value. This
means that assigning `undefined` to an environment variable in Node will result
in it holding the string `undefined`.

This means, for example, that `module.exports.FFPROBE_PATH || 'ffprobe'` in
`server/libs/nodeFfprobe/index.js` will actually result in the string
`undefined`.

This patch fixes several such assignments in the `index.js`, potentially
causing problems in the development mode.
2022-12-26 23:55:14 +01:00
advplyr
10295b000a Update:Remove HOST default to allow for ipv6 #1256 2022-12-17 15:55:53 -06:00
advplyr
cd04533eea Update:Setting up paths to eventually support subdirectory 2022-10-01 16:07:30 -05:00
advplyr
9e7b84f289 Update:JWT signing 2022-07-18 17:19:16 -05:00
advplyr
c962090c3a Update:No longer creating initial root user and initial library, add init root user page, web app works with no libraries 2022-05-14 17:23:22 -05:00
Rasmus Krämer
2df5ab0dde Only fall back to the default secret when no is provided 2022-04-09 09:25:13 +02:00
advplyr
e36c31c5e7 Add HOST config for docker and debian 2022-03-17 08:18:39 -05:00
advplyr
712aad2f14 Fix:FFprobe requires path update config #302 2022-01-10 17:57:51 -06:00
advplyr
f752c19418 narrator filter, no series filter, full paths toggle, book landing page details, new sans font, update query string on filter/sort, persist experimental feature flag, batch edit redirect bug, upload file permissions and owner 2021-10-06 21:08:52 -05:00
Mark Cooper
e4dac5dd05 Adding download tab and download manager, ffmpeg in worker thread 2021-09-04 14:17:26 -05:00
Mark Cooper
a0c60a93ba Init 2021-08-17 17:01:11 -05:00