Skip to content

Log/run snyk tool#63

Open
yuriiShmal wants to merge 8 commits intomainfrom
log/run-snyk
Open

Log/run snyk tool#63
yuriiShmal wants to merge 8 commits intomainfrom
log/run-snyk

Conversation

@yuriiShmal
Copy link

@yuriiShmal yuriiShmal commented Mar 12, 2026

The purpose of snyk is to find security vulnerabilities, both from installed libraries, and from the source code.

snyk was installed successfully for local testing, as can be seen in this screenshot of the package.json file
Screenshot from 2026-03-11 20-26-26

Snyk was successfully run via the cli. This can be seen in the snyk_testing_results.txt file.
Testing found 13 issues with dependencies, and 244 issues of varying severity with the source code.
image
image

Customization Considerations:

  • A priori:
    • Minimal customization - required creating an account and installing the cli with npm install snyk
    • Running the tool initially can be done manually, locally, with no other customization
  • Over time:
    • Possible to add continuous integration for dependency security test, so that the dependencies are checked regularly. However, this serves mostly to find out when new vulnerabilities are discovered, as new dependencies are not added very often (presumably)
    • If payment plan is upgraded from free, there is a possibility of adding code test to the CI (doing it under free plan is inadviseable, as described below), as well as customizing it to ignore some irrelevant issues like hardcoded passwords in test files.

Advantages:

  • It can find issues in both the codebase, and search through the dependencies to find issues with them, suggesting dependencies where issues can be fixed by upgrading
  • snyk allows for unlimited testing of dependencies on public manifests

Disadvantages:

  • Testing requires a snyk account and access to github to track usage. This means that correctly integrating snyk with CI requires the use of secrets.
  • As there is a monthly limit of 100 uses to the number of snyk code testing for a free account, using that type of testing in CI is a poor idea.
  • Although it suggests fixing some dependencies by upgrading dependencies, it gives no suggestions for resolving issues where upgrading is insufficient. Furthermore, upgrading the library versions may introduce compatibility issues

yuriiShmal and others added 3 commits March 12, 2026 00:18
Installed and ran snyk. Output in txt file. For forwarding from fork into the branch within the shared repo
The evidence wasn't visible before, as package.json at project root (which is what was used to run snyk) is not and should not be tracked.
@railway-app railway-app bot temporarily deployed to Clean Code Team (nodebb) / nodebb-spring-26-clean-cod-pr-63 March 12, 2026 02:17 Destroyed
@railway-app
Copy link

railway-app bot commented Mar 12, 2026

🚅 Deployed to the nodebb-spring-26-clean-cod-pr-63 environment in Clean Code Team (nodebb)

Service Status Web Updated (UTC)
nodebb-spring-26-clean-code ◻️ Removed (View Logs) Web Mar 17, 2026 at 1:52 am

Wasteful - including a useless image. better just attach it to the pull request
@railway-app railway-app bot temporarily deployed to Clean Code Team (nodebb) / nodebb-spring-26-clean-cod-pr-63 March 12, 2026 02:20 Destroyed
@cirex-web
Copy link

cirex-web commented Mar 12, 2026

I think u should probably install snyk in install/package.json instead of the top-level one? (otherwise it's not picked up by version control)

@railway-app railway-app bot temporarily deployed to Clean Code Team (nodebb) / nodebb-spring-26-clean-cod-pr-63 March 12, 2026 02:38 Destroyed
@railway-app railway-app bot temporarily deployed to Clean Code Team (nodebb) / nodebb-spring-26-clean-cod-pr-63 March 12, 2026 02:40 Destroyed
@yuriiShmal
Copy link
Author

I think u should probably install snyk in install/package.json instead of the top-level one? (otherwise it's not picked up by version control)

And this is the way to run at least the dependency testing automatically later (although not really required for this assignment for now I think)

"snyk": "^1.1303.1",
"socket.io": "4.8.3",
"socket.io-client": "4.8.3",
"@socket.io/redis-adapter": "8.3.0",

Choose a reason for hiding this comment

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

why is this gone lmao

Copy link
Author

Choose a reason for hiding this comment

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

I used npm install snyk to make sure that all of its dependencies would be installed. Not a clue why it was gone afterwards. Fixed now.

@railway-app railway-app bot temporarily deployed to Clean Code Team (nodebb) / nodebb-spring-26-clean-cod-pr-63 March 12, 2026 22:42 Destroyed
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.

2 participants