[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2023-05-31 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Fridolin Somers  changed:

   What|Removed |Added

 Blocks||33875


Referenced Bugs:

https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33875
[Bug 33875] Missing closing tag a in API key management page
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2019-01-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Fridolin SOMERS  changed:

   What|Removed |Added

 Blocks||22071


Referenced Bugs:

https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22071
[Bug 22071] authenticate_api_request does not stash koha.user in the OAuth use
case
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2019-01-09 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Caroline Webb  changed:

   What|Removed |Added

 CC||carolineweb...@gmail.com

--- Comment #57 from Caroline Webb  ---
A best platform for users and makers to tell the developers about the bug which
they experience and feels that there is need of adding API key management
interface for patrons and welcoming solutions here.

Caroline,
http://www.personalstatementfolks.co.uk/

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-07-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Martin Renvoize  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|Pushed to Master|RESOLVED
 CC||martin.renvoize@ptfs-europe
   ||.com

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-05-22 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Jonathan Druart  changed:

   What|Removed |Added

 Blocks||20803


Referenced Bugs:

https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20803
[Bug 20803] Cannot search to hold or use print options from API keys interface
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-05-09 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Jonathan Druart  changed:

   What|Removed |Added

 Status|Passed QA   |Pushed to Master

--- Comment #56 from Jonathan Druart  
---
Pushed to master for 18.05, thanks to everybody involved!

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-05-08 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Jonathan Druart  changed:

   What|Removed |Added

  Attachment #75186|0   |1
is obsolete||

--- Comment #55 from Jonathan Druart  
---
Created attachment 75188
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=75188=edit
Bug 20568: Fix bad resolution conflict with bug 18403

borrowers module permission has now several subpermissions

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-05-08 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #54 from Jonathan Druart  
---
Created attachment 75187
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=75187=edit
Bug 20568: fix shebang

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-05-08 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #53 from Jonathan Druart  
---
Created attachment 75186
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=75186=edit
Bug 20568: (follow-up) API keys management in interface

Fix bad resolution conflict.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-05-03 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #52 from Tomás Cohen Arazi  ---
Created attachment 75023
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=75023=edit
Bug 20568: (QA follow-up) Remove unused vars

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-05-02 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74980|0   |1
is obsolete||

--- Comment #51 from Tomás Cohen Arazi  ---
Created attachment 74981
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74981=edit
Bug 20568: (QA follow-up) Remove api-key management from OPAC

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-05-02 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #50 from Tomás Cohen Arazi  ---
Created attachment 74980
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74980=edit
Bug 20568: (QA follow-up) Remove api-key management from OPAC

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-23 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

 Blocks||20638


Referenced Bugs:

https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20638
[Bug 20638] Log actions on API keys
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-20 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Martin Renvoize  changed:

   What|Removed |Added

 Blocks||20627


Referenced Bugs:

https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20627
[Bug 20627] Prevent leakages of user permissions to api access tokens
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-19 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

 Blocks||20624


Referenced Bugs:

https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20624
[Bug 20624] Allow switching off the OAuth2 client credentials grant
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Katrin Fischer  changed:

   What|Removed |Added

 CC||katrin.fisc...@bsz-bw.de
  Text to go in the|Adds the ability to handle  |Adds the ability to handle
  release notes|patron-level API keys to be |patron-level API keys to be
   |used for authenticating the |used for authenticating the
   |REST api.   |REST API.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Text to go in the||Adds the ability to handle
  release notes||patron-level API keys to be
   ||used for authenticating the
   ||REST api.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74454|0   |1
is obsolete||

--- Comment #45 from Julian Maurice  ---
Created attachment 74492
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74492=edit
Bug 20568: (follow-up) Atomic update fix

Signed-off-by: Tomas Cohen Arazi 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74477|0   |1
is obsolete||

--- Comment #47 from Julian Maurice  ---
Created attachment 74494
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74494=edit
Bug 20568: (QA follow-up) Make sure client_id and secret are not overwritten on
store

Signed-off-by: Tomas Cohen Arazi 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74480|0   |1
is obsolete||

--- Comment #48 from Julian Maurice  ---
Created attachment 74495
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74495=edit
Bug 20568: (QA follow-up) Get rid of the id column

Signed-off-by: Tomas Cohen Arazi 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74482|0   |1
is obsolete||

--- Comment #49 from Julian Maurice  ---
Created attachment 74496
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74496=edit
Bug 20568: CSRF protection

Edit: fix warning introduced by this patch

Signed-off-by: Tomas Cohen Arazi 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74476|0   |1
is obsolete||

--- Comment #46 from Julian Maurice  ---
Created attachment 74493
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74493=edit
Bug 20568: (QA follow-up) Test client_id and secret are not overwritten

Signed-off-by: Tomas Cohen Arazi 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74389|0   |1
is obsolete||

--- Comment #44 from Julian Maurice  ---
Created attachment 74491
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74491=edit
Bug 20568: Move value => client_id + secret

This patch addresses the request from Julian that api keys are expected
to be client id/secret pairs.

It does so by
- Adding 'client_id' and 'secret' columns
- Removing 'value'

Tests got adjusted and so controller scripts and templates.
Both libs and tests changes have been squashed. This ones remain in
order to keep Owen's attribution on the template changes and avoid
rebase conflicts.

Signed-off-by: Kyle M Hall 
Signed-off-by: Tomas Cohen Arazi 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74346|0   |1
is obsolete||

--- Comment #42 from Julian Maurice  ---
Created attachment 74489
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74489=edit
Bug 20568: API key management for OPAC users

This patch makes the OPAC interface for API keys management work
with the new lib. Verify all actions work for a logged user.

Users without login should be redirected to an error page.

The AllowPatronsManageAPIKeysInOPAC syspref is added to control if the
OPAC feature is enabled or not.

To test:
- Verify the syspref works
- Verify users can manage their API keys

Signed-off-by: Kyle M Hall 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74388|0   |1
is obsolete||

--- Comment #43 from Julian Maurice  ---
Created attachment 74490
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74490=edit
Bug 20568: (follow-up) Interface and markup changes

This patch makes some interface changes to bring things better in line
with existing interface patterns. This patch also re-indents the
modified templates with 4 spaces instead of 2 and makes s
self-closing.

Also changed: Corrected system preference check in opac-apikeys.pl.

To test, apply the patch and:

In the staff client:

 - Open a patron record and choose More -> Manage API keys.
   - There should be a standard message dialog containing a link to
 "Generate a new key."
 - Clicking the link should show the form for adding a new key.
 - Test that clicking the "Cancel" link hides the form.
 - Test that creating the new key works correctly.
   - You should now see a table showing existing keys and a "Generate a
 new key" button above it.
 - Test that the "Delete" button asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.

In the OPAC:

 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Allow."
 - Log in to the OPAC and click the "your API keys" link in the sidebar.
   - Clicking the "Generate new key" button should display the form for
 adding a new key.
 - Clicking the "cancel" link should hide the form.
 - Submitting the form should add a new key.
   - You should now see a table showing existing keys.
 - Test that the "Delete" link asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.
 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Don't
   allow."
   - Log in to the OPAC and confirm that the "your API keys" link in the
 sidebar is no longer visible.
 - Confirm that navigating directly to /cgi-bin/koha/opac-apikeys.pl
   results in a 404 error.

Signed-off-by: Tomas Cohen Arazi 

Signed-off-by: Kyle M Hall 
Signed-off-by: Tomas Cohen Arazi 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74345|0   |1
is obsolete||

--- Comment #41 from Julian Maurice  ---
Created attachment 74488
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74488=edit
Bug 20568: Unit tests

This patch adds unit tests for the introduced classes: Koha::ApiKey(s).

To test:
- Apply this patch
- Run
  $ kshell
 k$ prove t/db_dependent/Koha/ApiKeys.t
=> FAIL: Tests fail because the feature is not implemented.

Signed-off-by: Kyle M Hall 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74343|0   |1
is obsolete||

--- Comment #39 from Julian Maurice  ---
Created attachment 74486
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74486=edit
Bug 20568: API keys management in interface

This introduces the concept of API keys for use in the new REST API.
A key is a string of 32 alphanumerical characters (32 is purely
arbitrary, it can be changed easily).
A user can have multiple keys (unlimited at the moment)
Keys can be generated automatically, and then we have the possibility to
delete or revoke each one individually.

Test plan:
1/ Go to staff interface
2/ Go to a borrower page
3/ In toolbar, click on More -> Manage API keys
4/ Click on "Generate new key" multiple times, check that they are
   correctly displayed under the button, and they are active by default
5/ Revoke some keys, check that they are not active anymore
6/ Delete some keys, check that they disappear from table
7/ Go to opac interface, log in
8/ In your user account pages, you now have a new tab to the left "your
   API keys". Click on it.
9/ Repeat steps 4-6

Signed-off-by: Kyle M Hall 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74344|0   |1
is obsolete||

--- Comment #40 from Julian Maurice  ---
Created attachment 74487
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74487=edit
Bug 20568: Add mandatory description field for api keys

This patch changes the table structure adding fields usually found on
this kind of api management pages.

Signed-off-by: Kyle M Hall 
Signed-off-by: Julian Maurice 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74481|0   |1
is obsolete||

--- Comment #38 from Tomás Cohen Arazi  ---
Created attachment 74482
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74482=edit
Bug 20568: CSRF protection

Edit: fix warning introduced by this patch

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

 CC||oleon...@myacpl.org

--- Comment #37 from Tomás Cohen Arazi  ---
(In reply to Julian Maurice from comment #30)
> QA comments:
> 
> 1) The UUID generation happens in the store method. This means that every
> time I revoke/activate a key, client_id and secret are changed. I think that
> is not the desired behaviour.

Done. I provided both regression tests for this situation and the fix.

> 2) A CSRF attack can remove and revoke keys. This can be prevented by using
> Koha::Token.

