Skip to content
Snippets Groups Projects
Commit 51d027cf authored by Demian Katz's avatar Demian Katz
Browse files

Added option to disable SSL verification in OAI harvesting.

parent 8687bb0e
No related merge requests found
......@@ -16,6 +16,7 @@
; dateGranularity = auto
; harvestedIdLog = harvest.log
; verbose = false
; sslverifypeer = true
;
; The section_name may be passed to harvest_oai.php as a parameter to harvest only
; records from that source. This is also the directory name that records will be
......@@ -74,6 +75,9 @@
; verbose may be set to true in order to display more detailed output while
; harvesting; this may be useful for troubleshooting purposes, but it defaults to
; false.
;
; sslverifypeer may be set to false to disable SSL certificate checking; it defaults
; to true, and changing the setting is not recommended.
; SAMPLE CONFIGURATION FOR OPEN JOURNAL SYSTEMS
;[OJS]
......
......@@ -194,6 +194,11 @@ class OAI
// Store client:
$this->client = $client;
// Disable SSL verification if requested:
if (isset($settings['sslverifypeer']) && !$settings['sslverifypeer']) {
$this->client->setOptions(array('sslverifypeer' => false));
}
// Don't time out during harvest!!
set_time_limit(0);
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment