DNP3 Source Code Library

Our ANSI C source code library provides a quick and cost effective way to implement a DNP3 master or outstation.  A .NET component version is also available.  And they're royalty free!

Related Products

What's New

Current Release: v3.23
Release Date:  July 2018

Newest Features in this Release

  • Added support for TLS v1.2 in the Windows target layer
  • Included support for 64 bit builds in the example project and solution files provided for Visual Studio
  • Updated Device Profile Current Values section for Outstations to schema Version 2.11 April 2016
  • Added x.509 certificates and support for DNP Secure Authentication g120v8 requests
  • Updated simulated database for Outstation example to support DNP Technical Bulletin TB2017-001 Supervisory Mode
  • Resolved warnings when compiling on Linux with strict checking turned on
  • Improved Secure Authentication Version 2 to better support the expiration and updating of User Session Keys (in the same way as described in the SAv5 specification) 
  • Added capability in Master to notify the application via a callback if commands or secure authentication requests time out
  • Improved the algorithm in the Master for managing multiple sessions in a single channel
  • Several other enhancements (see release notes)

Key Additions to Recent Releases


  • Improved performance of database interface and other library functions
  • Restructured directories and sample code for Windows and Linux target layer libraries
  • Added support for IPv6 in Linux target layer
  • Expanded Windows target layer support for resolving IP address from destination host name
  • Updated Linux sample makefiles to generate debug information by default
  • Added multiple enhancements to Secure Authentication library and documentation


  • Improved Linux® makefiles and Windows® solution and project files
  • Improved integration with OpenSSL library
  • Added parsing of Object 91 response for DNP3 Master
  • Added GetRxBuf() method for DNP3 Master so that application can view the entire received message
  • Added capability to configure use of Aggressive Mode for Secure Authentication critical functions launched from the “Auto Request Mask” for DNP3 Master 
  • Added capability for DNP3 channel to skip offline sessions for specified amount of time
  • Several improvements to DNP3 Secure Authentication
  • Improved DNP3 Dual End Point mode

  • Implemented several improvements to DNP3 Secure Authentication including all items suggested in TB2016-002, addressing some deficiencies in DNP3-SAv5
  • Added a configurable feature that would allow the user to issue two separate BRM commands, holding off other automatic behavior
  • Added statistic indicating Link Status was received
  • Made improvements to DNP3 Device Profile

  • Added support for Assign Class Function Code for Virtual Terminal object group
  • Added Session Statistic event to indicate a Link Status response is received
  • Added configuration to disable default behavior required on TCP by the DNP specification to disconnect and reconnect when a link status request times out
  • Modified code to allow use of either UNICODE or MBCS character set

  • Updated the DNP3 libraries to include DNP3 Device Profile November 2014 version 2.10
  • Improved the handling of DNP messages with the wrong link address
  • DNP Secure Authentication improvements including a configurable 4-32 byte challenge data object, a new device attribute for the version of Secure Authentication that is supported by the Outstation, corrected session statistics, and improved aggressive mode support
  • Exposed DNP Unsolicited class mask for .NET components (propertyUnsolnitialClassMask)
  • Added multiple new DNP3 device attributes in the default simulated database
  • Improved support of Linux® networking layer for UDP
  • Added ability to disable function codes for device specific addresses as described in AN2014-001
  • Implemented DNP device attribute time type described in TB2013-004
  • Updated the code to use C99 standard types for 16 bit and 32 bit types for improved Linux® implementations
  • Improved handling of unsolicited messages under special cases
  • Improved support of DNP3 points set to local mode

  • Additional support for DNP3 device profile, including secure authentication, control broadcast configuration, and other fields
  • Added cryptography interface for Secure Authentication V2 (the Library already has this interface for SAv5)
  • Enhanced the tolerance for restart in Master and Outstation with Secure Authentication, including initialization of keys
  • Added compile time choice of using either standard or Microsoft “safe” string functions that include the length of the buffer to be written to (ie strcpy or strcpy_s)
  • Added more checking to discard improperly formatted messages

v3.16.01 - Corrected an issue where DNP3 transport layer would reject a message 

  • Addressed all items associated with ICS-CERT Advisory (ICSA-13-240-01)
  • Improved input verification
  • Made improvements to DNP3 Secure Authentication interface
  • Enhanced Assign Class functions
  • Added configuration option to disable support for receiving broadcast messages

v3.14 - Enhanced DNP3 SAv5 implementation

v3.07 - Added sample Linux® and Windows® target implementation

v3.05.01 - Added updates to DNP3 SA approved by DNP3 TC

v3.01.01 - Added ability to keep time on a per-session basis

v3.01.00 - Added support for DNP3 SAv2

v3.00.44 - Updates to Data Sets

v3.00.43 - Added support for Data Sets and Object 0 (Device Description)

v3.00.38 - Added support for Double Bit data types and Self Address Discovery mechanism

v3.00.36 - Added support for File Transfer Event Mode

v3.00.35 - Added memory alignment support

v3.00.32 - Added support for multiple threads

© 2013 Triangle MicroWorks, Inc. All rights reserved.