Done. Good catch :-D

> 3) UUID::generate($uuid); UUID::unparse( $uuid, $uuidstring ); can be
> replaced by $uuidstring = uuid();

I've had issues with Jessie's version of UUID (0.05). I get:

Error: "uuid" is not exported buy the UUID module

> 4) In intranet, if I have no key and click twice on "Generate a new client
> id/secret pair" link, the form appear then disappear. Not really a problem,
> but it's an odd behaviour. I suggest to just show the button even if I have
> no keys, like in OPAC.

Right, I will think about it. Maybe Owen can answer about this.

> 5) I feel that api_keys.id is not useful as client_id can be used as a
> primary key

You are right! Removed!

> 6) Since we're using UUID, why not store the binary representation instead
> of the string representation ? I don't know how that would affect
> performance but that will save storage space. If we stick with the string
> representation I suggest that we change the data type of client_id and
> secret to a fixed-width string type (CHAR(36) ?)

I don't think this is necessary. For this client_id/secret pairs as are not
expected be be many. Also, VARCHAR only takes as much space as the size of the
content.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

 Status|Failed QA   |Passed QA

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #36 from Tomás Cohen Arazi  ---
Created attachment 74481
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74481=edit
Bug 20568: CSRF protection

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74479|0   |1
is obsolete||

