Coder Social home page Coder Social logo

Comments (11)

felicienfrancois avatar felicienfrancois commented on July 26, 2024 1

Works well now. Thank you !

from ssl-checker.

felicienfrancois avatar felicienfrancois commented on July 26, 2024

Basically, you should rely on response.socket.authorized which already contains result of validation

from ssl-checker.

dyaa avatar dyaa commented on July 26, 2024

@felicienfrancois are we talking about this case https://wrong.host.badssl.com/

from ssl-checker.

felicienfrancois avatar felicienfrancois commented on July 26, 2024

@dyaa Exactly.
Using response.socket.authorized may also cover other cases of "invalid certificates"

from ssl-checker.

dyaa avatar dyaa commented on July 26, 2024

So, You expect if the response.socket.authorized was false to return an error instead of returning the remaining date? @felicienfrancois

from ssl-checker.

felicienfrancois avatar felicienfrancois commented on July 26, 2024

@dyaa yes because in this case the certificate is invalid.

from ssl-checker.

dyaa avatar dyaa commented on July 26, 2024

in this case the expired domain will fail as well, Currently we return the data object with negative days_remaining.

from ssl-checker.

felicienfrancois avatar felicienfrancois commented on July 26, 2024

I suggest to add a field to returned payload so it won't makes any braking changes.
Example :

{
	"valid" : true, // whether certificate pass ssl validation or not
	"days_remaining" : 90,
	"valid_from" : "issue date",
	"valid_to" : "expiry date"
}

from ssl-checker.

dyaa avatar dyaa commented on July 26, 2024

Published a new version [email protected] with these changes, Please Verify.

from ssl-checker.

felicienfrancois avatar felicienfrancois commented on July 26, 2024

@dyaa now I get an SyntaxError: Unexpected token import at index.js:3
It seems that you changed require to import which is not supported natively on my node version (8.9.3).

from ssl-checker.

dyaa avatar dyaa commented on July 26, 2024

Done, Check [email protected]

from ssl-checker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.