chore: fix some security issues in markdown (#20639)
This commit is contained in:
3
web/app/components/base/markdown-blocks/utils.ts
Normal file
3
web/app/components/base/markdown-blocks/utils.ts
Normal file
@@ -0,0 +1,3 @@
|
||||
export const isValidUrl = (url: string): boolean => {
|
||||
return ['http:', 'https:', '//', 'mailto:'].some(prefix => url.startsWith(prefix))
|
||||
}
|
||||
Reference in New Issue
Block a user