Main Koha release repository
https://koha-community.org
Tomas Cohen Arazi
ee2931a7b0
This patch adds a check in Koha::REST::V1::Auth::under to catch all routes that begin with 'public' (inside /api/v1). If they match, and the RESTPublicAPI syspref is off, then an exception is thrown, rendering a 403 error to the consumer. Otherwise the routes are processed as usual. This is THE on/off switch for the public REST API. The target use case: people not wanting an OPAC or public interaction with the API besides privileged users. In order to test, the rest of the patches are needed because the only way to test a route is having it in the spec. To test: - Apply the patches - Run: $ kshell k$ prove t/db_dependent/api/v1/auth.t => SUCCESS: tests pass! - Sign off :-D Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> |
||
---|---|---|
acqui | ||
admin | ||
api/v1 | ||
authorities | ||
basket | ||
C4 | ||
catalogue | ||
cataloguing | ||
circ | ||
clubs | ||
course_reserves | ||
debian | ||
docs | ||
errors | ||
etc | ||
ill | ||
installer | ||
Koha | ||
koha-tmpl | ||
labels | ||
members | ||
misc | ||
offline_circ | ||
opac | ||
OpenILS | ||
patron_lists | ||
patroncards | ||
plugins | ||
reports | ||
reserve | ||
reviews | ||
rotating_collections | ||
serials | ||
services | ||
skel | ||
suggestion | ||
svc | ||
t | ||
tags | ||
test | ||
tmp/modified_authorities | ||
tools | ||
virtualshelves | ||
xt | ||
.editorconfig | ||
.gitignore | ||
.htaccess | ||
.mailmap | ||
.scss-lint.yml | ||
about.pl | ||
changelanguage.pl | ||
fix-perl-path.PL | ||
gulpfile.js | ||
help.pl | ||
INSTALL | ||
install-CPAN.pl | ||
Koha.pm | ||
koha_perl_deps.pl | ||
kohaversion.pl | ||
LICENSE | ||
mainpage.pl | ||
Makefile.PL | ||
MANIFEST.SKIP | ||
package.json | ||
README | ||
README.md | ||
README.robots | ||
rewrite-config.PL | ||
yarn.lock |
Koha is a free software integrated library system (ILS).
Koha is distributed under the GNU GPL version 3 or later.
Note: This is a synced mirror of the official Koha repo.
Note: Koha does not accept pull requests from git hosting sites.
Note: This project has its own bug tracker, to report a bug or submit a patch visit http://bugs.koha-community.org.
For guidelines on submitting patches for Koha please visit https://wiki.koha-community.org/wiki/SubmitingAPatch
The developers handbook can be found at https://wiki.koha-community.org/wiki/Developer_handbook