Something weird : Can't connect to meter server with ECDSA based on different architecture (e.g. between arm and x64).

8 posts / 0 new
Last post
wooreeinfo
Something weird : Can't connect to meter server with ECDSA based on different architecture (e.g. between arm and x64).

Hi gurux team,

I'm trying to connect meter server example from github running on raspberry pi model 3.

When it try to connect lower than high authentication, it works successful with no errors.
But when it try to connect highECDSA authentication, it returns "Access Error : Device reports a inconsistent Class or object.".

I'm using meter server and client examples from github, and I have checked it works successfully based on same x64 architecture systems.
Even it works perfectly on the different operating systems. (e.g. I checked it works between Windows 11 and CentOS 7 x64)

All the codes are same, certificates and keys are also same too.
It only different architectures.

It seems to be weird.
Would you please check it if time permits.

Best regards,
Hyunse Cho.

Kurumi
Kurumi's picture

Hi Hyunse Cho,

This sounds interesting. I have a few questions.

Are you using Java version from the client?
What distro you are using?
What java version you are using?

BR,
Mikko

________________________________________
Mikko Kurunsaari
Gurux Ltd
http://www.gurux.fi

wooreeinfo

Hi Mikko,

I'm using java client example at first time, but currently I'm using GXDLMSDirector instead.
I thought It would be better to use for the clearly result, but it appears same issues.

Server and client example codes are running on Oracle JDK 11 and some of JVM based on OpenJDK 11. (e.g. Azul Zulu, Eclipse Temurin)

Kurumi
Kurumi's picture

Hi,

This is interesting because ECDSA is using Java implementation. This needs to be tested with Raspberry Pi. Can you run java --version in PI and let me know the results?

BR,
Mikko

________________________________________
Mikko Kurunsaari
Gurux Ltd
http://www.gurux.fi

wooreeinfo

Results are below here:

1. Eclipse Temurin
openjdk 11.0.16 2022-07-19
OpenJDK Runtime Environment Temurin-11.0.16+8 (build 11.0.16+8)
OpenJDK Server VM Temurin-11.0.16+8 (build 11.0.16+8, mixed mode)

2. Azul Zulu
openjdk 11.0.16 2022-07-19 LTS
OpenJDK Runtime Environment Zulu11.58+17-CA (build 11.0.16+8-LTS)
OpenJDK Client VM Zulu11.58+17-CA (build 11.0.16+8-LTS, mixed mode)

Kurumi
Kurumi's picture

Hi,

I believe that you are not running Eclipse Temurin in Raspberry PI.
Can you get this information from the Raspberry PI? It's easier to test when we have exactly the same environment.

BR,
Mikko

________________________________________
Mikko Kurunsaari
Gurux Ltd
http://www.gurux.fi

wooreeinfo

Hi,

I ran uname -a in PI, and it returns this.
Linux raspberrypi 4.19.57-v7+ #1244 SMP Thu Jul 4 18:45:25 BST 2019 armv7l GNU/Linux

I downloaded Eclipse Temurin JDK 11 for arm architecture from https://adoptium.net/temurin/releases page.
(Direct URL : https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11....)

Then I executed server example like this:
exec ../jdk-11/bin/java -cp "./*:./libs/*" gurux.dlms.server.example.GuruxDlmsServerExample

I used azul zulu that is same way.

cf. when trying to connect server example on raspberry pi with ECDSA, logs are like below :

