mirror of
https://github.com/HeyPuter/puter.git
synced 2026-08-22 22:17:01 +00:00
security: address 7018641
This commit is contained in:
@@ -295,6 +295,7 @@ class PuterHomepageService extends BaseService {
|
||||
};
|
||||
|
||||
generate_error_html ({ message }) {
|
||||
const { encode } = require('html-entities');
|
||||
return `
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
@@ -320,7 +321,9 @@ class PuterHomepageService extends BaseService {
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<h1>${message}</h1>
|
||||
<h1>${
|
||||
encode(message, { mode: 'nonAsciiPrintable' })
|
||||
}</h1>
|
||||
</body>
|
||||
</html>
|
||||
`;
|
||||
|
||||
Reference in New Issue
Block a user