--- Comment #35 from Tomás Cohen Arazi  ---
Created attachment 74480
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74480=edit
Bug 20568: (QA follow-up) Get rid of the id column

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74478|0   |1
is obsolete||

--- Comment #34 from Tomás Cohen Arazi  ---
Created attachment 74479
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74479=edit
Bug 20568: (QA follow-up) Get rid of the id column

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #33 from Tomás Cohen Arazi  ---
Created attachment 74478
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74478=edit
Bug 29568: (QA follow-up) Get rid of the id column

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #31 from Tomás Cohen Arazi  ---
Created attachment 74476
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74476=edit
Bug 20568: (QA follow-up) Test client_id and secret are not overwritten

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #32 from Tomás Cohen Arazi  ---
Created attachment 74477
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74477=edit
Bug 20568: (QA follow-up) Make sure client_id and secret are not overwritten on
store

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

 Blocks||20612


Referenced Bugs:

https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20612
[Bug 20612] Make OAuth2 use patron's client_id/secret pairs
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

 Status|Signed Off  |Failed QA

--- Comment #30 from Julian Maurice  ---
QA comments:

1) The UUID generation happens in the store method. This means that every time
I revoke/activate a key, client_id and secret are changed. I think that is not
the desired behaviour.
2) A CSRF attack can remove and revoke keys. This can be prevented by using
Koha::Token.
3) UUID::generate($uuid); UUID::unparse( $uuid, $uuidstring ); can be replaced
by $uuidstring = uuid();
4) In intranet, if I have no key and click twice on "Generate a new client
id/secret pair" link, the form appear then disappear. Not really a problem, but
it's an odd behaviour. I suggest to just show the button even if I have no
keys, like in OPAC.
5) I feel that api_keys.id is not useful as client_id can be used as a primary
key
6) Since we're using UUID, why not store the binary representation instead of
the string representation ? I don't know how that would affect performance but
that will save storage space. If we stick with the string representation I
suggest that we change the data type of client_id and secret to a fixed-width
string type (CHAR(36) ?)

