i need to get value which first 16 characters are TZxy2o2h2I2NMVR+ for which I have a formula. The formula goes like this: Base64(XOR("KonstantaZaLDAP", MD5(521009)) + XOR(521009, "KonstantaZaLDAP")) or in a word:

I have two values:

int radID = 521009

String konst = "KonstantaZaLDAP"

The first step is to apply XOR operation to konst and MD5 hash value of konst >>XOR(kost, MD5(radID))

After that i should concatenate values from first and second step >> XOR(kost, MD5(radID)) + XOR(radID, konst) and finaly Base64 encode concatenated value.
That is Base64(XOR(konst, MD5(radID)) + XOR(radID, konst)).

I have tried to achieve wanted value, and whatever I do, I get first 13 characters right, and after that it's all wrong. The value I get is TZxy2o2h2l2NMfUfpPmJNA==