Skip to main content
Home
for DLMS smart meters

Main navigation

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

Breadcrumb

  1. Home
  2. Create Custom AARQ Request For Encrypted Communication

Create custom AARQ Request for encrypted communication

By cdsvb, 12 April, 2026
Forums
Gurux.Serial

Hello everyone,
I’m completely new to Gurux and am trying to establish encrypted communication with a gas meter that uses a different AARQ request.

<HDLC len="4F" >
<TargetAddress Value="1" />
<SourceAddress Value="D" />
<!-- AARQ frame. -->
<FrameType Value="10" />
<PDU>
<AssociationRequest>
 <ApplicationContextName Value="LN_WITH_CIPHERING" />
 <CallingAPTitle Value="[key]" />
 <SenderACSERequirements Value="1" />
 <MechanismName Value="HighGMAC" />
 <CallingAuthentication Value="[auth]" />
 <InitiateRequest>
   <ProposedDlmsVersionNumber Value="06" />
   <ProposedConformance>
     <ConformanceBit Name="PriorityMgmtSupported" />
     <ConformanceBit Name="Attribute0SupportedWithGet" />
     <ConformanceBit Name="BlockTransferWithGetOrRead" />
     <ConformanceBit Name="BlockTransferWithSetOrWrite" />
     <ConformanceBit Name="BlockTransferWithAction" />
     <ConformanceBit Name="MultipleReferences" />
     <ConformanceBit Name="Get" />
     <ConformanceBit Name="Set" />
     <ConformanceBit Name="SelectiveAccess" />
     <ConformanceBit Name="EventNotification" />
     <ConformanceBit Name="Action" />
   </ProposedConformance>
   <ProposedMaxPduSize Value="01CE" />
 </InitiateRequest>
</AssociationRequest>
</PDU>
</HDLC>

How can I put this request together myself now? I’ve already tried using the GXDLMSXmlClient, but unfortunately I’m getting an error message saying that the specified key isn’t in the dictionary.

I’d be very grateful for any help.

 

Profile picture for user Kurumi

Kurumi

4 weeks 1 day ago

Hi, You set AARQ parameters…

Hi,

You set AARQ parameters as a comand line arguments.
Try with this:

-a HighGMac -C AuthenticationEncryption -T YOUR_System_Title -A YOUR_Authentication_Key - B YOUR_Block_Cipher_Key

BR,
Mikko

cdsvb

4 weeks ago

Hey Mikko, thanks for the…

Hey Mikko, thanks for the quick reply – I’m afraid I wasn’t quite clear enough. 

I’m currently using the GXDLMSSecureClient in C#. To generate the AARQ request, I use the client.AARQRequest() function. When I set the parameters as required, a glo_ActionRequest is generated. 

Unfortunately, this doesn’t work for my gas meter, as I need to construct the request as described above.

Best regards

Profile picture for user Kurumi

Kurumi

3 weeks 5 days ago

Hi, You need to propose the…

Hi,

You need to propose the General Protection Conformance.

Try to add this before you establish the connection to the meter.

client.ProposedConformance|= Conformance.GeneralProtection;

BR,
Mikko

cdsvb

3 weeks 5 days ago

Hey Mikko,I have now set the…

Hey Mikko,

I have now set the General Protection Conformance, but it is still using `glo_InitiateRequest` instead of `InitiateRequest`. Could you also tell me how I can set the CallingAuthentication?

<AssociationRequest>
  <ApplicationContextName Value="LN_WITH_CIPHERING" />
  <CallingAPTitle Value="[Title]" />
  <SenderACSERequirements Value="1" />
  <MechanismName Value="HighGMAC" />
  <CallingAuthentication Value="0000000000000000" />
  <glo_InitiateRequest Value="3000000001B8A2B0FEE5FA80FE27AB7E360A7BB6794BD3653005450C43EFC5" />
</AssociationRequest>

Thank you in advance and best regards,
Leon

Profile picture for user Kurumi

Kurumi

2 weeks 6 days ago

Hi, If you want to send…

Hi,

If you want to send InitiateRequest, you don't use secured connection.
InitiateRequest is sent if you change Secure = None or just remove
-C AuthenticationEncryption argument.

BR,
Mikko

  • Create new account
  • Reset your password

Hire Us!

Latest Releases

  • Mon, 05/11/2026 - 11:07
    Gurux.DLMS.Go 1.0.17
  • Mon, 04/27/2026 - 08:37
    Gurux.DLMS.Go 1.0.16
  • Thu, 04/23/2026 - 13:19
    Gurux.DLMS.Net 9.0.2604.2101
  • Tue, 04/14/2026 - 11:47
    gurux.dlms.java 4.0.93
  • Mon, 04/13/2026 - 16:12
    gurux.dlms.java 4.0.92

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
RSS feed
Privacy FAQ GXDN Issues Contact
Follow Gurux on Twitter Follow Gurux on Linkedin