Failing QA for 1 and 2.
3 and 4 are not required but they should be easy to do.
5 and 6 are just thoughts. Please comment.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

  Attachment #74434|0   |1
is obsolete||

--- Comment #29 from Julian Maurice  ---
Created attachment 74454
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74454=edit
Bug 20568: (follow-up) Atomic update fix

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

 QA Contact|testo...@bugs.koha-communit |julian.maur...@biblibre.com
   |y.org   |

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #28 from Tomás Cohen Arazi  ---
Created attachment 74434
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74434=edit
Bug 20568: (follow-up) Atomic update fix

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-17 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74348|0   |1
is obsolete||

--- Comment #27 from Tomás Cohen Arazi  ---
Created attachment 74389
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74389=edit
Bug 20568: Move value => client_id + secret

This patch addresses the request from Julian that api keys are expected
to be client id/secret pairs.

It does so by
- Adding 'client_id' and 'secret' columns
- Removing 'value'

Tests got adjusted and so controller scripts and templates.
Both libs and tests changes have been squashed. This ones remain in
order to keep Owen's attribution on the template changes and avoid
rebase conflicts.

Signed-off-by: Kyle M Hall 
Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-17 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74347|0   |1
is obsolete||

--- Comment #26 from Tomás Cohen Arazi  ---
Created attachment 74388
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74388=edit
Bug 20568: (follow-up) Interface and markup changes

This patch makes some interface changes to bring things better in line
with existing interface patterns. This patch also re-indents the
modified templates with 4 spaces instead of 2 and makes s
self-closing.

Also changed: Corrected system preference check in opac-apikeys.pl.

To test, apply the patch and:

In the staff client:

 - Open a patron record and choose More -> Manage API keys.
   - There should be a standard message dialog containing a link to
 "Generate a new key."
 - Clicking the link should show the form for adding a new key.
 - Test that clicking the "Cancel" link hides the form.
 - Test that creating the new key works correctly.
   - You should now see a table showing existing keys and a "Generate a
 new key" button above it.
 - Test that the "Delete" button asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.

In the OPAC:

 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Allow."
 - Log in to the OPAC and click the "your API keys" link in the sidebar.
   - Clicking the "Generate new key" button should display the form for
 adding a new key.
 - Clicking the "cancel" link should hide the form.
 - Submitting the form should add a new key.
   - You should now see a table showing existing keys.
 - Test that the "Delete" link asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.
 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Don't
   allow."
   - Log in to the OPAC and confirm that the "your API keys" link in the
 sidebar is no longer visible.
 - Confirm that navigating directly to /cgi-bin/koha/opac-apikeys.pl
   results in a 404 error.

Signed-off-by: Tomas Cohen Arazi 

Signed-off-by: Kyle M Hall 
Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-17 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #25 from Kyle M Hall  ---
Created attachment 74348
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74348=edit
Bug 20568: Move value => client_id + secret

This patch addresses the request from Julian that api keys are expected
to be client id/secret pairs.

It does so by
- Adding 'client_id' and 'secret' columns
- Removing 'value'

Tests got adjusted and so controller scripts and templates.
Both libs and tests changes have been squashed. This ones remain in
order to keep Owen's attribution on the template changes and avoid
rebase conflicts.

