Jump to Real's How-to Main page

Detect if the connection is possible via a secure channel

To see what JavaScript can tell you about Navigator, use this statement:
for (i in navigator) alert(i + " = " + navigator[i])
If the appVersion (or the userAgent) property end with ;U which designates USA/Canada, the browser has the 128-bit strong encryption.

If the property ends with ";I" which designates International, then the browser _probably_ does not.

  var encryption =
    navigator.appName != 'Netscape' ? 'unknown' :
    navigator.userAgent.indexOf(' U') != -1 ? 'strong' : 'weak';
Note: for a java solution see this HowTo
If you find this article useful, consider making a small donation
to show your supportfor this Web site and its content.

Written and compiled by Réal Gagnon ©1998-2005
[ home ]