mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-07-30 04:23:11 +03:00
Updated attachments to not be saved with a complete extension
Intended to limit impact in the event the storage path is potentially exposed.
This commit is contained in:
@ -109,7 +109,8 @@ class AttachmentTest extends TestCase
|
||||
|
||||
$attachment = Attachment::query()->orderBy('id', 'desc')->first();
|
||||
$this->assertStringNotContainsString($fileName, $attachment->path);
|
||||
$this->assertStringEndsWith('.txt', $attachment->path);
|
||||
$this->assertStringEndsWith('-txt', $attachment->path);
|
||||
$this->deleteUploads();
|
||||
}
|
||||
|
||||
public function test_file_display_and_access()
|
||||
|
Reference in New Issue
Block a user