Skip to content

CVE-2023-32695 Solution options without installing a new version #4722

Answered by darrachequesne
temajm asked this question in General
Discussion options

You must be logged in to vote

Hi! Thanks for raising this concern 👍

There is also socket.use():

socket.use(([event], next) => {
  if (typeof event === "number" || typeof event === "string") {
    next();
  } else {
    socket.disconnect(true);
  }
});

Reference: https://socket.io/docs/v4/server-api/#socketusefn

Not many developers are ready to switch to a new version of socket.io

Out of curiosity, what makes you say that? The migration from v3 to v4 should be rather straightforward, as there are just a couple of breaking changes impacting the API on the server side: https://socket.io/docs/v4/migrating-from-3-x-to-4-0/

That being said, if that's really an issue, we could backport the fix in the other branches, like 4…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by temajm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants