Skip to content

Add SMW Immersion theme plugin for OJS 3.5.0 compatibility#482

Open
Godoy0722 wants to merge 6 commits into
pkp:mainfrom
Godoy0722:main
Open

Add SMW Immersion theme plugin for OJS 3.5.0 compatibility#482
Godoy0722 wants to merge 6 commits into
pkp:mainfrom
Godoy0722:main

Conversation

@Godoy0722
Copy link
Copy Markdown

No description provided.

@Godoy0722
Copy link
Copy Markdown
Author

Hello @bozana , would you mind having a look on this plugin? This will be a new theme in our plugin gallery. Also, would you mind having a look on the theme itself to make a code review on that? I appreciate your help!

@bozana
Copy link
Copy Markdown

bozana commented Apr 29, 2026

Hi @Godoy0722,

There are a few security issues:

Also:

I am not sure about those JS issues, so maybe also here to ask Jarda.

Thanks a lot!

@kaitlinnewson
Copy link
Copy Markdown
Member

Similar to the Ammonite plugin, this requires the user to have installed and enabled the Immersion theme to function properly, so that needs to be documented in the description and perhaps handled in the code (e.g. don't let the user set this theme without that perhaps?).

@Godoy0722
Copy link
Copy Markdown
Author

Hello @bozana and @kaitlinnewson! I just addressed your suggestions into the theme and generated a new release with these fixes! Would you mind having a second look? I appreciate it! Thanks a lot.

@bozana
Copy link
Copy Markdown

bozana commented May 12, 2026

Hi @Godoy0722,

I have a few comments:

  if (name === 'href' && /^\s*(javascript|data):/i.test(value)) {                                                                                                                                                                                             
      el.removeAttribute(name);                                                                                                                                                                                                                               
      continue;
  }                                                                                                                                                                                                                                                           
  if ((name === 'src' || name === 'xlink:href') &&
      /^\s*(javascript:|data:(text\/html|image\/svg))/i.test(value)) {                                                                                                                                                                                        
      el.removeAttribute(name);
  }               

This keeps innocent data:image/png inline images working while blocking the dangerous cases

It looks great! You have considered everything!

This plugin.xml would also need the rebase then.
Thanks a lot!!!

@Godoy0722
Copy link
Copy Markdown
Author

Hello again @bozana! First of all, sorry for the very late on answering you here! Just a heads-up that I updated the theme with your requested changes! Please feel free to have a look at it when you can! Thank you.

Comment thread plugins.xml Outdated
<release date="2026-04-20" version="3.5.3.0" md5="5ca818ab98c870691efe38b198e1c799">
<package>https://github.com/Godoy0722/smwImmersion/releases/download/v3.5.3/smwImmersion-v3.5.3.0.tar.gz</package>
<compatibility application="ojs2">
<version>~3.5.3.0</version>
Copy link
Copy Markdown

@bozana bozana Jun 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3.5.0.0 or 3.5.0.3 or 3.5.0.4?

@bozana
Copy link
Copy Markdown

bozana commented Jun 2, 2026

Hi @Godoy0722, thanks a lot! Just one more small thing -- the version the plugin is compatible with should be fixed in plugins.xml, I think -- see my last comment here.
Thanks a lot!

@Godoy0722
Copy link
Copy Markdown
Author

Hello @bozana ! Please let me know if I did it correctly with my most recent change! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants