SShortSingh.
Back to feed

Student builds AST-based GitHub Action to flag Java SQL injection and hardcoded secrets

0
·5 views

A George Mason sophomore built a GitHub Action that scans Java code for SQL injection and hardcoded secrets, marking the affected lines on pull requests. Instead of plain text search, the tool uses JavaParser to convert files into abstract syntax trees, letting rules detect queries built by concatenating user input rather than using PreparedStatement. To reduce false alarms, the author tested the scanner on 31 open source projects and manually reviewed the results, cutting secret false positives from 156 to 27 while still catching every real secret. An optional step uses a local Ollama model to suggest fixes, which are re-parsed to confirm they are valid Java before being shown. The project includes 57 JUnit tests and can be set up in about two minutes via a workflow file, and the author positions it as a learning project for student and small projects rather than a replacement for tools like CodeQL or Semgrep.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

Building Your First Power Apps App From an Excel Spreadsheet

A tutorial explains how to turn an Excel spreadsheet into a working mobile app using Microsoft's low-code platform, Power Apps, without writing code. Microsoft Learn offers a hands-on exercise that generates a three-screen app from a table, covering browsing records, viewing details, and editing values. The walkthrough notes that the data file must be uploaded to OneDrive, and that reusing a previously used file can cause a 'status code 400' error that is fixed by deleting an extra ID column. Readers are then guided to rebuild the app from a blank canvas, explaining how gallery controls use the ThisItem reference to display each row. The author argues the approach is valuable because it produces a real app, teaches transferable skills, and results in a publishable portfolio piece.

0
ProgrammingDEV Community ·

Obsidian Plugin 1.6.0 Release Nearly Shipped With Silently Reverted README

An Obsidian plugin team shipped version 1.6.0 on November 23 after automated checks reported a clean release. Their patch failed to apply to the live README because the file had gained two sections since the patch was built. A blind application would have silently removed that content without any error. The team resolved it with a three-way merge and confirmed the result by reading the diff. They then verified the eight pushed files at the specific commit SHA, finding all of them matched the verified merge result byte for byte.

0
ProgrammingDEV Community ·

Presigned URLs Offload Health Report Uploads From App Servers

An architecture write-up argues that large health report uploads should use short-lived presigned URLs so bytes go straight to storage rather than through application servers. The backend would still authenticate users, generate its own object keys, and control how long each permission lasts. Proxying uploads remains appropriate only when content must be inspected or transformed before it is stored. The author notes that the storage model has no public-read links, so downloads would also use fresh signed links after re-authorization. The piece emphasizes that direct uploads reduce bandwidth and timeout pressure on application instances but do not eliminate the need for validation.

0
ProgrammingDEV Community ·

Church Sermon Clips Now Generated by One Weekly Command

A church partner posts a short clip of each Sunday sermon to Facebook, a task that was previously repeated by hand every week. The team turned the fixed format, which pairs the speaker with captions, a branded look, and an end card, into a script. Supplying the date and the passage's start and end points produces a finished vertical clip in roughly two minutes. The tool transcribes and times captions, frames the speaker, and balances audio, while its end card doubles as a Story image. Transcription runs on local hardware so recordings are not sent to outside services, and the process can pause for a preview of captions and crop frames before rendering.