Signed-off-by: Kyle M Hall 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-17 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #23 from Kyle M Hall  ---
Created attachment 74346
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74346=edit
Bug 20568: API key management for OPAC users

This patch makes the OPAC interface for API keys management work
with the new lib. Verify all actions work for a logged user.

Users without login should be redirected to an error page.

The AllowPatronsManageAPIKeysInOPAC syspref is added to control if the
OPAC feature is enabled or not.

To test:
- Verify the syspref works
- Verify users can manage their API keys

Signed-off-by: Kyle M Hall 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-17 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #24 from Kyle M Hall  ---
Created attachment 74347
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74347=edit
Bug 20568 (follow-up) Interface and markup changes

This patch makes some interface changes to bring things better in line
with existing interface patterns. This patch also re-indents the
modified templates with 4 spaces instead of 2 and makes s
self-closing.

Also changed: Corrected system preference check in opac-apikeys.pl.

To test, apply the patch and:

In the staff client:

 - Open a patron record and choose More -> Manage API keys.
   - There should be a standard message dialog containing a link to
 "Generate a new key."
 - Clicking the link should show the form for adding a new key.
 - Test that clicking the "Cancel" link hides the form.
 - Test that creating the new key works correctly.
   - You should now see a table showing existing keys and a "Generate a
 new key" button above it.
 - Test that the "Delete" button asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.

In the OPAC:

 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Allow."
 - Log in to the OPAC and click the "your API keys" link in the sidebar.
   - Clicking the "Generate new key" button should display the form for
 adding a new key.
 - Clicking the "cancel" link should hide the form.
 - Submitting the form should add a new key.
   - You should now see a table showing existing keys.
 - Test that the "Delete" link asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.
 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Don't
   allow."
   - Log in to the OPAC and confirm that the "your API keys" link in the
 sidebar is no longer visible.
 - Confirm that navigating directly to /cgi-bin/koha/opac-apikeys.pl
   results in a 404 error.

Signed-off-by: Tomas Cohen Arazi 

Signed-off-by: Kyle M Hall 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-17 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #22 from Kyle M Hall  ---
Created attachment 74345
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74345=edit
Bug 20568: Unit tests

This patch adds unit tests for the introduced classes: Koha::ApiKey(s).

To test:
- Apply this patch
- Run
  $ kshell
 k$ prove t/db_dependent/Koha/ApiKeys.t
=> FAIL: Tests fail because the feature is not implemented.

Signed-off-by: Kyle M Hall 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-17 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #21 from Kyle M Hall  ---
Created attachment 74344
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74344=edit
Bug 20568: Add mandatory description field for api keys

This patch changes the table structure adding fields usually found on
this kind of api management pages.

Signed-off-by: Kyle M Hall 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-17 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Kyle M Hall  changed:

   What|Removed |Added

  Attachment #74254|0   |1
is obsolete||
  Attachment #74255|0   |1
is obsolete||
  Attachment #74256|0   |1
is obsolete||
  Attachment #74257|0   |1
is obsolete||
  Attachment #74258|0   |1
is obsolete||
  Attachment #74259|0   |1
is obsolete||

--- Comment #20 from Kyle M Hall  ---
Created attachment 74343
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74343=edit
Bug 20568: API keys management in interface

This introduces the concept of API keys for use in the new REST API.
A key is a string of 32 alphanumerical characters (32 is purely
arbitrary, it can be changed easily).
A user can have multiple keys (unlimited at the moment)
Keys can be generated automatically, and then we have the possibility to
delete or revoke each one individually.

Test plan:
1/ Go to staff interface
2/ Go to a borrower page
3/ In toolbar, click on More -> Manage API keys
4/ Click on "Generate new key" multiple times, check that they are
   correctly displayed under the button, and they are active by default
5/ Revoke some keys, check that they are not active anymore
6/ Delete some keys, check that they disappear from table
7/ Go to opac interface, log in
8/ In your user account pages, you now have a new tab to the left "your
   API keys". Click on it.
9/ Repeat steps 4-6

Signed-off-by: Kyle M Hall 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-17 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Kyle M Hall  changed:

   What|Removed |Added

 Status|Needs Signoff   |Signed Off

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #19 from Tomás Cohen Arazi  ---
Created attachment 74259
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74259=edit
Bug 20568: Move value => client_id + secret

