if(!decryptedText.Contains("?")||...lots)
{
continue;
}
Results.Add(decryptedText);
但是它要么什么都不显示,要么仅显示大量不正确的结果。我还尝试将其全部转换为ASCII,但它给出的结果数百万几乎相同和相同。
var textoLimpio = LimpiarASCII.ReturnCleanASCII(decryptedText);
所以我想知道是否有更好的方法来摆脱充满未知非ASCII字符的乱码结果>我想验证的代码
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.IO; using System.Collections; namespace ProyectoEspiasSergioSolorzanoAriste { class Program { static void Main(string[] args) { var encryptedText = "7iuYS0z/aIp/f+dNjJCkLULBY+3K5F3B4BYBSNoKEc0g8M3lcFFECqHMb2E9rv12sUCjJA/ve1uCxGNL/feZjEFBpANh0tAs/5+97+L+kuL0wZI78Ux40XhEbyTSIoEfGY4GsM7uce7PzZ1sYSb9Kql/0j6Qu9RGWXqJMPF9XYYv5FxgNLJ8y8bzoGcZVf6h7k95a5YoX6KP9T20TMPJcqUf+nEYTo2Y54K6vU8pAUC0UxTnLlxakzCT+QBIhXl0SRS6/36rbkSppNYd0GLq5HRN+/BEFvGF+0p9fRZQ5hyqEmy8OEFqFtSBeA0LotyszSHq1ZqJA56rqXjoSZZm6ljcITolbx101eNH7x0S1zjzNv1dovIsaONQfbt6ZUlldxFDSVrQrTrsso32LIO8JWGsUCp6mc8VhL5hAA8xY7d8cwSoDzlm7+46fqP6pEnL/dArS9As+vE6ZWh+JYmDQJ5pEs2KDEVTQb5o4rFB79QE8EmmysvsC23baZXsO5Qa1GqeMcUZ2mORTHUs1GTKhqY1DpOGtXbykpXs+0RlmNzvIEASf5yOqOnHOvhzxGGzjvrEiAc61t6DB/frmGlokVZEuZcziwcb883jCRwXOb21R/AtCaf4A1VHbVq/xoeS/XRExgOle6xZGibNMUHrvprtnj9Hhdwz4H0p6m6T3sR6GAzhzAl12MzMdG4VM6QFJsSND5nNQRlHByYTZ5ebWTupKbSIDPCaOu4FydZuJj4="; Console.WriteLine("After Encryption Text = " + encryptedText); var solucionesDecrypt = new List<string>(0xFFFFFF); //Presize the list to hold all the values. for (int i = 0; i <= 0xFFFFFF; i++) { var decryptedText = ClsTripleDES.Decrypt(encryptedText, i.ToString("X6")); //eliminar los caracteres improvables //if (!decryptedText.Contains("&") || !decryptedText.Contains("?") || !decryptedText.Contains("/") || !decryptedText.Contains("") || !decryptedText.Contains("") || !decryptedText.Contains("@") || !decryptedText.Contains("%") || !decryptedText.Contains("'") || !decryptedText.Contains("") || !decryptedText.Contains("") || !decryptedText.Contains("") || !decryptedText.Contains("?_") || !decryptedText.Contains("_") || !decryptedText.Contains("??") || !decryptedText.Contains("|") || !decryptedText.Contains("}") || !decryptedText.Contains("{") || !decryptedText.Contains("~") || !decryptedText.Contains("#") || !decryptedText.Contains("=") || !decryptedText.Contains("+") || !decryptedText.Contains("%") || !decryptedText.Contains("<") || !decryptedText.Contains(">") || !decryptedText.Contains(":") || !decryptedText.Contains("[") || !decryptedText.Contains("]")) //{ // continue; //} //pasa todos los caracteres a ASCII, y si es un mensaje normal será ya en ASCII, por lo que no afectará al mensaje correcto supongo //var textoLimpio = LimpiarASCII.ReturnCleanASCII(decryptedText); //if (!textoLimpio.Contains("&") || !textoLimpio.Contains("?") || !textoLimpio.Contains("/") || !textoLimpio.Contains("") || !textoLimpio.Contains("") || !textoLimpio.Contains("@") || !textoLimpio.Contains("%") || !textoLimpio.Contains("'") || !textoLimpio.Contains("") || !textoLimpio.Contains("") || !textoLimpio.Contains("") || !textoLimpio.Contains("?_") || !textoLimpio.Contains("_") || !textoLimpio.Contains("??") || !textoLimpio.Contains("|") || !textoLimpio.Contains("}") || !textoLimpio.Contains("{") || !textoLimpio.Contains("~") || !textoLimpio.Contains("#") || !textoLimpio.Contains("=") || !textoLimpio.Contains("+") || !textoLimpio.Contains("%") || !textoLimpio.Contains("<") || !textoLimpio.Contains(">") || !textoLimpio.Contains(":") || !textoLimpio.Contains("[") || !textoLimpio.Contains("]")) //{ // continue; //} if (!decryptedText.Contains("?")) { continue; } solucionesDecrypt.Add(decryptedText);//(decryptedText); } Console.WriteLine("Start"); foreach (string decryptedText in solucionesDecrypt) //(string decryptedText in solucionesDecrypt) { //if (!textoLimpio.Contains("?")) { // continue; //} Console.WriteLine("After Decryption Text = " + decryptedText); } Console.WriteLine("FIN DEL PROGRAMA"); Console.ReadLine(); } } }
我希望stackoverflow的众神最终认为我做了一个适当的问题,不要在几分钟后抹去或投赞成票,请告诉我我是否正确解释了一些内容,以便下次学习。我有一个程序可以检查数以百万计的结果以强制使用3DES密码,但我希望它向我显示正确的密码,而不是数以百万计的乱码结果,所以我想到了...