BSD Ports

databases/p5-Mojo-SQL 0.02 DragonFly

Safely generate and compose SQL statements

System
DragonFly
Repository
DPorts
Maintainer
[email protected] (as in FreeBSD)
License
MIT
Categories
databases, perl5
Package size
9.0 KiB, 14.7 KiB installed

Description

Mojo::SQL safely generates and composes SQL statements. To prevent SQL injection attacks, every ? in the input becomes a placeholder in the generated query, with the corresponding value bound to it. Partial statements can be composed recursively to build more complex queries.

Literal question marks can be escaped with ??.

Make partial statements optional to dynamically generate WHERE clauses.

If you need a little more control over the generated SQL query, you can also bypass safety features with "sql_unsafe". But make sure to handle unsafe values yourself with appropriate escaping functions for your database. For PostgreSQL there are "escape_literal" and "escape_identifier" functions included with this module.

For databases that do not support numbered placeholders like $1 and $2, you can set a custom character with the placeholder option.

In the other systems

The newest version among them is 0.02, as upstream numbers it.

SystemPortVersionVulnerabilitiesStatusMaintainerLast update
DragonFlydatabases/p5-Mojo-SQL0.02 newestnone known-[email protected]-
FreeBSDdatabases/p5-Mojo-SQL0.02 newestnone known-[email protected]-
HardenedBSDdatabases/p5-Mojo-SQL0.02 newestno data-[email protected]-
GhostBSDdatabases/p5-Mojo-SQL0.02 newestno data-[email protected]-

Version history 1

  1. 0.02

Upstream's version as each commit to the port's Makefile set it, or as this site first saw it in the system's packages; the tree's own revisions are not versions here.

Install

Binary package:

pkg install p5-Mojo-SQL

From DPorts:

cd /usr/dports/databases/p5-Mojo-SQL && make install clean

Dependency graph

Ports that need it on the left, what it needs to run on the right; at most 8 of each. "Dependencies" below lists them all.

Dependencies

Run dependencies 2
Required by 1