Skip to main content
Home
for DLMS smart meters
Open source solutions for DLMS smart metering

Main navigation

  • Home
  • Products
  • About us
  • Open Source
  • Community
  • Forum
  • Downloads
User account menu
  • Log in

Breadcrumb

  1. Home
  2. Forums
  3. Support HLS Authentication For C++

support HLS Authentication for C++

Forum Rules

Before commenting read Forum rules

Don't comment the topic if you have a new question.

You can create a new topic selecting correct category from Gurux Forum and then create a new topic selecting "New Topic" from the top left.

By micgur01 , 13 September, 2017
Forums
Gurux.DLMS

Hi

I can see HLS support for to C++ at client side.
Is it supported at server side as well, can't see it in code.

Thanks,
Michael

Profile picture for user Kurumi

Kurumi

8 years 9 months ago

support HLS Authentication for C++

Hi,

Yes it's supported.

BR,

Mikko

micgur01

8 years 9 months ago

support HLS Authentication for C++ for server side

Hi
Where is the relevant code? How to enable HLS at server side
for example HLS 5 - Galois Message Authentication Code (GMAC)

Profile picture for user Kurumi

Kurumi

8 years 9 months ago

support HLS Authentication for C++ for server side

Hi,

You don't need to do anything. Client decides what authentication level is used.
Get latest version.
BR,
Mikko

micgur01

8 years 8 months ago

support HLS Authentication for C++ for server side

Hello Mikko Kurunsaari,

Using the latest version from today

I am trying work with DLMS_AUTHENTICATION_HIGH_GMAC
Got a coredump , see below
(gdb) p block->c3 >> 24
$1 = 1099511627708
AES is 255 array, so it crashed.
I've tried to change code to r0 ^= Shift((AES[block->c3 >> 24 ) & 0xFF], 8);
but then server side return InvalidConnection.

(gdb) r
Starting program: /home/micgur01/work/cleanDLMS/Gurux.DLMS.cpp/GuruxDLMSClientExample/bin/gurux.dlms.client.bin
InitializeConnection

Program received signal SIGSEGV, Segmentation fault.
0x000000000043d730 in CGXCipher::EncryptBlock (
settings=settings@entry=0x7fffffffd920, block=block@entry=0x7fffffffcc50)
at src/GXCipher.cpp:562
562 r0 ^= Shift(AES[block->c3 >> 24], 8);
(gdb) bt
#0 0x000000000043d730 in CGXCipher::EncryptBlock (
settings=settings@entry=0x7fffffffd920, block=block@entry=0x7fffffffcc50)
at src/GXCipher.cpp:562
#1 0x000000000043dc16 in CGXCipher::ProcessBlock (settings=0x7fffffffd920,
input=0x7fffffffd9a0, inOffset=0, output=0x7fffffffd9a0, outOffset=0,
block=0x7fffffffcc50) at src/GXCipher.cpp:186
#2 0x000000000043e3ba in CGXCipher::Init (settings=0x7fffffffd920, aad=...,
iv=..., frameCounter=0, systemTitle=..., bufBlock=..., block=...)
at src/GXCipher.cpp:738
#3 0x000000000043ea8d in CGXCipher::Encrypt (this=this@entry=0x7fffffffd920,
security=security@entry=DLMS_SECURITY_AUTHENTICATION,
type=type@entry=DLMS_COUNT_TYPE_TAG, frameCounter=frameCounter@entry=0,
tag=tag@entry=0 '\000', systemTitle=..., plainText=..., encrypted=...)
at src/GXCipher.cpp:931
#4 0x000000000044c8ca in CGXSecure::Secure (settings=...,
cipher=0x7fffffffd920, ic=ic@entry=0, data=..., secret=..., reply=...)
at src/GXSecure.cpp:129
#5 0x000000000041661c in CGXDLMSClient::GetApplicationAssociationRequest (
this=0x7fffffffd520, packets=std::vector of length 0, capacity 2)
at src/GXDLMSClient.cpp:740
#6 0x000000000040596d in CGXCommunication::InitializeConnection (
this=0x7fffffffd430) at src/communication.cpp:688
#7 0x00000000004095cc in CGXCommunication::ReadAll (this=0x7fffffffd430)
---Type <return> to continue, or q <return> to quit---

By the way, only DLMS_AUTHENTICATION_LOW is working
others can not connect at all, and DLMS_AUTHENTICATION_HIGH_GMAC results coredump.
Could you please help?
Maybe need more settings to change, rather then authentication option?

Thanks,
Michael

Profile picture for user Kurumi

Kurumi

8 years 8 months ago

support HLS Authentication for C++ for server side

Hi,

Are you using GXDLMSSecureClient? What OS you are using?

BR,

Mikko

micgur01

8 years 8 months ago

support HLS Authentication for C++ for server side

Hi

Gurux.DLMS.cpp example as is, yep CGXDLMSSecureClient
CGXDLMSSecureClient cl(useLogicalNameReferencing, clientAddress, serverAddress, authentication, password, interfaceType);

Linux Ubuntu(64 bit)

BR,
Michael

micgur01

8 years 8 months ago

support HLS Authentication for C++ for server side

Hi

Just check it on raspberry pi3 , Ubuntu Mate 32bit ( both client and server).
It looks ok, using GMAC - no coredump, print all info
Looks like 32/64 bit problem

it still problematic using server and client with different architecture, one 32 and other 64.

By the way , other HLS did not even start any object prints.

Thanks,
Michael

Profile picture for user Kurumi

Kurumi

8 years 8 months ago

support HLS Authentication for C++ for server side

Hi,

We run test using Fedora 64bit. I'll ask to install 64 bit Ubuntu and we'll try with that.
I'll let you know as soon as I have something.

BR,

Mikko

Kernel Whoops

7 years 7 months ago

In reply to support HLS Authentication for C++ for server side by Kurumi

I've just experienced the

I've just experienced the same problem on Ubuntu 14.04 LTS 64 bits, g++ 4.8.4. Is there any solution for that?

Profile picture for user Kurumi

Kurumi

7 years 7 months ago

Ubuntu 14.04 LTS 64

Hi,

Do you have the latest version from Github? This should be fixed a long time ago.

BR,

Mikko

Kernel Whoops

7 years 7 months ago

In reply to Ubuntu 14.04 LTS 64 by Kurumi

Ubuntu 14.04 LTS 64

I use the version downloaded from the master branch on October 16th this year.

Regards,
KW

  • Create new account
  • Reset your password

Hire Us!

Latest Releases

  • Tue, 06/09/2026 - 11:16
    gurux.dlms.java 4.0.95
  • Tue, 06/09/2026 - 10:03
    Gurux.DLMS.Python 1.0.199
  • Mon, 06/08/2026 - 13:39
    gurux.dlms.cpp 9.0.2606.0801
  • Mon, 06/01/2026 - 10:15
    gurux.dlms.cpp 9.0.2606.0101
  • Thu, 05/28/2026 - 16:06
    gurux.dlms.java 4.0.94

New forum topics

  • Error reading L&G Meter
  • Pass a TCP Client to GXNet
  • Australian EDMI Mk10D (Essential Energy area)
  • Strange mix of data notificiation vs get response
  • DLMS Connection
More

Who's new

  • Tuanhgg
  • Adel
  • charnon
  • Paddles
  • Miguel Ángel
RSS feed
Privacy FAQ GXDN Issues Contact
Follow Gurux on Twitter Follow Gurux on Linkedin