diff options
| author | totegamma <github@gammalab.net> | 2023-04-06 08:37:18 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-04-06 08:37:18 +0900 |
| commit | 9629929977d1da84b1ce65a5915ed0aa6371b490 (patch) | |
| tree | d8bbaaa0cfa3a7fbcaaf7e24eaaf0127d064b602 /packages/backend/src/queue | |
| parent | refactor(fronted): setup syntax to menubar of Classic UI (#10474) (diff) | |
| download | sharkey-9629929977d1da84b1ce65a5915ed0aa6371b490.tar.gz sharkey-9629929977d1da84b1ce65a5915ed0aa6371b490.tar.bz2 sharkey-9629929977d1da84b1ce65a5915ed0aa6371b490.zip | |
fix misskey-dev/misskey-#10417 (#10418)
Diffstat (limited to 'packages/backend/src/queue')
| -rw-r--r-- | packages/backend/src/queue/processors/ImportCustomEmojisProcessorService.ts | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/packages/backend/src/queue/processors/ImportCustomEmojisProcessorService.ts b/packages/backend/src/queue/processors/ImportCustomEmojisProcessorService.ts index ed96e9a525..cf78d8330c 100644 --- a/packages/backend/src/queue/processors/ImportCustomEmojisProcessorService.ts +++ b/packages/backend/src/queue/processors/ImportCustomEmojisProcessorService.ts @@ -86,6 +86,10 @@ export class ImportCustomEmojisProcessorService { continue; } const emojiInfo = record.emoji; + if (!/^[a-zA-Z0-9_]+$/.test(emojiInfo.name)) { + this.logger.error(`invalid emojiname: ${emojiInfo.name}`); + continue; + } const emojiPath = outputPath + '/' + record.fileName; await this.emojisRepository.delete({ name: emojiInfo.name, |