https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=42517

--- Comment #12 from Martin Renvoize (ashimema) 
<[email protected]> ---
Created attachment 202097
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=202097&action=edit
Bug 42517: (QA follow-up) Address QA review findings

This patch addresses points raised during QA review:

* Make the atomicupdate file executable (koha-qa file_permissions)
* Add strict_host_key_checking to the config fields list in
  Koha::File::Transport->store so editing the option triggers the
  automatic connection re-test the confirmation modal promises
* Make the confirmation modal message reflect the selected strict
  host key checking value ('yes' will never auto-accept a host key)
  and fix the "servers" typo while we're there
* Preserve the stored strict_host_key_checking value when editing a
  non-SFTP transport: the select is disabled for those transports so
  the parameter is not submitted, and the value was silently reset
  to 'no' (the least secure option)
* Validate strict_host_key_checking at store time, following the
  pattern from bug 39224, so an invalid value can never be persisted
  regardless of how the field was populated (admin form,
  set_from_api or a direct accessor call)
* Cover the new field in the REST API tests (valid values roundtrip,
  invalid values are rejected) and cover the store-time validation
  in Transport.t

Test plan:
1. prove t/db_dependent/Koha/File/Transport.t \
     t/db_dependent/Koha/File/Transport/SFTP.t \
     t/db_dependent/api/v1/file_transports.t
   => SUCCESS: all green (yarn api:bundle first if the spec bundle
   is stale)
2. Edit an SFTP transport, set strict host key checking to
   'accept-new', switch the transport to FTP and save; edit again
   => SUCCESS: the stored value is preserved rather than being
   silently reset to 'no'
3. Edit an SFTP transport and cycle the strict host key checking
   select before saving
   => SUCCESS: the confirmation modal message reflects the selected
   value

Signed-off-by: Martin Renvoize <[email protected]>

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to