{"action":"created","issue":{"url":"https://api.github.com/repos/Arabidopsis-Information-Portal/adama/issues/99","labels_url":"https://api.github.com/repos/Arabidopsis-Information-Portal/adama/issues/99/labels{/name}","comments_url":"https://api.github.com/repos/Arabidopsis-Information-Portal/adama/issues/99/comments","events_url":"https://api.github.com/repos/Arabidopsis-Information-Portal/adama/issues/99/events","html_url":"https://github.com/Arabidopsis-Information-Portal/adama/issues/99","id":126966310,"number":99,"title":"Accessing Phytozome vista_rest adapter encounters SSLError","user":{"login":"vivekkrish","id":711637,"avatar_url":"https://avatars.githubusercontent.com/u/711637?v=3","gravatar_id":"","url":"https://api.github.com/users/vivekkrish","html_url":"https://github.com/vivekkrish","followers_url":"https://api.github.com/users/vivekkrish/followers","following_url":"https://api.github.com/users/vivekkrish/following{/other_user}","gists_url":"https://api.github.com/users/vivekkrish/gists{/gist_id}","starred_url":"https://api.github.com/users/vivekkrish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vivekkrish/subscriptions","organizations_url":"https://api.github.com/users/vivekkrish/orgs","repos_url":"https://api.github.com/users/vivekkrish/repos","events_url":"https://api.github.com/users/vivekkrish/events{/privacy}","received_events_url":"https://api.github.com/users/vivekkrish/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Arabidopsis-Information-Portal/adama/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2016-01-15T21:56:24Z","updated_at":"2016-01-15T22:45:22Z","closed_at":null,"body":"We are now utilizing Phytozome JBrowse vista_rest endpoint to power the VISTA conservation tracks in our Araport JBrowse. [Example](https://apps.araport.org/jbrowse/?data=arabidopsis&loc=Chr1:8146351..8150178&tracks=TAIR10_genome,Araport11_Loci,Araport11_gene_models,Vista_Alyrata)\r\n\r\nWe access their endpoint via an Araport passthrough adapter, which is defined by this [metadata.yml](https://github.com/Arabidopsis-Information-Portal/phytozome_webservices/blob/master/services/vista_rest/metadata.yml).\r\n\r\nHere is an example API call:\r\n```\r\n$ curl -v -H \"Authorization: Bearer $TOKEN\" \"https://api.araport.org/community/v0.3/phytozome/vista_rest_v0.2/access/features/Chr1?start=23058437&end=23059296&vista_base_id=611&target_id=962&target_run=660\"\r\n```\r\n\r\nThe passthrough adapter makes a request to Phytozome, before which the request URL is transformed into https://phytozome.jgi.doe.gov/jbrowse/vista_rest/features/Chr1?start=23058437&end=23059296&vista_base_id=611&target_id=962&target_run=660\r\n\r\nA successful request to the above URL should return valid JSON back to our JBrowse.\r\n\r\nRight around the time of PAG, all Phytozome services have now started using secure HTTP (https).\r\nHowever, since the change, we have started seeing the following SSLError:\r\n```\r\n{\r\n  \"exception\": \"SSLError\",\r\n  \"message\": \"hostname 'phytozome.jgi.doe.gov' doesn't match either of '*.nersc.gov', 'nersc.gov'\",\r\n  \"status\": \"error\",\r\n  \"worker_trace\": null\r\n}\r\n```\r\nBy default, we leave SSL certificate verification turned on.\r\n\r\nThe above error is produced by the python requests module, when the SSL certificate verification failed to match the certificate the server responds with, to the hostname (http://docs.python-requests.org/en/latest/community/faq/#what-are-hostname-doesn-t-match-errors)\r\n\r\nI have sent a request to the Phytozome team, asking them to check if the wildcard certificate installed on their server matches the hostname of their application.\r\n\r\nIn the meanwhile, could we implement a flag in ADAMA, triggered via an entry in `metadata.yml`, which can be used to **turn of*f* certificate verification. Something like:\r\n```\r\n---\r\n\r\nname: vista_rest\r\nversion: 0.2\r\ndescription: Passthrough adapter for Phytozome JBrowse REST endpoint serving VISTA alignments\r\ntype: passthrough\r\nurl: https://phytozome.jgi.doe.gov/jbrowse/vista_rest\r\nwhitelist:\r\n  - phytozome.jgi.doe.gov\r\n\r\nverify_certificate: false\r\n```\r\n\r\nAny downsides to having this functionality?"},"comment":{"url":"https://api.github.com/repos/Arabidopsis-Information-Portal/adama/issues/comments/172116922","html_url":"https://github.com/Arabidopsis-Information-Portal/adama/issues/99#issuecomment-172116922","issue_url":"https://api.github.com/repos/Arabidopsis-Information-Portal/adama/issues/99","id":172116922,"user":{"login":"vivekkrish","id":711637,"avatar_url":"https://avatars.githubusercontent.com/u/711637?v=3","gravatar_id":"","url":"https://api.github.com/users/vivekkrish","html_url":"https://github.com/vivekkrish","followers_url":"https://api.github.com/users/vivekkrish/followers","following_url":"https://api.github.com/users/vivekkrish/following{/other_user}","gists_url":"https://api.github.com/users/vivekkrish/gists{/gist_id}","starred_url":"https://api.github.com/users/vivekkrish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vivekkrish/subscriptions","organizations_url":"https://api.github.com/users/vivekkrish/orgs","repos_url":"https://api.github.com/users/vivekkrish/repos","events_url":"https://api.github.com/users/vivekkrish/events{/privacy}","received_events_url":"https://api.github.com/users/vivekkrish/received_events","type":"User","site_admin":false},"created_at":"2016-01-15T22:45:22Z","updated_at":"2016-01-15T22:45:22Z","body":"Thanks, Matt, I think it's best we allow for this flexibility.\r\n\r\nIncidentally, since PAG, we've started experiencing issues with a WSO2 adapter we are (still) using in ThaleMine, which points to Phytomine (also served via phytozome.jgi.doe.gov). Unfortunately, since it is WSO2, we are unable to see the errors on the server. The passthrough URL is https://api.araport.org/data/phytozome_intermine/v1.0.1.\r\n\r\nWe couldn't use ADAMA since the InterMine imtables infrastructure didn't support sending custom request headers. Josh (from the InterMine team) has recently fixed this issue per our request. So I'm hoping to replace the WSO2 URL with an ADAMA URL."}}