Main Koha release repository https://koha-community.org
Find a file
Galen Charlton 70d33a82bb granular permissions - C4::Auth
Enhanced the permission-checking functions in C4::Auth
(e.g., get_template_and_user, checkauth, check_api_auth, etc.).

If the CheckSpecificUserPermissions syspref is OFF, the behavior
of those APIs is unchanged.

If CheckSpecificUserPermissions is ON, then the value of each
key in the flagsrequired hash is considered during
the permissions check:

  1. if the value is 1, the staff user must have
     all privileges for the userflags flag (or module)
     referred to by the hash key, e.g.,

     { flaqsrequired => { tools => 1 } }

     In terms of the database, this means that the
     corresponding bit must be set in borrowers.flags.

  2. If the value is '*', the staff user must
     have at least one of the permissions for the
     userflag/module, but it doesn't matter which one.

     In terms of the database, this means ether that the
     corresponding bit must be set in borrowers.flags or
     that there at least is one row in user_permissions
     for the staff user and bit/module combination.

  3. If the value is any other string, it must be
     a permissions code defined in the permissions table.
     The staff user must have that specific permission
     or have access to all functions of the module

     In terms of the database, this means ether that the
     corresponding bit must be set in borrowers.flags or
     that there is a matching row in user_permissions
     for the staff user, bit/module, subpermission
     code combination.

In addition, get_template_and_user is modified so that the
CAN_user_XXX variables that it sets also includes the
subpermissions available (CAN_user_XXX_YYY, e.g.,
CAN_user_tools_import_patrons).  The template variables
for the specific permissions are set regardless of whether
CheckSpecificUserPermissions is ON or OFF so that the templates
don't have to test for that syspref explicitly.

In addition, the meaning of CAN_user_XXX has changed slightly -
CAN_user_tools, for example, is set to 1 in the template if the
user has access to *any* of the tools functions.  This was done
to simply the logic for deciding whether to display a menu
item in the staff interface are not.  This does mean that
when specific subpermissions are added to (say) the circulate
module, each use of CAN_user_circulate will need to be examined
to see if the intent is to allow the user to get at a circ
menu or page or if the user really should be required to have
all circulate functions.

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 15:53:13 -05:00
acqui acqui/addorder.pl - use reliable GetBookSellerFromId instead of relying on name search. 2008-03-08 11:19:27 -06:00
admin granular permissions - created DB tables 2008-04-10 15:53:08 -05:00
authorities authorities: make tag editor links consistent with bib 2007-12-29 06:53:52 -06:00
C4 granular permissions - C4::Auth 2008-04-10 15:53:13 -05:00
catalogue Fix authorised_value '0' problem with last commit on detail.pl 2008-04-07 15:59:50 -05:00
cataloguing BiblioAddsAuthorities improvement/fix 2008-04-10 02:55:08 -05:00
circ Formatting patron expiration date output (or was there a reason why this was commented out previously?) 2008-04-10 02:59:32 -05:00
errors bug 1803 - fix error page handling 2008-02-18 19:32:07 -06:00
etc adding Ç as equivale nt to c for frenchies 2008-04-07 15:56:28 -05:00
install_misc install: tweaked 'make update' 2008-02-15 08:30:53 -06:00
installer granular permissions - created DB tables 2008-04-10 15:53:08 -05:00
koha-tmpl fixed XHTML error 2008-04-10 15:53:02 -05:00
labels bug 2009: fix to include "type" so that adding items to label batches works. 2008-04-10 03:00:36 -05:00
members Some formatting changes, bringing displays in circ and moremember more in line with each other 2008-04-08 08:37:03 -05:00
misc Fix calls to CalcFine, and make fines obey CircControl syspref (get homebranch withssue data). 2008-04-08 08:37:01 -05:00
opac Reintroducing history dates for serial-issue (see previous commit for staff // feature) 2008-04-10 02:52:54 -05:00
reports All patches to Koha 3 beta to date. All work with branches. 2008-04-03 14:42:07 -05:00
reserve Report borrower's home library on reserves library mismatch. 2008-03-25 07:20:22 -05:00
reviews functions that were in C4::Interface::CGI::Output are now in C4::Output. 2007-04-24 13:54:28 +00:00
rss rel_3_0 moved to HEAD 2007-03-09 15:12:54 +00:00
serials bugfix : independantbranches behaviour 2008-04-10 02:55:50 -05:00
skel installer: fixed chown invocation; added skel for KOHA_LOG_DIR 2007-12-17 09:13:53 -06:00
sms SMS - widespread cleanup and moving code away from Cyprus/Turkey-specific implementation. Much more needed. 2008-02-06 23:19:30 -06:00
suggestion removing useless code 2007-10-24 17:03:38 -05:00
svc bib_profile web svc: report biblioitems.itemtype subfield as non-mandatory 2007-12-04 15:06:05 -06:00
t use bind variables in C4::Acquisition::GetPendingOrders 2008-03-19 15:46:23 -05:00
tmp/modified_authorities changing DO_NOT_REMOVE to README.txt 2007-10-21 19:14:41 -05:00
tools Bugfix: Correcting misspelled variable 2008-04-10 02:59:22 -05:00
virtualshelves Shelves consolidation to C4::VirtualShelves::Page. I can tell the consolidation 2008-01-14 16:45:21 -06:00
.htaccess bug 1803 - fix error page handling 2008-02-18 19:32:07 -06:00
about.pl don't sort @INC when displaying on about page 2008-02-15 08:24:43 -06:00
changelanguage.pl fixing bug 1754: Hide language chooser if only one translation is available 2008-03-17 21:28:31 -05:00
edithelp.pl edithelp.pl - cleanup, refactor and error feedback to user 2008-01-08 14:04:48 -06:00
fix-perl-path.PL installer: improvements to fix-path-perl.PL on Win32 2007-12-20 19:20:12 -06:00
help.pl Adding yuipath variable to help.pl, and doing some cleanup of help templates (standardizing structure, mostly, and correcting some nomenclature). 2008-01-09 14:50:20 -06:00
INSTALL adding upgrade instructions to INSTALL and INSTALL.debain 2008-02-21 14:04:47 -06:00
install-CPAN.pl BUGFIX: need to create authors/id if CPAN is unused 2007-09-07 05:26:16 -05:00
INSTALL.debian updating installation docs 2008-03-23 00:26:30 -05:00
kohaversion.pl granular permissions - created DB tables 2008-04-10 15:53:08 -05:00
LICENSE re-naming some files prior to release 2007-12-30 12:13:39 -06:00
mainpage.pl fixing permissions requirements on mainpage.pl 2008-01-04 21:30:14 -06:00
Makefile.PL NOTE: REQUIRES INSTALLATION OF Image::Magick; Adding image scaling/resizing capability to picture-upload.pl 2008-04-08 17:00:05 -05:00
MANIFEST.SKIP Do not pack the git repository 2007-09-06 17:14:36 -05:00
README adding README 2007-12-30 12:13:57 -06:00
rewrite-config.PL install: added --prev-install-log option to Makefile.PL 2008-02-15 08:30:51 -06:00

Koha 3 - the next-generation release of the award-winning Koha open-source
integrated library system.

30 December 2007 - Joshua Ferraro <jmf AT liblime DOT com>

Koha is distributed under the GNU GPL. Please read the file LICENSE for
more details.

To install or upgrade Koha, please see the INSTALL file.

Please report any bugs to the koha mailing lists or bug tracker and we
will try to fix them in a future release. The main koha web site is
http://www.koha.org/