본문 바로가기
IT 이모저모

[SAP PO] channel password 복호화

by DSEM 2022. 12. 27.
728x90
728x90

[SAP PO channel password 복호화]

 

SimpleQuery API를 통해 Channel password 조회한다. (encrypted data)
Directory objects: http(s)://<host>:<port>/dir/support/SimpleQuery

 

암호화된 데이타를 복호화 작업한다.
Convert Encrypted Data to Decrypted Data 
public static void main(String[] args) throws Exception {

String encryptedData = "XXXXXXX~~~";
byte[] aByteArray = Base64.getDecoder().decode(encryptedData);
int len = aByteArray.length;

byte[] result = new byte[len - 1];
for (int i = 1; i < len; i++) {
           result[(len - 1 - i)] = ((byte)(aByteArray[i] ^ 0x74));
}
String decryptedData = new String(result);
System.out.println(decryptedData);
}

 

728x90
반응형

댓글