This patch addresses the request from Julian that api keys are expected
to be client id/secret pairs.

It does so by
- Adding 'client_id' and 'secret' columns
- Removing 'value'

Tests got adjusted and so controller scripts and templates.
Both libs and tests changes have been squashed. This ones remain in
order to keep Owen's attribution on the template changes and avoid
rebase conflicts.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74235|0   |1
is obsolete||

--- Comment #16 from Tomás Cohen Arazi  ---
Created attachment 74256
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74256=edit
Bug 20568: Unit tests

This patch adds unit tests for the introduced classes: Koha::ApiKey(s).

To test:
- Apply this patch
- Run
  $ kshell
 k$ prove t/db_dependent/Koha/ApiKeys.t
=> FAIL: Tests fail because the feature is not implemented.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74248|0   |1
is obsolete||

--- Comment #18 from Tomás Cohen Arazi  ---
Created attachment 74258
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74258=edit
Bug 20568 (follow-up) Interface and markup changes

This patch makes some interface changes to bring things better in line
with existing interface patterns. This patch also re-indents the
modified templates with 4 spaces instead of 2 and makes s
self-closing.

Also changed: Corrected system preference check in opac-apikeys.pl.

To test, apply the patch and:

In the staff client:

 - Open a patron record and choose More -> Manage API keys.
   - There should be a standard message dialog containing a link to
 "Generate a new key."
 - Clicking the link should show the form for adding a new key.
 - Test that clicking the "Cancel" link hides the form.
 - Test that creating the new key works correctly.
   - You should now see a table showing existing keys and a "Generate a
 new key" button above it.
 - Test that the "Delete" button asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.

In the OPAC:

 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Allow."
 - Log in to the OPAC and click the "your API keys" link in the sidebar.
   - Clicking the "Generate new key" button should display the form for
 adding a new key.
 - Clicking the "cancel" link should hide the form.
 - Submitting the form should add a new key.
   - You should now see a table showing existing keys.
 - Test that the "Delete" link asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.
 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Don't
   allow."
   - Log in to the OPAC and confirm that the "your API keys" link in the
 sidebar is no longer visible.
 - Confirm that navigating directly to /cgi-bin/koha/opac-apikeys.pl
   results in a 404 error.

Signed-off-by: Tomas Cohen Arazi 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74236|0   |1
is obsolete||

--- Comment #17 from Tomás Cohen Arazi  ---
Created attachment 74257
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74257=edit
Bug 20568: API key management for OPAC users

This patch makes the OPAC interface for API keys management work
with the new lib. Verify all actions work for a logged user.

Users without login should be redirected to an error page.

The AllowPatronsManageAPIKeysInOPAC syspref is added to control if the
OPAC feature is enabled or not.

To test:
- Verify the syspref works
- Verify users can manage their API keys

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74234|0   |1
is obsolete||

--- Comment #15 from Tomás Cohen Arazi  ---
Created attachment 74255
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74255=edit
Bug 20568: Add mandatory description field for api keys

This patch changes the table structure adding fields usually found on
this kind of api management pages.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74233|0   |1
is obsolete||

--- Comment #14 from Tomás Cohen Arazi  ---
Created attachment 74254
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74254=edit
Bug 20568: API keys management in interface

This introduces the concept of API keys for use in the new REST API.
A key is a string of 32 alphanumerical characters (32 is purely
arbitrary, it can be changed easily).
A user can have multiple keys (unlimited at the moment)
Keys can be generated automatically, and then we have the possibility to
delete or revoke each one individually.

Test plan:
1/ Go to staff interface
2/ Go to a borrower page
3/ In toolbar, click on More -> Manage API keys
4/ Click on "Generate new key" multiple times, check that they are
   correctly displayed under the button, and they are active by default
5/ Revoke some keys, check that they are not active anymore
6/ Delete some keys, check that they disappear from table
7/ Go to opac interface, log in
8/ In your user account pages, you now have a new tab to the left "your
   API keys". Click on it.
