Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x509-validation: Export doValidate and no IO #99

Open
ch1bo opened this issue Jul 19, 2018 · 1 comment
Open

x509-validation: Export doValidate and no IO #99

ch1bo opened this issue Jul 19, 2018 · 1 comment

Comments

@ch1bo
Copy link

ch1bo commented Jul 19, 2018

Hi,

I am using validate from x509-validation package in an otherwise pure (no IO) scenario. After looking at the code I would be interested in accessing doValidate and pass in the current DateTime or not use that at all (disabling the check).

Would you be open about a PR where doValidate is exported and changed to something like:

doValidate :: Monad m => DateTime
           -> ValidationHooks
           -> ValidationChecks
           -> CertificateStore
           -> ServiceID
           -> CertificateChain
           -> m [FailedReason]

As far as I could tell there is no reason to have this lower-level checking function run in IO.

Thanks for creating these packages!

@infinisil
Copy link
Contributor

I made a PR for this here: #126

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants