CSharp · Console
using System;
using System.IO;
using System.Security.Cryptography;
using System.Xml;
namespace Rextester{
public class Program{
public static void Main(string[] args){
string sx = @"<?xml version=""1.0"" encoding=""ISO-8859-2""?>
<tabela_kursow typ=""A"" uid=""20a219"">
<numer_tabeli>219/A/NBP/2020</numer_tabeli>
<data_publikacji>2020-11-09</data_publikacji>
<pozycja>
<nazwa_waluty>bat (Tajlandia)</nazwa_waluty>
<przelicznik>1</przelicznik>
<kod_waluty>THB</kod_waluty>
<kurs_sredni>0,1236</kurs_sredni>
</pozycja>
<pozycja>
<nazwa_waluty>dolar amerykanski</nazwa_waluty>
<przelicznik>1</przelicznik>
<kod_waluty>USD</kod_waluty>
<kurs_sredni>3,7787</kurs_sredni>
</pozycja>
</tabela_kursow>";
XmlDocument xmlDoc = new XmlDocument();
xmlDoc.Load(new System.IO.StringReader(sx));
foreach (XmlNode node in xmlDoc.SelectNodes("//pozycja[contains('THB', kod_waluty)]"))
{
Console.WriteLine("{0}: {1}", node.Name, node.InnerText);
}
//Console.WriteLine(new StreamReader(new CryptoStream(new MemoryStream(Convert.FromBase64String("VOXl2zUXff9fqZtxQ06PxH3gkH13LLIR/H/DArtIJN2oyZByoeiiJit/XiLM3LL3G/z0/5IjK/YUkYgv1pOb6TxQ==")), new System.Security.Cryptography.RijndaelManaged{Key=System.Text.Encoding.UTF8.GetBytes("shoplogix!!!!!!!"),IV=new byte[16]}.CreateDecryptor(),CryptoStreamMode.Read)).ReadToEnd());
}
}
}