9/ Repeat steps 4-6

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #13 from Owen Leonard  ---
Created attachment 74248
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74248=edit
Bug 20568 (follow-up) Interface and markup changes

This patch makes some interface changes to bring things better in line
with existing interface patterns. This patch also re-indents the
modified templates with 4 spaces instead of 2 and makes s
self-closing.

Also changed: Corrected system preference check in opac-apikeys.pl.

To test, apply the patch and:

In the staff client:

 - Open a patron record and choose More -> Manage API keys.
   - There should be a standard message dialog containing a link to
 "Generate a new key."
 - Clicking the link should show the form for adding a new key.
 - Test that clicking the "Cancel" link hides the form.
 - Test that creating the new key works correctly.
   - You should now see a table showing existing keys and a "Generate a
 new key" button above it.
 - Test that the "Delete" button asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.

In the OPAC:

 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Allow."
 - Log in to the OPAC and click the "your API keys" link in the sidebar.
   - Clicking the "Generate new key" button should display the form for
 adding a new key.
 - Clicking the "cancel" link should hide the form.
 - Submitting the form should add a new key.
   - You should now see a table showing existing keys.
 - Test that the "Delete" link asks for confirmation, and that
   confirming and denying both work correctly.
 - Test that "Revoke" and "Activate" actions still work correctly.
 - Set the AllowPatronsManageAPIKeysInOPAC system preference to "Don't
   allow."
   - Log in to the OPAC and confirm that the "your API keys" link in the
 sidebar is no longer visible.
 - Confirm that navigating directly to /cgi-bin/koha/opac-apikeys.pl
   results in a 404 error.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74229|0   |1
is obsolete||

--- Comment #9 from Tomás Cohen Arazi  ---
Created attachment 74233
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74233=edit
Bug 20568: API keys management in interface

This introduces the concept of API keys for use in the new REST API.
A key is a string of 32 alphanumerical characters (32 is purely
arbitrary, it can be changed easily).
A user can have multiple keys (unlimited at the moment)
Keys can be generated automatically, and then we have the possibility to
delete or revoke each one individually.

Test plan:
1/ Go to staff interface
2/ Go to a borrower page
3/ In toolbar, click on More -> Manage API keys
4/ Click on "Generate new key" multiple times, check that they are
   correctly displayed under the button, and they are active by default
5/ Revoke some keys, check that they are not active anymore
6/ Delete some keys, check that they disappear from table
7/ Go to opac interface, log in
8/ In your user account pages, you now have a new tab to the left "your
   API keys". Click on it.
9/ Repeat steps 4-6

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74231|0   |1
is obsolete||

--- Comment #11 from Tomás Cohen Arazi  ---
Created attachment 74235
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74235=edit
Bug 20568: Unit tests

This patch adds unit tests for the introduced classes: Koha::ApiKey(s).

To test:
- Apply this patch
- Run
  $ kshell
 k$ prove t/db_dependent/Koha/ApiKeys.t
=> FAIL: Tests fail because the feature is not implemented.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74232|0   |1
is obsolete||

--- Comment #12 from Tomás Cohen Arazi  ---
Created attachment 74236
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74236=edit
Bug 20568: API key management for OPAC users

This patch makes the OPAC interface for API keys management work
with the new lib. Verify all actions work for a logged user.

Users without login should be redirected to an error page.

The AllowPatronsManageAPIKeysInOPAC syspref is added to control if the
OPAC feature is enabled or not.

To test:
- Verify the syspref works
- Verify users can manage their API keys

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74230|0   |1
is obsolete||

--- Comment #10 from Tomás Cohen Arazi  ---
Created attachment 74234
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74234=edit
Bug 20568: Add mandatory description field for api keys

This patch changes the table structure adding fields usually found on
this kind of api management pages.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

 Depends on|20402   |


Referenced Bugs:

https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20402
[Bug 20402] Implement OAuth2 authentication for REST API
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

 CC||tomasco...@gmail.com
 Status|ASSIGNED|Needs Signoff

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74180|0   |1
is obsolete||

--- Comment #6 from Tomás Cohen Arazi  ---
Created attachment 74230
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74230=edit
Bug 20568: Add mandatory description field for api keys

