Post by bobowk on Feb 18, 2017 12:41:02 GMT 10
I was wondering.... Wat is the wekomendead amount of dedtoted wam I should hav on my surverrr.... Jokes, anyway.... I was wondering how I can get the website secrity info by pressing on a green lock which is a button. How can i get what encryption the website has and the cookies and all that. An example is the green 🔒 on Google Chrome. Thankssss!
|
|
Post by Nathan Lecompte on Feb 18, 2017 13:52:19 GMT 10
In Awesomium it has a function to retrieve all that sort of information, but I don't think CEFSharp does unfortunately :/
|
|
Post by altair on Feb 24, 2017 1:56:44 GMT 10
Basically, HTTPS is just an issuing of SSL certificates... Just fetch it and see To say that they are secure just verify the expiry date... (I am not really sure though) Here is a sample code... ( I am sorry its C# but VB is weird to me now )
using System.Security; using System.Security.Cryptography; using System.Security.Cryptography.X509Certificates;
//Do webrequest to get info on secure site HttpWebRequest request = (HttpWebRequest)WebRequest.Create("https://mail.google.com"); HttpWebResponse response = (HttpWebResponse)request.GetResponse(); response.Close();
//retrieve the ssl cert and assign it to an X509Certificate object X509Certificate cert = request.ServicePoint.Certificate;
//convert the X509Certificate to an X509Certificate2 object by passing it into the constructor X509Certificate2 cert2 = new X509Certificate2(cert);
string cn = cert2.GetIssuerName(); string cedate = cert2.GetExpirationDateString(); string cpub = cert2.GetPublicKeyString();
//display the cert dialog box X509Certificate2UI.DisplayCertificate(cert2);
|
|