Bug 17336 - api_secret_passphrase missing in packages setup
Summary: api_secret_passphrase missing in packages setup
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Web services (show other bugs)
Version: Main
Hardware: All All
: P5 - low major
Assignee: Tomás Cohen Arazi (tcohen)
QA Contact: Testopia
URL:
Keywords:
Depends on: 13799 17332
Blocks:
  Show dependency treegraph
 
Reported: 2016-09-23 14:54 UTC by Tomás Cohen Arazi (tcohen)
Modified: 2021-09-20 13:26 UTC (History)
6 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 17336: Add api_secret_passphrase entry in packages setup (2.75 KB, patch)
2016-09-23 15:00 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 17336: Add api_secret_passphrase entry in packages setup (2.80 KB, patch)
2016-09-26 08:53 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 17336: Add api_secret_passphrase entry in packages setup (2.86 KB, patch)
2016-09-26 18:44 UTC, Kyle M Hall (khall)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Tomás Cohen Arazi (tcohen) 2016-09-23 14:54:00 UTC
Bug 13799 introduced the api_secret_passphrase on source installs, but missed to do so on packages.
Comment 1 Tomás Cohen Arazi (tcohen) 2016-09-23 15:00:50 UTC
Created attachment 55778 [details] [review]
Bug 17336: Add api_secret_passphrase entry in packages setup

Bug 13799 introduced the api_secret_passphrase on source installs, but missed to do so on packages.

This patch introduces the entry on the template koha-conf-site.xml.in file, and
patches koha-create so it generates a randomized string (64 chars) to put in it.

To test:
- Apply the patch
- Grab the new template file:
  $ sudo cp kohaclone/debian/templates/koha-conf-site.xml.in \
            /etc/koha
- Create a new instance:
  $ kohaclone/debian/scripts/koha-create --create-db blah
=> SUCCESS: The script runs fine, /etc/koha/sites/blah/koha-conf.xml
   contains the api_secret_passphrase entry.
- Sign off :-D
Comment 2 Chris Cormack 2016-09-23 20:09:17 UTC
Applying: Bug 17336: Add api_secret_passphrase entry in packages setup
fatal: sha1 information is lacking or useless (debian/templates/koha-conf-site.xml.in).
error: could not build fake ancestor
Patch failed at 0001 Bug 17336: Add api_secret_passphrase entry in packages setup
Comment 3 Tomás Cohen Arazi (tcohen) 2016-09-23 20:36:49 UTC
Sorry, forgot I wrote it on top of 17332
Comment 4 Josef Moravec 2016-09-26 08:53:07 UTC
Created attachment 55818 [details] [review]
Bug 17336: Add api_secret_passphrase entry in packages setup

Bug 13799 introduced the api_secret_passphrase on source installs, but missed to do so on packages.

This patch introduces the entry on the template koha-conf-site.xml.in file, and
patches koha-create so it generates a randomized string (64 chars) to put in it.

To test:
- Apply the patch
- Grab the new template file:
  $ sudo cp kohaclone/debian/templates/koha-conf-site.xml.in \
            /etc/koha
- Create a new instance:
  $ kohaclone/debian/scripts/koha-create --create-db blah
=> SUCCESS: The script runs fine, /etc/koha/sites/blah/koha-conf.xml
   contains the api_secret_passphrase entry.
- Sign off :-D

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Comment 5 Kyle M Hall (khall) 2016-09-26 18:44:24 UTC
Created attachment 55830 [details] [review]
Bug 17336: Add api_secret_passphrase entry in packages setup

Bug 13799 introduced the api_secret_passphrase on source installs, but missed to do so on packages.

This patch introduces the entry on the template koha-conf-site.xml.in file, and
patches koha-create so it generates a randomized string (64 chars) to put in it.

To test:
- Apply the patch
- Grab the new template file:
  $ sudo cp kohaclone/debian/templates/koha-conf-site.xml.in \
            /etc/koha
- Create a new instance:
  $ kohaclone/debian/scripts/koha-create --create-db blah
=> SUCCESS: The script runs fine, /etc/koha/sites/blah/koha-conf.xml
   contains the api_secret_passphrase entry.
- Sign off :-D

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 6 Kyle M Hall (khall) 2016-09-27 10:31:06 UTC
Pushed to master for 16.11, thanks Tomas!