Skip to main content

disabling SSL in windows

1.Press win+R
2.Type regedit



3.go to

 Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 2.0\Client






set the Dword value to 1 for enabling SSL client and 0 to disable

Comments

Popular posts from this blog

Java function to read from sql database

 public static ResultSet sqlread(String S){       ResultSet rs = null;        try     {       // create a mysql database connection       String myUrl = "jdbc:mysql://localhost:3306/firewall?zeroDateTimeBehavior=convertToNull";       Class.forName("com.mysql.jdbc.Driver");       Connection conn = DriverManager.getConnection(myUrl, "root", "Cns@54321");             Statement st = conn.createStatement();       // note that i'm leaving "date_created" out of this insert statement         rs = st.executeQuery(S);           }        catch (Exception e)     {       System.err.println("Got an exception!");       System.err.println(e.getMessage());     }        return rs;   } 

Encryption and Decryption functions for Java

    public static String encrypt(String key, String initVector, String value) {         try {             IvParameterSpec iv = new IvParameterSpec(initVector.getBytes("UTF-8"));             SecretKeySpec skeySpec = new SecretKeySpec(key.getBytes("UTF-8"), "AES");             Cipher cipher = Cipher.getInstance("AES/CBC/PKCS5PADDING");             cipher.init(Cipher.ENCRYPT_MODE, skeySpec, iv);             byte[] encrypted = cipher.doFinal(value.getBytes());             System.out.println("encrypted string: "                     + Base64.encodeBase64String(encrypted));             return Base64.encodeBase64String(encrypted);         } catch (Exception ex) {   ...