Skip to content

Node.js based forum software built for the modern web

fix: reverse tabnabbing exploit in post images

Julian Lam040e6a9a4c43
diff --git a/public/src/client/topic/images.js b/public/src/client/topic/images.js
index 3be0303e43..c1dc5866db 100644
--- a/public/src/client/topic/images.js
+++ b/public/src/client/topic/images.js
@@ -25,7 +25,7 @@ define('forum/topic/images', [], function () {
if (!$this.parent().is('a')) {
$this.wrap('<a href="' + src + '" ' +
(!srcExt && altExt ? ' download="' + altFilename + '" ' : '') +
- ' target="_blank" >');
+ ' target="_blank" rel="noopener">');
}
});
};