Skip to content

Java Functionsยถ

Create Notification to Move Applet from One Environment to Anotherยถ

run this in sim-service

public static void main(String[] args) throws IOException {
    ByteArrayOutputStream stream = new ByteArrayOutputStream();
    stream.write(responseHeader(ServerToAppletMessageType.NOTIFICATION_WAITING.id, SUCCESS));
    stream.write(new byte[SECURE_PAYLOAD_SIZE]);
    stream.write(tlv(MessageTag.TCP_IP_V4.getTag(), ipToByte("3.213.165.77")));
    stream.write(tlv(MessageTag.SHORT_CODE.getTag(), AppletMessageUtils.shortCodeToByte("9876", "91")));
    System.out.println(ByteUtils.bytesToHexString(stream.toByteArray()));
}