DBIx-Safe
Dbix-safe
https://metacpan.org/release/DBIx-Safe
Safe wrapper to DBI interface
The purpose of this module is to give controlled, limited access to an application, rather than simply passing it a raw database handle through DBI. DBIx::Safe acts as a wrapper to the database, by only allowing through the commands you tell it to. It filters all things related to the database handle - methods and attributes.
The typical usage is for your application to create a database handle via a normal DBI call to new(), then pass that to DBIx::Safe->new(), which will return you a DBIx::Safe object. After specifying exactly what is and what is not allowed, you can pass the object to the untrusted application. The object will act very similar to a DBI database handle, and in most cases can be used interchangeably.
By default, nothing is allowed to run at all. There are many things you can control. You can specify which SQL commands are allowed, by indicating the first word in the SQL statement (e.g. 'SELECT'). You can specify which database methods are allowed to run (e.g. 'ping'). You can specify a regular expression that allows matching SQL statements to run (e.g. 'qr{SET TIMEZONE}'). You can specify a regular expression that is NOT allowed to run (e.g. qr(UPDATE xxx}). Finally, you can indicate which database attributes are allowed to be read and changed (e.g. 'PrintError'). For all of the above, there are matching methods to remove them as well.
Licensing
License
Verified by
Verified on
Notes
License
Verified by
Debian
Verified on
20 March 2013
Notes
License: BSD or Artistic or GPL-1+
BSD:
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
Artistic:
This program is free software; you can redistribute it and/or modify it under the terms of the Artistic License, which comes with Perl. On Debian GNU/Linux systems, the complete text of the Artistic License can be found in `/usr/share/common- licenses/Artistic'
GPL-1+:
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version. On Debian GNU/Linux systems, the complete text of the GNU General Public Licensecan be found in `/usr/share/common-licenses/GPL'
License
Verified by
Debian
Verified on
20 March 2013
Notes
License: Artistic or GPL-1+
Artistic:
This program is free software; you can redistribute it and/or modify it under the terms of the Artistic License, which comes with Perl. On Debian GNU/Linux systems, the complete text of the Artistic License can be found in `/usr/share/common- licenses/Artistic'
GPL-1+:
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version. On Debian GNU/Linux systems, the complete text of the GNU General Public Licensecan be found in `/usr/share/common-licenses/GPL'
Leaders and contributors
Resources and communication
Audience | Resource type | URI |
---|---|---|
Debian (Ref) (R) | https://tracker.debian.org/pkg/libdbix-safe-perl | |
Perl (Ref) | https://metacpan.org/release/DBIx-Safe |
Software prerequisites
}
}
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the page “GNU Free Documentation License”.
The copyright and license notices on this page only apply to the text on this page. Any software or copyright-licenses or other similar notices described in this text has its own copyright notice and license, which can usually be found in the distribution or license text itself.