<commit_before>package cliente;

import java.security.MessageDigest;
import java.util.Arrays;
import javax.crypto.Cipher;
import javax.crypto.SecretKey;
import javax.crypto.spec.SecretKeySpec;
import org.apache.commons.codec.binary.Base64;

public class Encriptador {

    public static String Encriptar(String texto, String secretKey)
	{
        String base64EncryptedString = "";

        try
		{
            MessageDigest md = MessageDigest.getInstance("MD5");
            byte[] digestOfPassword = md.digest(secretKey.getBytes("utf-8"));
            byte[] keyBytes = Arrays.copyOf(digestOfPassword, 24);

            SecretKey key = new SecretKeySpec(keyBytes, "DESede");
            Cipher cipher = Cipher.getInstance("DESede");
            cipher.init(Cipher.ENCRYPT_MODE, key);

            byte[] plainTextBytes = texto.getBytes("utf-8");
            byte[] buf = cipher.doFinal(plainTextBytes);
            byte[] base64Bytes = Base64.encodeBase64(buf);
            base64EncryptedString = new String(base64Bytes);
        }
		catch (Exception ex)
		{}
		
        return base64EncryptedString;
    }

    public static String Desencriptar(String textoEncriptado, String secretKey)
	{
        String base64EncryptedString = "";

        try
		{
            byte[] message = Base64.decodeBase64(textoEncriptado.getBytes("utf-8"));
            MessageDigest md = MessageDigest.getInstance("MD5");
            byte[] digestOfPassword = md.digest(secretKey.getBytes("utf-8"));
            byte[] keyBytes = Arrays.copyOf(digestOfPassword, 24);
            SecretKey key = new SecretKeySpec(keyBytes, "DESede");

            Cipher decipher = Cipher.getInstance("DESede");
            decipher.init(Cipher.DECRYPT_MODE, key);

            byte[] plainText = decipher.doFinal(message);

            base64EncryptedString = new String(plainText, "UTF-8");
        }
		catch (Exception ex)
		{}
		
        return base64EncryptedString;
    }
}<commit_msg>Agregado ciframiento Cesar<commit_after>package cliente;

import java.io.UnsupportedEncodingException;
import java.security.MessageDigest;
import java.util.Arrays;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.crypto.Cipher;
import javax.crypto.SecretKey;
import javax.crypto.spec.SecretKeySpec;
import org.apache.commons.codec.binary.Base64;

public class Encriptador {

    public static String Encriptar(String texto, String secretKey)
	{
        String base64EncryptedString = "";

        try
		{
            MessageDigest md = MessageDigest.getInstance("MD5");
            byte[] digestOfPassword = md.digest(secretKey.getBytes("utf-8"));
            byte[] keyBytes = Arrays.copyOf(digestOfPassword, 24);

            SecretKey key = new SecretKeySpec(keyBytes, "DESede");
            Cipher cipher = Cipher.getInstance("DESede");
            cipher.init(Cipher.ENCRYPT_MODE, key);

            byte[] plainTextBytes = texto.getBytes("utf-8");
            byte[] buf = cipher.doFinal(plainTextBytes);
            byte[] base64Bytes = Base64.encodeBase64(buf);
            base64EncryptedString = new String(base64Bytes);
        }
		catch (Exception ex)
		{}
		
        return base64EncryptedString;
    }

    public static String Desencriptar(String textoEncriptado, String secretKey)
	{
        String base64EncryptedString = "";

        try
		{
            byte[] message = Base64.decodeBase64(textoEncriptado.getBytes("utf-8"));
            MessageDigest md = MessageDigest.getInstance("MD5");
            byte[] digestOfPassword = md.digest(secretKey.getBytes("utf-8"));
            byte[] keyBytes = Arrays.copyOf(digestOfPassword, 24);
            SecretKey key = new SecretKeySpec(keyBytes, "DESede");

            Cipher decipher = Cipher.getInstance("DESede");
            decipher.init(Cipher.DECRYPT_MODE, key);

            byte[] plainText = decipher.doFinal(message);

            base64EncryptedString = new String(plainText, "UTF-8");
        }
		catch (Exception ex)
		{}
		
        return base64EncryptedString;
    }
	
	public static String encriptarCesar(String msg, int d)
	{
		byte[] msgBytes = msg.getBytes();
		for (int i = 0; i < msgBytes.length; i++) msgBytes[i] += d;
		
		String msgEncriptado;
		try { msgEncriptado = new String(msgBytes, "UTF-8"); }
		catch (UnsupportedEncodingException ex) { msgEncriptado = "";}
		
		return msgEncriptado;
	}
	
	public static String desencriptarCesar(String msg, int d)
	{
		return encriptarCesar(msg, -d);
	}
	
	public static void main(String[] args)
	{
		String msg = "Hola! Esta es una prueba de ciframiento Cesar.";
		String encrypted = encriptarCesar(msg, 2);
		String desencrypted = desencriptarCesar(encrypted, 2);
		
		System.out.println(encrypted);
		System.out.println(desencrypted);
	}
}
{'fraction_non_alphanumeric': 0.10985087166561647, 'fraction_numerical': 0.01638311279143037, 'mean_word_length': 2.961730449251248, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5690691', 'n_tokens_mistral': 1526, 'n_tokens_neox': 1396, 'n_words': 293}