This patch changes the table structure adding fields usually found on
this kind of api management pages.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #8 from Tomás Cohen Arazi  ---
Created attachment 74232
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74232=edit
Bug 20568: API key management for OPAC users

This patch makes the OPAC interface for API keys management work
with the new lib. Verify all actions work for a logged user.

Users without login should be redirected to an error page.

The AllowPatronsManageAPIKeysInOPAC syspref is added to control if the
OPAC feature is enabled or not.

To test:
- Verify the syspref works
- Verify users can manage their API keys

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #7 from Tomás Cohen Arazi  ---
Created attachment 74231
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74231=edit
Bug 20568: Unit tests

This patch adds unit tests for the introduced classes: Koha::ApiKey(s).

To test:
- Apply this patch
- Run
  $ kshell
 k$ prove t/db_dependent/Koha/ApiKeys.t
=> FAIL: Tests fail because the feature is not implemented.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

  Attachment #74179|0   |1
is obsolete||

--- Comment #5 from Tomás Cohen Arazi  ---
Created attachment 74229
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74229=edit
Bug 20568: API keys management in interface

This introduces the concept of API keys for use in the new REST API.
A key is a string of 32 alphanumerical characters (32 is purely
arbitrary, it can be changed easily).
A user can have multiple keys (unlimited at the moment)
Keys can be generated automatically, and then we have the possibility to
delete or revoke each one individually.

Test plan:
1/ Go to staff interface
2/ Go to a borrower page
3/ In toolbar, click on More -> Manage API keys
4/ Click on "Generate new key" multiple times, check that they are
   correctly displayed under the button, and they are active by default
5/ Revoke some keys, check that they are not active anymore
6/ Delete some keys, check that they disappear from table
7/ Go to opac interface, log in
8/ In your user account pages, you now have a new tab to the left "your
   API keys". Click on it.
9/ Repeat steps 4-6

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-16 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Julian Maurice  changed:

   What|Removed |Added

 CC||julian.maur...@biblibre.com

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-13 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED

--- Comment #4 from Tomás Cohen Arazi  ---
I've attached my WIP stuff just in case anyone wants to comment on that.
I basically resurrected one patch from Julian from bug 13920 (API keys
management in interface) and worked on adapting it to current practices.

The staff interface api management page is fully functional. OPAC is next.
Unit tests almost ready, not submitted.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-13 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #2 from Tomás Cohen Arazi  ---
Created attachment 74179
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74179=edit
Bug 20568: API keys management in interface

This introduces the concept of API keys for use in the new REST API.
A key is a string of 32 alphanumerical characters (32 is purely
arbitrary, it can be changed easily).
A user can have multiple keys (unlimited at the moment)
Keys can be generated automatically, and then we have the possibility to
delete or revoke each one individually.

Test plan:
1/ Go to staff interface
2/ Go to a borrower page
3/ In toolbar, click on More -> Manage API keys
4/ Click on "Generate new key" multiple times, check that they are
   correctly displayed under the button, and they are active by default
5/ Revoke some keys, check that they are not active anymore
6/ Delete some keys, check that they disappear from table
7/ Go to opac interface, log in
8/ In your user account pages, you now have a new tab to the left "your
   API keys". Click on it.
9/ Repeat steps 4-6

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-13 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

--- Comment #3 from Tomás Cohen Arazi  ---
Created attachment 74180
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74180=edit
Bug 20568: Add mandatory description field for api keys

This patch changes the table structure adding fields usually found on
this kind of api management pages.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-11 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

David Cook  changed:

   What|Removed |Added

 CC||dc...@prosentient.com.au

--- Comment #1 from David Cook  ---
Looking forward to this. I've wanted this for a while.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-11 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

   Assignee|koha-b...@lists.koha-commun |tomasco...@gmail.com
   |ity.org |

-- 
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 20568] Add API key management interface for patrons

2018-04-11 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20568

Tomás Cohen Arazi  changed:

   What|Removed |Added

 Depends on||20402
   See Also||https://bugs.koha-community
   ||.org/bugzilla3/show_bug.cgi
   ||?id=13920


Referenced Bugs:

https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20402
[Bug 20402] Implement OAuth2 authentication for REST API
-- 
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/