[2022-08-10 16:05:53] RX: 7E A0 08 02 2D 21 93 A6 74 7E
[2022-08-10 16:05:53] TX: 7E A0 1F 21 02 2D 73 F6 5D 81 80 12 05 01 80 06 01 80 07 04 00 00 00 01 08 04 00 00 00 01 53 3B 7E
[2022-08-10 16:05:53] RX: 7E A0 2C 02 2D 21 10 B4 8F E6 E6 00 60 1D A1 09 06 07 60 85 74 05 08 01 01 BE 10 04 0E 01 00 00 00 06 5F 1F 04 00 20 1E 1D FF FF 54 84 7E
[2022-08-10 16:05:53] TX: 7E A0 38 21 02 2D 30 24 7D E6 E7 00 61 29 A1 09 06 07 60 85 74 05 08 01 01 A2 03 02 01 00 A3 05 A1 03 02 01 00 BE 10 04 0E 08 00 06 5F 1F 04 00 00 00 10 04 00 00 07 86 A1 7E
[2022-08-10 16:05:53] RX: 7E A0 1A 02 2D 21 32 ED 62 E6 E6 00 C0 01 C1 00 01 00 00 2B 01 07 FF 02 00 5C D8 7E
[2022-08-10 16:05:53] TX: 7E A0 16 21 02 2D 52 19 3C E6 E7 00 C4 01 C1 00 06 00 00 00 64 5F 3D 7E
[2022-08-10 16:05:53] RX: 7E A0 08 02 2D 21 53 AA B2 7E
[2022-08-10 16:05:53] TX: 7E A0 1F 21 02 2D 73 F6 5D 81 80 12 05 01 80 06 01 80 07 04 00 00 00 01 08 04 00 00 00 01 53 3B 7E
[2022-08-10 16:05:53] RX: 7E A0 08 02 2D 2F 93 B6 EE 7E
[2022-08-10 16:05:53] TX: 7E A0 1F 2F 02 2D 73 B4 F3 81 80 12 05 01 80 06 01 80 07 04 00 00 00 01 08 04 00 00 00 01 53 3B 7E
[2022-08-10 16:05:53] RX: 7E A8 8A 02 2D 2F 10 A0 E5 E6 E6 00 60 7E A1 09 06 07 60 85 74 05 08 01 03 A6 0A 04 08 47 58 41 41 41 41 41 41 8A 02 07 80 8B 07 60 85 74 05 08 02 07 AC 22 80 20 12 22 25 79 6D 47 57 70 6D 39 19 60 21 35 51 6C 4C 62 54 39 40 42 3C 68 5B 30 36 67 57 14 0A 19 BE 34 04 32 21 30 31 00 00 00 65 96 F0 2A 70 B0 39 7C 86 21 90 88 3F 0D 08 03 A7 0A DD 8E 0D CA C2 8C 64 BC B4 7F 06 CB 1E 3C EC 65 25 06 BC 19 2B 81 88 B1 FB 7E
[2022-08-10 16:05:53] TX: 7E A0 08 2F 02 2D 31 3E 16 7E
[2022-08-10 16:05:53] RX: 7E A0 0D 02 2D 2F 12 63 5D 20 D5 74 6C D8 7E
[2022-08-10 16:05:53] TX: 7E A0 84 2F 02 2D 50 D4 99 E6 E7 00 61 75 A1 09 06 07 60 85 74 05 08 01 03 A6 0A 04 08 41 42 43 44 45 46 47 48 A2 03 02 01 00 A3 05 A1 03 02 01 0E A4 0A 04 08 41 42 43 44 45 46 47 48 88 02 07 80 89 07 60 85 74 05 08 02 07 AA 12 80 10 01 53 2E 08 42 58 61 56 67 1E 30 2E 75 59 38 73 BE 23 04 21 28 1F 31 00 00 00 00 16 58 4D 6F 2B F4 37 73 19 6D DC 50 81 77 6A 39 CF 3C CA E2 D0 97 F5 07 A8 2B 65 A1 7E
[2022-08-10 16:05:53] RX: 7E A0 6F 02 2D 2F 34 6C AE E6 E6 00 CB 60 31 00 00 00 66 D3 F3 DC 52 13 A7 DF CC 03 54 34 B7 ED 33 A8 F1 FB 0E 9C E1 D6 94 36 D9 F7 CE 3D 6A 8E 7A 65 CD 90 C3 3D AA 2B D9 C9 9B 32 86 CD 4E 95 6B 4F 33 13 68 5F 07 CF 84 7A 9F DA 32 40 92 7F DA EE E9 FF 22 DF BE 95 26 B3 4A 65 DB BA A7 B9 8B E6 0A B1 DE 77 4D 78 BF 3D 92 D8 80 DC FB 15 7E
[2022-08-10 16:05:53] TX: 7E A0 12 2F 02 2D 72 49 9E E6 E7 00 C7 01 C1 09 00 E4 63 7E
[2022-08-10 16:05:53] RX: 7E A0 08 02 2D 2F 53 BA 28 7E
[2022-08-10 16:05:53] TX: 7E A0 1F 2F 02 2D 73 B4 F3 81 80 12 05 01 80 06 01 80 07 04 00 00 00 01 08 04 00 00 00 01 53 3B 7E

Best regards,
Hyunse Cho.

Kurumi
Kurumi's picture

Hi Hyunse Cho,

Thank you for this. Setting the environment will take some time. I hope we have an answer to this during the next week.

BR,
Mikko

________________________________________
Mikko Kurunsaari
Gurux Ltd
http://www.gurux.fi