Compare commits

...

10 Commits

Author SHA1 Message Date
ypc 8b3b94aa68 <修改>
1、完成了参数文件的生成功能
2、调整了部分配置文件
2026-05-19 16:26:20 +08:00
ypc 3f6163defb <修改>
1、解析iec104的配置文件
2、增加out的回调
3、增加in的回调
2026-05-19 10:44:10 +08:00
ypc 1468207cae <修改>
1、调整vscode配置,终端打印历史行数增加;
2、增加信号类型ao,作为参数,区分param定值,定值有定值区
3、信号中的指向数据的指针使用vector,用于存储定值时,存在多个定值区;
4、webserver中同步增加ao类型信号处理
5、调整各配置文件,增加ao类型,调整param类型
2026-05-15 14:47:16 +08:00
ypc 8d4c7eebb4 <修改>
1、调整mms_m库中,创建数据时,赋初值;
2、数据中心的数据表中不存放控制数据,控制状态逻辑由调用者申请分别传入;
3、数据中心参数注册时,存放缺省值的字符串数据;
4、数据中心遥控与参数不再初始化控制状态结构体;
5、调整配置文件目录,存入私有规约配置文件,添加iec1014的配置文件
2026-05-12 15:58:25 +08:00
ypc d6dc13937e <修改>
1、使用新的配置文件,在main中初始化解析;
2、私有规约获取配置解析结果,调用数据中心注册函数注册
2026-05-12 13:23:10 +08:00
ypc 7fd80337dd 从Git仓库移除 uart_trans 文件夹 2026-05-11 16:25:57 +08:00
ypc 79ead5b58e 从Git仓库移除 FTU_cfg_parse 文件夹 2026-05-11 16:24:53 +08:00
ypc 488858317e <修改> 1、增加git筛选;2、调整解析ftu文件的工具程序;3、编写解析私有规约配置文件的代码 2026-05-11 15:43:52 +08:00
ypc b3201d4dd3 <修改> 1、调整makefile的mk文件中61850库文件的路径 2026-05-11 13:33:03 +08:00
ypc ce509d8be9 <修改> 1、删除libiec61850-1.5.3,改为使用编译完成的库 2026-05-11 11:28:45 +08:00
1034 changed files with 8078 additions and 233118 deletions

28
.gitignore vendored Normal file
View File

@ -0,0 +1,28 @@
# 只忽略编译出来的二进制、目标文件
*.o
*.a
*.obj
*.lib
*.exe
*.out
*.elf
*.hex
*.map
*.d
*.su
*.pdb
*.idb
*.gch
# 编译临时目录
obj/
build/
lib/
tmp/
# vscode 缓存
.vscode/
release/x86/exe/FTU_cfg_parse
release/x86/exe/RTU
src/system/uart_trans/
src/system/FTU_cfg_parse/

View File

@ -1,4 +1,5 @@
{
"makefile.makefilePath": "/mnt/RTU/release/",
"cmake.sourceDirectory": "/mnt/RTU/libiec61850-1.5.3/demos/beaglebone"
"cmake.sourceDirectory": "/mnt/RTU/libiec61850-1.5.3/demos/beaglebone",
"terminal.integrated.scrollback": 10000
}

View File

@ -1,26 +0,0 @@
name: CIFuzz
on: [pull_request]
jobs:
Fuzzing:
runs-on: ubuntu-latest
steps:
- name: Build Fuzzers
id: build
uses: google/oss-fuzz/infra/cifuzz/actions/build_fuzzers@master
with:
oss-fuzz-project-name: 'libiec61850'
dry-run: false
language: c
- name: Run Fuzzers
uses: google/oss-fuzz/infra/cifuzz/actions/run_fuzzers@master
with:
oss-fuzz-project-name: 'libiec61850'
fuzz-seconds: 300
dry-run: false
language: c
- name: Upload Crash
uses: actions/upload-artifact@v3
if: failure() && steps.build.outcome == 'success'
with:
name: artifacts
path: ./out/artifacts

View File

@ -1,71 +0,0 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"
on:
push:
branches: [ v1.5 ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ v1.5 ]
schedule:
- cron: '38 23 * * 6'
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
language: [ 'cpp' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
# Learn more:
# https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
steps:
- name: Checkout repository
uses: actions/checkout@v2
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1
# Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language
#- run: |
# make bootstrap
# make release
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1

View File

@ -1,12 +0,0 @@
name: Greetings
on: [pull_request, issues]
jobs:
greeting:
runs-on: ubuntu-latest
steps:
- uses: actions/first-interaction@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
pr-message: 'Push requests and other code contributions can only be accepted from authorized persons that have signed our contributor license agreement(CLA). When in doubt please write to info@libiec61850.com.'

View File

@ -1,2 +0,0 @@
build/
/Debug/

View File

@ -1,25 +0,0 @@
language: c
compiler:
- clang
- gcc
addons:
apt:
packages:
- cmake
- swig
- libsqlite3-dev
- python-dev
before_install:
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then
brew update;
brew install swig python sqlite;
fi
- mkdir -p build && cd build
script:
- cmake .. -DBUILD_PYTHON_BINDINGS=ON
- make
- make test

View File

@ -1,913 +0,0 @@
Changes to version 1.5.3
------------------------
New features and improvements:
- config file parser dynamically allocates linebuffer to allow multithreaded applications (#484)
- parse time values in model configuration file (LIB61850-426)
- config file generator: added missing code for GSEControl (LIB61850-418)
- Config file generator: support multiple access points for GOOSE and SMV control blocks (LIB61850-418)
- config file generator: added code to add SMVCBs to config files (LIB61850-67)
- IED server: added code to create SMVCBs with the dynamic model API (LIB61850-67)
- MMS server: added support for write access with component alternate access (LIB61850-414)
- MMS client: added function MmsConnection_writeVariableComponent to write to variables with alternate component access (LIB61850-414)
- make write access to RCB elements configurable according to ReportSettings (LIB61850-404)
- Added function IedConnection_setLocalAddress to define local IP address and optionally local port of a client connection (LIB61850-378)
- IED server: added ControlAction_getSynchroCheck and ControlAction_getInterlockCheck functions
Fixed bugs and vulnerabilities:
- fixed - IEC 61580 server: dataset is not released when RCB.Datset is set to empty string by client (LIB61850-425)
- PAL: fixed wrong order of function arguments for fread and fwrite functions
- MMS client: parsing of servicecsSupported in MMS init response is off by one (LIB61850-419)(#469)
- fixed - potential memory leaks in goose publisher code (#464)
- fixed - server sends dchg report when only dupd is enabled in RCB (LIB61850-411)
- GOOSE subscriber: fixed - possible heap corruption in parseAllData due to missing validity check in bit-string handling (LIB61850-402)
- IED server: fixed problem with implicit ResvTms setting when reserved with RptEna (LIB61850-400)
- IED server: fixed - segmentation fault when compiled with CONFIG_MMS_THREADLESS_STACK (LIB61850-398)
- fixed - MMS server: messages can be corrupted when TCP buffer is full (LIB61850-385)
- fixed - .NET: IedConenction.WriteDataSetValues throws a NullReferenceException (LIB61850-384)
- fixed - server send invalid response- when client uses wrong ctlModel (LIB61850-383) (#435)
- fixed - IedConnection_setRCBValuesAsync crashes when RCB is already reserved by other client (LIB61850-382)
- fixed - outstanding call not released in IedConnection_getDataSetDirectoryAsync (LIB61850-379)
Changes to version 1.5.2 (Dec 19, 2022)
---------------------------------------
New features and improvements:
- renamed TLSConfiguration_EventLevel to TLSEventLevel
- updated required mbedtls version to 2.28.x
- Added check for changed CRL on socket read/write. Added reset of renegotiation ssl cache on CRL add
- Fixing Security events messages to match IEC62351-100-3
- .NET API: Added support for TLS event handler (LIB61850-373)
- IED Server: added function to set time quality for internally updated times (LIB61850-372)
- added TLSConnection object to provide more context in TLS event callback (LIB61850-366)
- TLS: added TLS alert callbacks; support for session resumption with session IDs (LIB61850-339)
- MMS client: added function MmsConnection_sendRawData for test purposes
- changed StringUtils_createStringInBuffer function to consider max buffer size (LIB61850-333)
- replaced most str(n)cpy/str(n)cat calls (LIB61850-333)
- encode boolean true value as 0x01 instead of 0xff to avoid interoperability problems
- added IedServerConfig_setSyncIntegrityReportTimes/IedServerConfig_setSyncIntegrityReportTimes wrapper to .NET API (LIB61850-323)
- added feature: synchronization of integrity report times (LIB61850-323)
- server: added RCBEventHandler event types REPORT_CREATED and OVERFLOW
- added function ReportControlBlock_getResv
- mms_utility: added option to read data set directory
- .NET API: added IedServer.GetFunctionalConstrainedData method (LIB61850-317)
- RCBEventHandler: replaced GI event by purgeBuf event when client disables RCB instance (LIB61850-316)
- enabled TLS 1.2 support in mbedtls configuration
- improved MmsValue handling; fixed MmsValue(OCTET-STRIG) maximum size problem (LIB61850-150)
- IED server: improved control state machine performance (LIB61850-312)
Fixed bugs and vulnerabilities:
- fixed - dynamic model helper functions: Check added to Cancel object for CDC APC
- fixed wrong number in TLS event code define (LIB61850_366)
- fixed - servers sends object-access-unsupported on GetAllData when ReadAccessHandler is installed (LIB61850-370)
- fixed - endless loop sending reports when MMS PDU size is too small (LIB61850-365)
- fixed path traversal vulnerability in MMS file services (LIB61850-357)
- IED server: added missing call to getNextRoundedStartTime (LIB61850-323)
- fixed - server crashs when SyncIntegrityReportTimes is active and IntgPd=0 (LIB61850-355)
- fixed - missing API export declarations for functions IedServerConfig_setSyncIntegrityReportTimes and IedServerConfig_getSyncIntegrityReportTimes (LIB61850-353)
- IED server: fixed - possible deadlock when IedServer_lockDataModel is used from multiple threads (LIB61850-352)
- MMS server: fixed - possible deadlock in obtainFile-service/file upload task (LIB61850-351)
- MMS server: fixed potential null pointer dereference when confirmeServiceResponse for fileOpen is received with invoke-id 0 (LIB61850-348)
- MMS_SERVER: fixed bug in getNameList request handling when domain ID is too long (LIB61850-346)
- GOOSE subscriber: fixed vulnerabilities related to malformed bit-string, integer, and unsigned values (LIB61850-342)
- MMS server: fixed bug in handling of continueAfter parameter of getNameList request (LIB61850-341)
- fixed sscanf format string in config_file_parser.c
- fixed locking mechanism in logging.c (LIB61850-327)
- fixed problem: negative presentation layer and ACSE results are ignored by client
- fixed wrong buffer size in client side report handling
- fixed memory leak in server read request handling (LIB61850-325)
- fixed memory leak in reuse of client connection (related to socket extension buffer)
- fixed - TLS: CRL is ignored
- fixed wrong MMS protocol version check (#379)
- fixed - SV publisher encoding problem when svID or datset length > 127 bytes (LIB61850-315)(#382)
- IedServerConfig: added missing variable initialization
- fixed - server doesn't respond SBOw when waiting for select callback (LIB61850-313)
Changes to version 1.5.1 (Mar 11, 2022)
---------------------------------------
New features and improvements:
- added server side ReportControlBlock events and value access functions
- added functions Timestamp_fromMmsValue and Quality_toMmsValue
- made server report reservation compatible with Ed. 2.1 (LIB61850-293)
- new functions MmsValue_getOctetStringOctet and MmsValue_setOctetStringOctet
- IedConnection: added function IedConnection_getDataSetDirectoryAsync
- IedConnection: added function IedConnection_createDataSetAsync
- IedConnection: added new function IedConnection_deleteDataSetAsync
- IedServer instance can be restarted
- new function IedConnection_setTimeQuality - Added support to set time quality for client generated time stamps (LIB61850-280)
- .NET API: added wrapper for IedConnection_setFile and IedConnection_setFilestoreBasepath (LIB61850-258)
- IED server: improved accuracy of integrity report intervals
- .NET API: GooseSubscriber - added GetGoId, GetGoCbRef, GetFataSet methods
- IED server: add support for SMV control blocks ("SMVC") in config file parser
- .NET API: added support for server integrated GOOSE publisher
- MacOS thread layer: replaced semaphore by mutex
Fixed bugs and vulnerabilities:
- fixed vulnerability of GOOSE subscriber to malformed messages (LIB61850-304)
- fixed - Bug in presentation layer parser can cause infinite loop (LIB61850-302)
- .NET API: fix problem with garbage collected delegates for async client functions (LIB61850-301)
- fixed compilation problem with option CONFIG_MMS_THREADLESS_STACK
- fixed - TPKT error when connection is interrupted during message reception (LIB61850-299)
- handle presentation layer data messages with transfer-syntax-name
- fixed - UBRB: library can't work at the same time with URCB with preconfigured client and URCB without preconfigured client (LIB61850-292)(#355)
- fix - server crashes when presentation message has no user data (LIB61850-291)(#368)
- MMS server: query log service returns services error instead of reject message when log does not exist (LIB61850-290)
- fixed - IED server: crash during invalid control access - FC=CO on invalid layer (LIB61850-282)
- fixed - Server: ctlNum and origin(status) are not updated automatically by the server when APC command is received (LIB61850-277)
- MMS server: fixed problem with continue-after in some get-name-list handling cases
- fixed - IedConnection: outstanding call on IEC layer is not release under some circumstances (LIB61850-270, LIB61850-251)
- fixed bug in IsoServer that caused memory violation when the server was restarted while a client was connected
- IED client: send RptEna as first element when RCB is to be disabled
- fixed problem with double free of TLS configuration structure (LIB61850-254)
- .NET API: Fixed problem with AccessViolationException in GooseControlBlock.GetDstAddress
- MMS server: fixed data race bug in transmitBuffer handling (#338)
- IED server: fixed crash when IEDName+LDInst is too long
- .NET API: fixed bug - server write access handler causes "CallbackOnCollectedDelegate" exception (LIB61850-236)
- MMS server: fixed potential crash when client connection closed during file upload (LIB61850-2)
- MMS client: fixed problem - doesn't close file when the setFile (obtainFile) service is interrupted e.g. due to connection loss (LIB61850-230)
- Ethernet Socket (Windows): fixed bug and added workaround for problem on Windows (most GOOSE/SV messages are not received when waiting with WaitForMultipleObjects - observed with winpcap 4.1.3 and Windows 10
- fixed problem in BER integer decoder (problem with GOOSE fixed length message decoding)
- .NET API: Fixed memory release problem in method ModelNode.GetObjectReference
- IED server: fixed bug in GoCBEventHandler
- fixed problem in BSD ethernet layer (#328)
- fixed bug in cmake file for BSD
- fixed compilation problem when compiling without GOOSE support (#325)
- IED server: control handling - fixed problem in test flag handling
- IED server: For SBOes check test flag match when accepting operate (sSBOes8)
- IED server: Reject Cancel/SBOw in WaitForChange state - fixed problem with test case sCtl26
Changes to version 1.5.0
------------------------
- added support for time with ns resolution
- IEC 61850 server: control models - allow delaying select response with check handler (new handler return value CONTROL_WAITING_FOR_SELECT)
- IEC 61850 server: added support to listen on multiple IP addresses and ports (new function IedServer_addAccessPoint)
- added support for service tracking
- added tool support for transient data objects
- .NET API: added more functions to create and access server data model
- IED server - control model - send AddCause with operate- for DOes, SBOes control models
- IED server: integrated GOOSE publisher - lock data model during GOOSE retransmission to avoid corrupted GOOSE data
- added server example for dead band handling
- IED server: make presence of RCB.Owner configurable at runtime with function IedServerConfig_enableOwnerForRCB (B1502/S1634)
- IED server: make presence of BRCB.ResvTms configurable at runtime with function IedServerConfig_enableResvTmsForBRCB (F1558)
- restrict maximum recursion depth in BerDecoder_decodeLength when indefinite length encoding is used to avoid stack overflow when receiving malformed messages
- fixed oss-fuzz issues 31399, 31340, 31341, 31344, 31346
- IED server: fixed bug in log service - old-entry and old-entry-time not updated
- IED server: added new function IedServer_handleWriteAccessForComplexAttribute. Changed WriteAccessHandler behavior when ACCESS_POLICY_ALLOW.
- MMS server: add compile time configuration options to enable/disable fileDelete and fileRename services (fileRename is now disabled by default)
- MMS server: better data model lock handling for performance improvements
- Linux - Ethernet: replace IFF_PROMISC by IFF_ALLMULTI
- improvements in Python wrapper code
- IED server: control models - fixed bug that only one control is unselected when connection closes
- IED server: fixed bug - logs (journals) are added to all logical devices instead of just the parents
- IED Server: prevent integrated GOOSE publisher to crash when ethernet socket cannot be created
- IED server: make compatible with tissue 1178
- IED server: reporting - implemented behavior according to tissue 1432
- IED server: WriteAccessHandler can tell the stack not to update the value when returning DATA_ACCESS_ERROR_SUCCESS_NO_UPDATE
- IED server: fixed problem that BL FC is not writable (#287)
- IEC 61850 client: fixed dead lock in IedConnection_getFileAsync when fileRead times out (#285)
- IED server: added ControlSelectStateChangedHandler callback for control mode
- Client: fixed - IedConnection_getRCBValues doesn't check type of server response (#283)
- GOOSE subscriber: changed maximum GoID size according to tissue 770 (129 bytes)
- IED server: send AddCause for invalid origin also in case of direct control models
- IED server: support for configuration of EditSG service and online visibility of SGCB.ResvTms at runtime
- IED server: changed types TrkOps and OptFlds to variable length bit strings
- MMS: changed handling of variable sized bit strings (now also accepts bit strings of larger size, ignoring the bits that exceed the specified size)
- IED server: add support for correct CBB handling (required for test case sAss4) and initiate error PDU
- IED server: add support for tissue 807 (owner attribute in RCB is only present when ReportSettings@owner attribute is true)
- IED server: implemented tissue 1453 also for writing to "RptId" (purgeBuf only executed when value changes)
- GOOSE subscriber: always copy GoID and DatSet from GOOSE message; always create new MmsValue instance for GOOSE data set when subscriber is observer
- IED server: added configuration file support for data set entries with array elements or array element components
- fixed problems in handling array elements and array element components
- fixed bug in MmsConnection_readMultipleVariables: send invaid messsage and memory access errors when too many items are passed to the function exhausting MMS payload size
- IEC 61850 server: fixed problem with test case sRp4 - RCB RptID attribute is not empty after writing empty string
- fixed program crash when normal mode parameers are missing in presentation layer (#252)
- IED Server/GOOSE: Don't send GOOSE message with new event while data model is locked
- GOOSE: added GOOSE observer feature (GooseSubscriber listening to all GOOSE messages) and GOOSE observer example
- COTP: fixed possible heap buffer overflow when handling message with invalid (zero) value in length field (#250)
- IEC 61850 server: fixed - cancel command for time activated control returns object-access-denied even in case of success
- IEC 61850 client: fixed bug - IedConnection_setRCBValuesAsync always return 0 instead of invoke-ID
- MMS: fixed problem in handling of indefinite length encoded BER elements
- IEC 61850 client: reporting - support data set entries with multiple reasons for inclusion
- Java tools: moved minTime, maxTime from GSEControl to GSE; updated GOOSE server example CID file
- IEC 61850 server: Added ControlAction_setError function - with this function the user application can control the error code used in LastApplError and CommandTermination messages
- IEC 61850 server: fixed problem with logging when log data set contains FCDO (#225)
Changes to version 1.4.2.1
--------------------------
- IEC 61850 server: RCB - fixed problem that other client can "steal" reservation
- MMS client: fixed bug in log entry parsing (#224)
- IEC 61850 server: fixed potential null pointer dereference in multi-thread mode when server is stopped
- IEC 61850 server: fixed bug in single threaded mode (windows)
- IEC 61850 server: fixed compilation error in single thread mode (was new in release 1.4.2)
Changes to version 1.4.2
-------------------------
- IEC 61850 server: wait for background thread termination before data model is released
- MMS server: fixed potential crash when get-named-variable-list-attributes response doesn't fit in MMS PDU. Server returns service error in this case
- IEC 61850 server: unbuffered reporting - send first integrity report after integrity timeout (before it was sent when the RCB was enabled)
- IEC 61850 server: allow server to start without logical devices in data model (#218)
- IEC 61850 client: fixed bug in ClientReportControlBlock - some allowed structures for RCB were rejected
- IEC 61850 server: control - unselect when operate with wrong origin parameters, check if check parameter matches for SBO
- IEC 61850 server: fixed missing report timestamp update for unbuffered reporting
- IEC 618580 server: Added function IedServer_setServerIdentity to set values for MMS identity service
- CDC helpers: added functions to create ISC and BAC CDCs
- CDC helpers: added stSeld and attributes from ControlTestingCDC to control CDCs
- CDC helper functions: added stSeld and attributes from ControlTestingCDC to control CDCs
- updated cmake files
- .NET API: fixed memory management issue in MmsValue.SetElement (see #213)
- IEC 61850 server: unselect control when oper is not accepted
- IEC 61850 server: send select-failed for control when origin parameter is not valid
- IEC 61850 server: fixed control handling to comply with test case sCtl25
- IEC 61850 server: fixed control handling to comply with test case sCtl11
- IEC 61850 server: pass origin, ctlNum, ctlVal to select handler (perform check handler) for SBOw
- removed internal header files from install target (#214)
- .NET API: additional function mappings
- TLS: fixed memory leak when TLS authentication fails
- fixed bug in windows socket layer
Changes to version 1.4.1
------------------------
- MMS server: refactored connection handling; more efficient use of HandleSet
- linux/bsd socket layer: replaced select by poll
- removed header dependencies from API headers
- IEC 61850 server: added support for transient data objects
- .NET API: added MmsValue methods BitStringToUInt32BigEndian and BitStringFromUInt32BigEndian
- fixed compilation problem when CONFIG_MMS_THREADLESS_STACK is defined
- MMS get name list service: fixed wrong return value in case of unknown argument for continueAfter (problem with test case sSrvN1)
- fixed memory leak in windows socket layer (socket connect)
- improved robustness in MMS message parsing
- SV publisher: fixed memory leaks (#191)
- .NET API: added ControlAction.GetControlTime methods
- .NET API: fixed problem in ReportControlBlock.SetRCBValues (see #184)
- MMS server: fixed possible crash when client disconnects during file upload
- MMS server: fixed file upload error with multi-threaded server, added some NULL checks to file-handling.
- IEC 61850 server: added function ConfigFileParser_createModelFromConfigFileEx with filename as argument to avoid dependency on FileSystem_... functions
- IEC 61850 server: Add check call before starting a timeactivated operate, so operates can be denied before the waiting state
- IEC 61850 client: improved error handling and fixed potential memory leak in IedConnection_getDeviceModelFromServer
- replaced timegm implementation on windows. Fixes bug with MMS file times
Changes to version 1.4.0
------------------------
- IEC 61850 client: added asynchronous client API (can handle multiple outstanding requests in a single thread)
- IEC 61850 client: added support for non-thread mode (for use with asynchronous API)
- IEC 61850 client: added IedConnection_StateChangedHandler callback that is called for each connection state change
- .NET API: Added support for IedConnection.GetState and StateChangedHandler
- modelviewer: show full hierarchy including sub data objects
- IEC 61850 server: added IedServer_updateCtlModel function to change control model at runtime
- IEC 61850 client: added functions IedConnection_getLogicalDeviceVariables, IedConnection_getLogicalDeviceDataSets, and IedConnection_getLogicalDeviceDataSetsAsync to address #89
- .NET API: extended MmsValue.ToString method to print arrays and data access errors
- common: MmsVariableSpecification_getChildValue now also accepts "." as separator
- .NET API: ReportControlBlock.GetOwner returns null when no owner available (#79)
- IEC 61850 client: IedConnection - added CONNECTING AND CLOSING states - removed IDLE state (CLOSED, CONNECTING, CONNECTED, CLOSING)
- now using mbedtls 2.16
- TLS renegotiation disabled by default
- fixed bug in BerInteger_setUint16
- IEC 61850 client: Added functions IedConnection_setRequestTimeout and IedConnection_getRequestTimeout to C API and IedConnection.RequestTimeout property to .NET API
- MMS client: fixed problem with obtain file timeout with large files
- IEC 61850 server: Control model callback signature changed. Added ControlAction object to access control related parameters in control callbacks
- SV subscriber: improved error handling when Ethernet access doesn't work; fixed potential memory leak
- GOOSE publisher: integrated error handling when Ethernet interface is not available
- GOOSE receiver: add support for operation without Ethernet HAL implementation
- MMS server: fixed memory access problem when client unexpectedly closed connection during file upload (set-file)
- static model generator: Initialize Dbpos value from Val element in ICD/CID file (see github #163)
Changes to version 1.3.3
------------------------
- IEC 61850 server: reporting - fixed problem with removing old GI reports when latest report is also GI
- IEC 61850 client: fixed problems in ClientReportControlBlock_create (see github #134)
- IEC 61850 client: handle reason code correctly when report contains data with different reason code (see github #133)
- IEC 61850 server: optimized report buffer handling for buffered reporting (save memory and encoding time)
- IEC 61850 client: fixed problem - IedConnection cannot be reused after IedConnection_close (github #124)
- IEC 61850 server: added support for pre configured client with ClientLN
- IEC 61850 client: added function ClientReportControlBlock_hasResvTms
- IEC 61850 server: don't clear owner when client disables BRCB (RptEna = false)
- IED Server: added ResvTms handling for BRCB
- SV publisher: fixed length calculation
- IEC 61850 server: added support for segmented reporting
- fixed bug in windows socket abstraction
- fixed client TCP keep alive problem (see github #115)
- MMS server: read service - return data access error for component access to simple variable
- GOOSE receiver: fixed potential deadlock when GooseReceiver_stop is called directly after GooseReceiver_start
Changes to version 1.3.2
------------------------
- MMS client/server: added support for component alternate access for generic variable read requests
- MMS client: improved handling/stability when receiving malformed messages from the server
- IEC 61850 server: fixed problem with wrong purge buffer invocation when using dynamic data set in buffered report control block
- .NET API: add GetFileDirectoryEx function
- modelviewer: show full hierarchy including sub data objects
- .NET API: DataSet implements IDisposable interface, Report/DataSet GetValues methods return now clones of the original native values to prevent GC issues
- .NET API: MmsValue - added Clone method and implemented IDisposable interface
Changes to version 1.3.1
------------------------
- GOOSE publisher: fixed problem in payload length calculation
- .NET API: Added method MmsConnection.ReadMultipleVariables
- IEC 61850 client: implemented tissue 1178 client side (select-response+ is
non-NULL)
- SV publisher: fixed RefrTm and SmpSynch handling
- IEC 61850 client: improved support for handling segmented reports
- .NET API: Added some additional access function to ReportControlBlock
- Java SCL parser: added support for timestamp values in "Val" elements
- fixed bug in cmake file (winpcap support)
- added C# example code for client side setting group handling
- .NET API: added some additional wrapper code for MmsVariableSpecification functions
Changes to version 1.3.0
------------------------
- IEC 61850 server: more features configurable at runtime
- IEC 61850 server: control objects - fixed bug in select response for SBO control model
- IEC 61850 client: add support for single array element access (with component specification)
- MMS server: add support for array element (index) access with nested component
- IEC 61850 server: made IEC 61850 edition configurable at runtime
- IEC 61850 server: added ReadAccessHandler to control read access
- HAL: unified platform abstraction layer (to simplify using the library together with lib60870)
- IEC 61850 server: fixed bug when calling write access handler (wrong pointer for ClientConnection object)
- updated IEC 61850-9-2 LE example to be more realistic
- added server side example for the substitution service
- MMS server: fixed wrong preprocessor defines that can cause problems in some configurations (unlimited number of client connections/ multi-threaded server)
- IEC 61850 client: added new function ControlObjectClient_getCtlValType to simplify control handling
- IEC 61850 server: reporting - don't delete pending events when buffered report is enabled and dataset didn't change
- fixed bug in MmsValue_update
- MMS server: fixed bug in delete variable list service - scope of delete was not considered optional
- some more small bug fixes and optimizations
Changes to version 1.2.2
------------------------
- IEC 61850 server: added support to configure report buffer size at runtime
- IEC 61850 server: new IedServerConfig type and new IedServer constructor
- .NET API: added support for IedServerConfig
- IEC 61850 server: prevent sending reports when data model is locked (updated)
- TLS client: fixed problem with high CPU load
- ISO connection: fixed race condition that can cause corrupted messages
- .NET API: added project files for .NET core 2.0
- .NET API: added server side support for TLS
Changes to version 1.2.1
------------------------
- IEC 61850 server: fixed bug in report module when RCB was enabled multiple times (was new in 1.2.0)
- .NET API: Added destructor and Dispose method to ReportControlBlock (fixed memory leak)
- .NET API: Changed ReportControlBlock access to IedConnection to improve stability when connection closes unexpectedly
Changes to version 1.2.0
------------------------
- IEC 61850/MMS client/server: Added TLS support (TLS API and implementation for mbedtls)
- IEC 61850/MMS server: removed deprecated AttributeChangedHandler
- Added pkg-config file
- The Sampled Values APIs have been renamed. The old version of the API is deprecated but still supported and will be removed in the next major version of the library.
- SV Publisher/Subscriber: a lot of small fixed and improvements
- .NET API: Added support for sampled values (SV) subscriber
- .NET API: Added support for GOOSE subscriber
- SV subscriber: added function SVReceiver_enableDestAddrCheck
- IEC 61850 server: fixed bug in buffered report module - report can be lost under some circumstances when BRCB is enabled
- SV subscriber: replaced code that caused unaligned memory access
- IEC 61850 server: added memory alignement for buffered reporting
Changes to version 1.1.2
------------------------
- MMS client: fixed parsing initiate response message
- SV publisher: conditional encoding for SmpRate
- MmsValue_update function now allows adjusting octet-string size of target object
- .NET API: Added DeleteFile
- CDC helper functions: added helper functions for VSS and VSG CDC
- added additional locks in client and server
Changes to version 1.1.1
------------------------
- IEC 61850 client: fixed bug in APC control handling
- IEC 61850 client: ClientReportControlBlock now accepts "$" and "." as seperator for RCB object reference
- MMS client: fixed bug in MmsConnection_connect (COTP payload buffer was not reset in case of an error during connect -> connection failed in case of reuse of MmsConnection object
- MMS client: delete named variable list service supports VMD specific lists
- SV subscriber/publisher: additional features and bug fixes
- SV: fixed data type for smpRate
- SV: fixed encoding of optional smpMod attribute
- SV receiver: Added semaphore to make subscriber list thread-safe
- .NET API: ControlObject implements IDisposable interface
- IED server: added new function IedServer_udpateDbposValue
- fixed problem with cmake include folders
- MMS client: file services -fixed encoding problem with long file names
- MMS server: ACSE authenticator passes application reference (ap-title and ae-qualifier)
- example directory cleanup
- MMS: fixed potential memory leak in asn1 code that can be caused by malformed MMS messages
- MMS client: MmsConnection_getVariableAccessAttributes support for VMD specific variables
- Java SCL parser: added support for "Val" elements for Octet64 types
Changes to version 1.1.0
------------------------
- MMS client/server: added write support for named variable lists
- IEC 61850 client/server: added support for SetDataSet service
- C# API: client - added support to write data set values
- IEC 61850 client: Changed result strings of IedConnection_getDataDirectoryByFC. Removed appended FC string.
- MMS client/server: extended BER encoder to support MMS PDU sizes with more than 64k
- C# API: server - keep references to internal control handler delegates to avoid garbage collection
- IEC 61850 server: added IedModel_getDeviceByInst function
- SV subscriber: added subscriber side handling for RefrTm
- SV publisher: Changed SampledValuesPublisher_create to support setting of Communication parameters at runtime
- socket-win32: updated WSA initialization handling
- all: small fixes and code optimizations
Changes to version 1.0.2
------------------------
- server: added MmsFileAccessHandler for server side monitoring and control of file services
- file services: added support to set filestore basepath at runtime
- added IedConnection_getFileDirectoryEx to better control receiving file directories
- common: added timestamp handling functions Timestamp_create, Timestamp_destroy, Timestamp_setByMmsUtcTime, Timestamp_toMmsValue
- .NET API: Added Timestamp class
- .NET API: Added missing UpdateAttribute methods to IedServer
- common: added support for Currency BasicType
- MMS file services: fixed problem with negative frsmId
- java scl tools: fixed bug with SDOs in dynamic code generator
- java scl tools: fixed parsing bug in OptionFields.java
- server: added functions to restrict local IP address IedServer_setLocalIpAddress, IedServer.SetLocalIpAddress
- .NET: IedConnection: added internal reference to IsoConnectionParameters object to avoid deletion of internal AcseAuthenticationParameters by garbage collector
Changes to version 1.0.1
------------------------
- server: fixed problem in COTP src/dst reference handling (returning zero src reference)
- client: fixed problem in report handling when RCB contains no rptID
- Python: added pyiec61850 tutorial and example thanks to Cédric Boudinet
- .NET API: fixed server side bug with connection indication handler
- added Lantronix XPORT PRO uclinux make target
- .NET API: fixed bug in client readValue functions
- .NET API: added MmsValue.GetDataAccessError() method
Changes to version 1.0.0
------------------------
- MMS client/server: implemented obtainFile service
- client/server: implemented setFile service
- fixed bug in MmsValue_getNumberOfSetBits
- hardened client report handling
- added FileSystem_writeFile function required for obtainFile service
- added server1 example for .NET
- fixed problems in windows .def files
Changes to version 0.9.3
------------------------
- .NET API: server side API
- .NET API: client side support for log service
- server: added maximum number of log entries for log service
- client: added callback to provide user access to raw MMS functions
- SV: added FLOAT64 support
Changes to version 0.9.2.1
--------------------------
- server: fixed some memory access problens in dynamic model LCB
- server: fixed some minor problems with stack configuration options
- client: added IEC61850_REASON prefix to inclusion reason code values for reporting
Changes to version 0.9.2
------------------------
- client/server: support for MMS journals and IEC 61850 log service
- Abstract interface for log storage providers: logging_api.h and LogStorage class
- log storage implementation using sqlite
- server: negative delete data set response is now compatible with new test procedures (TPCL 1.1)
- FileSystem API is now intended to access the complete file system. Path translation for VMD filestore is done by MMS file service implementation (removed FileSystem_setBasePath function)
- added CDC_DPL_create function
- MMS server: fixed race condition when opening/closing connections in multi-threaded configuration.
- client: IedConnection_readObject and IedConnection_getVariableSpecification functions can now be applied to whole LNs
- client: GetLogicalNodeDirectory for data set and log ACSI classes will not use cached model data but request the information from server. This way the client can get up to date information about newly created dynamic data sets
- changed HAL thread implementation for bsd to be compatible with MacOS X 10.10
- fixed problem with test case sSgN4: return temporarily-unavailable when no EditSG is selected
- fixed bug in ethernet_win32.c
Changes to version 0.9.1
------------------------
- client: added function MmsConnection_getMmsConnectionParameters
- client: new functions to reset synchro and interlock bits for control clients
- some extensions to C# API
- integrated some under the hood changes to be more compliant with certification tests.
- added CMake recipe to create python bindings
- added functions MmsValue_encodeMmsData, MmsValue_decodeMmsData to serialize/deserialize MmsValue objects to BER encoded MMS Data
- changed signature of IedConnection_deleteDataSet, MmsConnection_deleteAssociationSpecificNamedVariableList, MmsConnection_deleteNamedVariableList. added boolean return value to indicate if data set/named variable list has been deleted.
Changes to version 0.9.0.2
--------------------------
- added CONFIG_IEC61850_EDITION_1 configuration option to enable server builds for edition 1 (at the moment only remove "Owner" form RCBs).
- fixed encoding problem with negative frsmId in client file read service
- allow 1 to 16 octet size ISO session selector (small API change in IsoConnectionParameters methods)
- added C++ compatible headers to GOOSE/SV publisher headers
- server: fixed problem in GetFileDirectory-service with a single file as parameter
- added goose_publisher_example to cmake
Changes to version 0.9.0.1
--------------------------
- fixed problem with windows build with GOOSE and SV support
Changes to version 0.9
----------------------
- Sampled values subscriber code
- Experimental sampled values publisher and MMS SVCB code
- server: support for VMD scope data sets (MMS named variable lists)
- .NET API: added MmsConnection.setLocalDetail and MmsConnection.getLocalDetail
- example server/sv publisher according to IEC 61850-9-2LE
- server: multi-threaded configuration now uses select instead of socket polling
- .NET API: some additional methods for MmsValue class
- server: fixed bug with nested directories in file service
- mms_utility: added read file directory feature
- SCL parser/modelviewer: show unused types in SCL file
- server: fixed some problems related to buffered reporting UCA test cases
- other bug fixes
Changes to version 0.8.7
------------------------
- client: added client side control service support for edition 1 and 2 APC CDCs
- client: ControlObjectClient uses GetVarSpec instead of GetNameList and ReadData to get required information from the server (compatible with more server implementations)
- client: Added function ControlObjectClient_useConstantT to support constant T parameter during a control sequence (required my some non-standard conformant servers)
- server: Fixed problem with SqNum in RCBs and reports
- windows file provider now supports unicode file name and converts them to UTF-8
- some small API changes (some char* parameter became const char*; new function ClientReport_getDataSetName)
- client API: added function ClientReport_getDataSetName
- .NET API: new methods Report.GetDataSetName, ReportControlBlock.GetEntryID, ReportControlBlock.SetEntryID, Dispose methods for ReportControlBlock and IedConnection classes
- .NET API: fixed bug with garbage collected CommandTerminationHandler
- server: getNameList response with alphabetically sorted variable names (configurable by CONFIG_MMS_SORT_NAME_LIST option)
- server: only client that set EditSG can change EditSG and modify variables with FC=SE
- server: changed ControlObjectClient_create function: doesn't read "Oper" and uses GetVarSpec instead of GetNameList service
- extended beoglebone demo (write access to GAPC settings, ...)
- server: File service: support for wildcard character ('*') in requests; support for flat file list
- server: changed signature of WriteAccessHandler: Handler now returns MmsDataAccessError instead of boolean value!
- server: added function IedModel_setIedNameForDynamicModel
- and some more small changes and bug fixes
Changes to version 0.8.6
------------------------
- demos: extended beaglebone demo to use SBO control
- common: fixed bug that led to wrong encoding of large unsigned integer values on big endian systems
- server: fixed server crash problem when read request contains only LN but no FC
- server: fixed server sending empty report when RCB is disabled while report is pending during bufTm
- server: fixed server allowed creation of dynamic data set with wrong LD name
- server: sending type-inconsistent instead of unknown-error when receiving a write request with invalid value type
- server: fixed server side SBO control handling code provides wrong ClientConnection object to PerformCheckHandler
- client: fixed client does not correctly handle GCBs for edition 1 devices. Also will fail for edition 2 devices when optional elements are missing.
- GOOSE subscriber: fixed - subscriber rejects messages with trailing data (like PRP trail)
- server: added support for multiple data models with static model generator.
- client: added function ClientReport_getBufOvfl to client API
- dotnet: added support to access report entry ID
Changes to version 0.8.5
------------------------
- server/GOOSE: better support for GOOSE minTime, maxTime
- server/GOOSE: it is now configurable which GoCB elements are writable
- server: fixed problem (buffer overflow) with large report data sets
- server: improved memory handling in report generation module
- server/GOOSE: added IedServer_setGooseInterfaceId to change ethernet interface for GOOSE at runtime
- server: fixed bug in delete data set service (server crashed when client sent an unknown LD name)
- client: fixed memory leak in IedConnection_readDataSetValues function
- server: fixed memory alignement problem for buffered reporting on ARM platform
- client: fixed timeout bug in Socket_connect functions
- windows: fixed problem with non-blocking socket send function on windows (as a consequence COTP fragmentation and file read service didn't work on the windows platform).
Changes to version 0.8.4
------------------------
- server: implemented all optional report elements for buffered reporting
- server: fixed bug (server crash) for buffered reporting of integer values
- client: client closes socket after timeout when sending an ABORT message
- common: removed wrong transport disconnect parameter from session FINISH message
- client: LastApplError contrlObj detection is now more robust
- SCL parser: parser consider default values from "DataTypeTemplates" section
- server: now sending error message when client sends a getDataDefinition with wrong domain name
- server: fixed standard deviations in unbuffered reporting
- server: predefined data sets can contain element of multiple logical devices
- MMS server: added callbacks for deletion and creation of new data sets (named variable lists)
- and a lot of small buf fixes
Changes to version 0.8.3
------------------------
- client: better support for optional report elements
- server: fixed some minor problems with reporting
- C# API: Fixed report handler and other problems in C# wrapper layer
- C# API: Fixed problem with data set creation
- server: support for association specific data sets in reports
- server: added bufOvl support for buffered reporting
- server: added support for data-references in reports
- server: fixed server crash when client tries to read structured SE variables
- SCL: configuration file creator supports default values from SCL type templates
Changes to version 0.8.2
------------------------
- Client: Added adjustable timeout to connect functions
- Client: Support for T selectors with different size than two bytes
- GOOSE publisher: added support for explicit GoID
- GOOSE subscriber: refactored subscriber
- Server: Added support for setting groups
- Server: Added support for data references in reports
- SCL parser: support for "Val" attributes in DA type definitions
- Server: Added function to disable all GOOSE publishing
- Client/Server: added helper functions for Dbpos
- C# API: more features and improved stability
Changes to version 0.8.1
------------------------
- IEC 61850/MMS client: IedConnection and MmsConnection objects can now be reused
- reorganization of library header files
- C# API provides support for bit string and octet string data type
- IEC 61850 client/server: Added support for CommandTermination-
- C# API added handler for CommandTermination messages
- IEC 61850 server: IED name for static device model can now be configured at runtime
- Client/server: Fixed problem with association specific data sets
- GOOSE: fixed triggering GOOSE reports for data set members without trigger condition set
- Linux/Windows/BSD: added support for select based socket read (reduces CPU load)
- C# API added support for file services
- a lot of small bug fixes
Changes to version 0.8
-----------------------
- HAL: socket layer. Some changes. read and accept are now non-blocking. Changes the standard implementations (Linux/POSIX, WIN32, BSD) accordingly
- server stack: added single-threaded and threadless operation modes to better fit to resource constraint devices (added new configuration option CONFIG_MMS_SINGLE_THREADED)
- some small changes in server side control model handling (ControlHandler return values and behaviour) to enable threadless and single-threaded operation.
- C# client API extended and XML documentation completed
- some smaller bug fixes and extensions
Changes to version 0.7.8
------------------------
- IED client: added client side support for Ed.1 compliant control (client side automatically detects if a control is ed1 or ed2 compliant)
- Tools: SCL parser throws exceptions if names are defined multiple times in the same context
- build support for FreeBSD (gmake and cmake)
- server: fixed BER encoding problen in file close/delete response messages
- server: fixed wrong reason-for-inclusion encoding for GI/integrity reports in buffered reporting
- server: fixed endianess issue with report entry id
- Configuration tools: fixed bug in static model generator - generator does not create RCBs for all logical devices
- mms server: added support for vmd-scope named variables
- mms server: support for standard MMS get-name-list behaviour (no flat address space)
- common: refactored MmsValue string handling
- some small extensions to C# client API
Changes to version 0.7.7
------------------------
- client: fixed encoding bug in file close service
- Configuration tools: fixed code generator problem with index report control blocks
- Configuration tools: fixed problem with multiple data sets in a logical node
- Configuration tools: configuration file generator can now handle arrays of data objects
- Configuration toosl: configuration file generator does now properly define predefined unicode strings
- removed some older functions of client API report setup in favor of ClientReportControlBlock
- client side report handling does no longer require to read the data set before reports can be received
- added preview version of C# client API
- added support (HAL) for Mac OS X (thanks to Michael Clausen - HES-SO Valais-Wallis)
- some fixes in server side report handling (data set containing complex data attributes or FCDOs)
- buffered reporting: fixed problem when buffer can only hold a single entry
- fixed problem in function MmsValue_cloneToBuffer used by buffered reporting
- fixed problem in GOOSE publisher (sqNum starts with 1 instead of 0)
- added convenience methods IedServer_updateInt64AttributeValue and IedServer_updateVisibleStringAttributeValue
- added conditional extern "C" declaration to header files for use in C++ projects
- server now closes TCP socket after sending the ACSE release message
Changes to version 0.7.6
------------------------
- Server: fixed bug: authenticator will be called and can accept client connection even if no authentication value is provided
- Tools: SCL parser accepts SCL files without communication section
- Server: fixed missing support for nested control objects (required to support IEC 61400-25-2)
- client API: fixed some bugs in client API functions of version 0.7.5
- client API: added support to receive CommandTermination message of enhanced control models
- server API: new function to get access to DataAttribute references without knowing the IED name
- some other small changes...
Changes to version 0.7.5
------------------------
- Client API: added convenience functions to avoid direct handling with MmsValue instances
- Added timestamp handling functions
- Configuration tools (genmodel/genconfig) allow specification of access point and IED for SCL files containing more then one IED / access point
- client/server: COTP layer is now more efficient
- added server example to illustrate using arrays of data objects
- MMS server: fixed potential dead-lock problem server side
- IED server: solved problem that client writes didn't trigger a report
- MMS server: fixed problem in fileDirectory response
- server: removed optional transfer syntax field in ACSE layer to improve compatibility with some clients
- some other smaller bug fixes ...
Changes to version 0.7.4
------------------------
- Configurations tools: fixed bug with default values and short addresses for sub data objects and sub data attributes
- DLL build with Visual Studio now exports functions
- server stack is more configurable (some services can be excluded to reduce binary size)
- improved doxygen documentation
- Client API: control service supports originator value (orIdent/orCat)
- Server: control service checks for valid originator value
- fixed problem with blocking client abort function
- Server API: helper functions for dynamic data model creation now contains support for most CDCs of IEC 61850-7-3 (Ed.2)
- Client API: client report structure now provides access to report timestamp
- Configuration tool: fixed data set problem with static model generator of 0.7 series
- fixed some other minor problems ...
Changes to version 0.7.3
------------------------
- Server/Client: MMS deleteFile and renameFile services
- IEC client API: deleteFile ACSI service
- fixed bug when compiling for big endian systems
- Client/Server API: added Quality data type and handling functions
- Server API: added IedServer_updateQuality, IedServer_updateFloatAttributeValue.. convenience functions.
- extended cmake builder (contains some experimental configuration options)
- added install target to cmake and make build systems.
Changes to version 0.7.2
------------------------
- Server API: added API to create data models at runtime
- Server: added some helper functions to create common CDCs at runtime
- Server/ Server API: added configuration file parser
- Server: Implemented AcseAuthenticator to provide more flexible authentication and access control schemes
- Server: added windows support for file services (both for Visual Studio and MinGW)
- Server/Tools: Added access to data attributes by simple integer short addresses ("sAddr" SCL file attribute)
- Tools: added configuration file generator tool
- Added examples for using file services and dynamic model features
- GOOSE publisher: fixed bug - sending wrong confRef field
Changes to version 0.7.1.1
--------------------------
- Server: fixed long term stack memory leak present in versions 0.7 and 0.7.1
Changes to version 0.7.1
------------------------
- Server API: Added IedServer_getFunctionalConstrainedData function to simplify handling of arrays of data objects.
- Client API: Made connetion parameters for ACSE and lower layers fully configurable (AP-title, AEQualifier, PSel, SSel, TSel) - required to be compatible with some servers
- MMS server: made number of concurrent TCP connections configurable by CONFIG_MAXIMUM_... define
- MMS client/server: added MMS status services
- MMS server: made MMS identify service optional
- added file access abstraction to HAL
- MMS client/server: added getFileDirectory, fileOpen, fileRead, fileClose services
- Client/server: added GetFile ACSI service
Changes to version 0.7
-----------------------
- Server: added support for buffered reporting
- Server: Bug fix: trigger reasons for reports are taken from SCL file
- Server/Server API: added callback to perform access control on write accesses
- Server/Server API: added default access policies to writable FCs
- Client API: get/setGoCBValues ACSI services - new ClientGooseControlBlock class
- Client API: added callbacks for connection losses
- GOOSE Subscriber: API change -> use GoCBReference instead of DataSetReference to identify a GOOSE message
- GOOSE Subscriber: Bug fix: Linux driver now switches interface to promiscuous mode.
- MMS Client: improved buffer handling
- MMS Client/MMS Client API: Added functions to browse and read VMD scope variables
- Client/Client API/Server: Implemented ABORT and RELEASE services
- Client API: Allows definition of association specific data sets
- MMS Client API: Removed all occurances of MmsIndication type in MMS client API
Changes to version 0.6
------------------------
- Client API: getDataSetDirectory ACSI service
- Client API: create and delete data set ACSI services
- Client API: added getRCBValue/setRCBValues ACSI services to improve client support for reporting
- client side stack: improved error handling
- Client API: Methods to allow clients track the connection state
- Client API: Report handler provides access to reason-for-inclusion
- Server API: added callbacks for connection events
- Server API: new ClientConnection object that will be handed over to some callback functions to allow connection specific reactions on events -> some callback handler signatures have changed!
- Added server side support for indexed RCBs
- more efficient server side buffer handling
- added BeagleBone LED control demo
- DEBUG output can be switched on/off for stack components
- and a lot of small improvements and bug fixes
Changes to version 0.5.3
------------------------
- MMS client/server: multiple variables can be written with a single MMS write request
- changed encoding of boolean to be compatible with buggy server devices
- added TCP keep alive support to MMS client
- added IedConnection_triggerGIReport function
- some enhancements in server side report handling
- some bug fixes
Changes to version 0.5.2.1
--------------------------
- all examples now compile with VC++
- CMake script supports GOOSE for Windows if winpcap is available
Changes to version 0.5.2
------------------------
- fixed problem when compiling with MINGW
- changed order of FC named variables according to standard
- fixed some other compatibility problems
- allows read access to sub-elements of control variables
- allows write access to GoCB if the control block is not enabled
- allows dynamically generated datasets to be used with GOOSE
Changes to version 0.5.1
------------------------
- made code compatible with Visual Studio C++ (tested with versions 2010/2012)
- added new build system based on cmake. It is now possible to create solution and project files for different versions ofVisual Studio as well as for other IDEs/toolchains.
- fixed interoperability problem in ACSE layer
- added server side support to use dynamically created data sets in reports (addSubscription service according to IEC 61400-25)
Changes to version 0.5
----------------------
- client support for control
- client support for multiple outstanding requests.
- full server support for all control models and time avtivated control
- added client and server support for MMS identify service
- extended build system to build shared libraries (linux shared objects and DLLs) with "make dynlib"
- some small bug fixes in model generator tool
- fixed bug in handling reject messages
Changes to version 0.4.1
------------------------
- SCL parser/code generator is more tolerant
- ubrcb supports resv handling
- fixed problems in presentation layer
- fixed problems when running on 64 bit systems
Changes to version 0.4.0.2
--------------------------
- removed too strict requirements in accepting session layer accept message client side.
- fixed memory management bugs in client and server.
Changes to version 0.4.0.1
--------------------------
- fixed problem in client association request message in new presentation layer code
- MMS read access to GoCB and control objects is now more flexibel to be compatible with more clients
Changes to version 0.4
----------------------
- GOOSE publisher for windows based on winpcap
- GOOSE subscriber for linux and windows
- Started to implement a IEC 61850 client API (supported functions yet: read/write variables, simple model discovery functions, support for receiving reports)
- reimplemented presentation layer and ACSE for more efficient memory handling.
- changed error handling in MMS client
Changes to version 0.3.3.1
--------------------------
- fixed bug in MMS client that causes a segmentation fault when the connection to the server cannot be established.
Changes to version 0.3.3
------------------------
- added facility to observe write access to individual data attributes.
- added experimental GOOSE publisher code for Linux. The server also exposes configuration parameters with the GoCB.
- Server now respects the "BufTm" parameter as set by the client or SCL file. This allows related events to be accumulated for the period of time specified by "BufTm" and reported in a single report message.
Changes to version 0.3.2
------------------------
- added support functions for MMS time types (MMS_BINARY_TIME and MMS_UTC_TIME).
- improved server side support for reporting. Reports can now contain TimeOfEntry values. The server now
respects most of the options for reports set by the client.
- added Semaphore functions to HAL API (thread.h). Semaphores are used by the server stack for internal
synchonization.
- fixed bugs in code that is responsible for remote access to report control blocks.
- fixed bug in COTP code when TPDU size is larger than 1024 bytes. TPDU size can now be as large as 16384 bytes.
- fixed bug in Hal_getTimeInMs function for Windows. Window filetime value will now be correctly converted.
- fixed problems with read access to complex array types (arrays of constructed attribute classes).
Changes to version 0.3.1
------------------------
- improved support for reporting - more options are possible, reason code can be included in reports
- basic support for control model (operate) in server and server API
- added server example for control model (server_example3)
Changes to version 0.3
----------------------
- change server API, access to data model via handles
- SCL file parser supports buffered and unbuffered report control blocks
- server support for unbuffered reporting (supported triggers are GI, integrity and value update)
- MMS client support for MMS information reports
- MMS stack supports fragmented transmission for MMS getNameList service
- new structure for examples directory -> each example is in its own directory and has its own Makefile
- server support for additional ACSI types -> better support for IEC 61850 data models
- server enforces write access restrictions to the IEC 61850 data model based on functional constraints.
- added support for TCP keepalive
- and a lot of bug fixes
Changes to version 0.2.1
------------------------
- fixed bug in SCL file parser
- Added doxygen generated documentation to source distribution
- some bug fixes
Changes to version 0.2
-----------------------
- Support for association specific data sets (named variable lists)
- Support for permanent data sets configured in SCL file
- fixed bug when deleting data sets
- data sets can now contain variables of different MMS domains (IEC 61850 logical devices)
- Changed handling of MMS GetNameList service in MMS client API
Changes to version 0.1.1
-------------------------
- a template project and makefile to simplify getting started with the library.
- New implementation of the model generator tool that now contains its own SCL file parser.

View File

@ -1,198 +0,0 @@
cmake_minimum_required(VERSION 3.5.1)
# automagically detect if we should cross-compile
if(DEFINED ENV{TOOLCHAIN})
set(CMAKE_C_COMPILER $ENV{TOOLCHAIN}gcc)
set(CMAKE_CXX_COMPILER $ENV{TOOLCHAIN}g++)
set(CMAKE_AR "$ENV{TOOLCHAIN}ar" CACHE FILEPATH "CW archiver" FORCE)
endif()
project(libiec61850)
ENABLE_TESTING()
set(LIB_VERSION_MAJOR "1")
set(LIB_VERSION_MINOR "5")
set(LIB_VERSION_PATCH "3")
set(LIB_VERSION "${LIB_VERSION_MAJOR}.${LIB_VERSION_MINOR}.${LIB_VERSION_PATCH}")
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/third_party/cmake/modules/")
# feature checks
include(CheckLibraryExists)
check_library_exists(rt clock_gettime "time.h" CONFIG_SYSTEM_HAS_CLOCK_GETTIME)
# check if we are on a little or a big endian
include (TestBigEndian)
test_big_endian(PLATFORM_IS_BIGENDIAN)
set(CONFIG_MMS_MAXIMUM_PDU_SIZE "65000" CACHE STRING "Configure the maximum size of an MMS PDU (default 65000)" )
set(CONFIG_MAXIMUM_TCP_CLIENT_CONNECTIONS 5 CACHE STRING "Configure the maximum number of clients allowed to connect to the server")
option(BUILD_EXAMPLES "Build the examples" ON)
option(BUILD_PYTHON_BINDINGS "Build Python bindings" OFF)
option(CONFIG_MMS_SINGLE_THREADED "Compile for single threaded version" ON)
option(CONFIG_MMS_THREADLESS_STACK "Optimize stack for threadless operation (warning: single- or multi-threaded server will not work!)" OFF)
set(CONFIG_MMS_SERVER_MAX_GET_FILE_TASKS 5 CACHE STRING "Configure the maximum number of get file tasks")
set(CONFIG_MMS_MAX_NUMBER_OF_DATA_SET_MEMBERS 100 CACHE STRING "Configure the maximum number of dataSet members")
option(CONFIG_ACTIVATE_TCP_KEEPALIVE "Activate TCP keepalive" ON)
option(CONFIG_INCLUDE_GOOSE_SUPPORT "Build with GOOSE support" ON)
option(CONFIG_USE_EXTERNAL_MBEDTLS_DYNLIB "Build with pre-compiled mbedtls dynamic library" OFF)
set(CONFIG_EXTERNAL_MBEDTLS_DYNLIB_PATH "${CMAKE_CURRENT_LIST_DIR}/third_party/mbedtls/mbedtls-2.28/library" CACHE STRING "Path to search for the mbedtls dynamic libraries" )
set(CONFIG_EXTERNAL_MBEDTLS_INCLUDE_PATH "${CMAKE_CURRENT_LIST_DIR}/third_party/mbedtls/mbedtls-2.28/include" CACHE STRING "Path to search for the mbedtls include files" )
# choose the library features which shall be included
option(CONFIG_IEC61850_CONTROL_SERVICE "Build with support for IEC 61850 control features" ON)
option(CONFIG_IEC61850_REPORT_SERVICE "Build with support for IEC 61850 reporting services" ON)
option(CONFIG_IEC61850_LOG_SERVICE "Build with support for IEC 61850 logging services" ON)
option(CONFIG_IEC61850_SERVICE_TRACKING "Build with support for IEC 61850 service tracking" ON)
option(CONFIG_IEC61850_SETTING_GROUPS "Build with support for IEC 61850 setting group services" ON)
option(CONFIG_IEC61850_SUPPORT_USER_READ_ACCESS_CONTROL "Allow user provided callback to control read access" ON)
option(CONFIG_IEC61850_RCB_ALLOW_ONLY_PRECONFIGURED_CLIENT "allow only configured clients (when pre-configured by ClientLN)" OFF)
set(CONFIG_IEC61850_SG_RESVTMS 300 CACHE STRING "Configure the maximum number of SG RESVTMS")
set(CONFIG_REPORTING_DEFAULT_REPORT_BUFFER_SIZE "65536" CACHE STRING "Default buffer size for buffered reports in byte" )
# advanced options
option(DEBUG "Enable debugging mode (include assertions)" OFF)
option(DEBUG_SOCKET "Enable printf debugging for socket layer" ${DEBUG})
option(DEBUG_COTP "Enable COTP printf debugging" ${DEBUG})
option(DEBUG_ISO_SERVER "Enable ISO SERVER printf debugging" ${DEBUG})
option(DEBUG_ISO_CLIENT "Enable ISO CLIENT printf debugging" ${DEBUG})
option(DEBUG_IED_SERVER "Enable IED SERVER printf debugging" ${DEBUG})
option(DEBUG_IED_CLIENT "Enable IED CLIENT printf debugging" ${DEBUG})
option(DEBUG_MMS_SERVER "Enable MMS SERVER printf debugging" ${DEBUG})
option(DEBUG_MMS_CLIENT "Enable MMS CLIENT printf debugging" ${DEBUG})
option(DEBUG_GOOSE_SUBSCRIBER "Enable GOOSE subscriber printf debugging" ${DEBUG})
option(DEBUG_GOOSE_PUBLISHER "Enable GOOSE publisher printf debugging" ${DEBUG})
option(DEBUG_SV_SUBSCRIBER "Enable Sampled Values subscriber debugging" ${DEBUG})
option(DEBUG_SV_PUBLISHER "Enable Sampled Values publisher debugging" ${DEBUG})
option(DEBUG_HAL_ETHERNET "Enable Ethernet HAL printf debugging" ${DEBUG})
include_directories(
${CMAKE_CURRENT_BINARY_DIR}/config
${CMAKE_CURRENT_LIST_DIR}/src/common/inc
${CMAKE_CURRENT_LIST_DIR}/src/goose
${CMAKE_CURRENT_LIST_DIR}/src/sampled_values
${CMAKE_CURRENT_LIST_DIR}/src/hal/inc
${CMAKE_CURRENT_LIST_DIR}/src/iec61850/inc
${CMAKE_CURRENT_LIST_DIR}/src/iec61850/inc_private
${CMAKE_CURRENT_LIST_DIR}/src/mms/inc
${CMAKE_CURRENT_LIST_DIR}/src/mms/inc_private
${CMAKE_CURRENT_LIST_DIR}/src/mms/iso_mms/asn1c
${CMAKE_CURRENT_LIST_DIR}/src/logging
)
set(API_HEADERS
hal/inc/hal_base.h
hal/inc/hal_time.h
hal/inc/hal_thread.h
hal/inc/hal_filesystem.h
hal/inc/hal_ethernet.h
hal/inc/hal_socket.h
hal/inc/tls_config.h
src/common/inc/libiec61850_common_api.h
src/common/inc/linked_list.h
src/iec61850/inc/iec61850_client.h
src/iec61850/inc/iec61850_common.h
src/iec61850/inc/iec61850_server.h
src/iec61850/inc/iec61850_model.h
src/iec61850/inc/iec61850_cdc.h
src/iec61850/inc/iec61850_dynamic_model.h
src/iec61850/inc/iec61850_config_file_parser.h
src/mms/inc/mms_value.h
src/mms/inc/mms_common.h
src/mms/inc/mms_types.h
src/mms/inc/mms_type_spec.h
src/mms/inc/mms_client_connection.h
src/mms/inc/mms_server.h
src/mms/inc/iso_connection_parameters.h
src/goose/goose_subscriber.h
src/goose/goose_receiver.h
src/goose/goose_publisher.h
src/sampled_values/sv_subscriber.h
src/sampled_values/sv_publisher.h
src/logging/logging_api.h
)
if(MSVC AND MSVC_VERSION LESS 1800)
include_directories(
${CMAKE_CURRENT_LIST_DIR}/src/vs
)
endif(MSVC AND MSVC_VERSION LESS 1800)
if(CONFIG_USE_EXTERNAL_MBEDTLS_DYNLIB)
set(WITH_MBEDTLS 1)
set(USE_PREBUILD_MBEDTLS 1)
set(MBEDTLS_INCLUDE_DIR ${CONFIG_EXTERNAL_MBEDTLS_INCLUDE_PATH})
endif(CONFIG_USE_EXTERNAL_MBEDTLS_DYNLIB)
if(EXISTS ${CMAKE_CURRENT_LIST_DIR}/third_party/mbedtls/mbedtls-2.28)
set(WITH_MBEDTLS 1)
set(MBEDTLS_INCLUDE_DIR "${CMAKE_CURRENT_LIST_DIR}/third_party/mbedtls/mbedtls-2.28/include")
endif(EXISTS ${CMAKE_CURRENT_LIST_DIR}/third_party/mbedtls/mbedtls-2.28)
if(WITH_MBEDTLS)
add_definitions(-DCONFIG_MMS_SUPPORT_TLS=1)
endif(WITH_MBEDTLS)
include(CheckCCompilerFlag)
check_c_compiler_flag("-Wredundant-decls" SUPPORT_REDUNDANT_DECLS)
if (SUPPORT_REDUNDANT_DECLS)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wredundant-decls")
endif(SUPPORT_REDUNDANT_DECLS)
# write the detected stuff to this file
configure_file(
${CMAKE_CURRENT_LIST_DIR}/config/stack_config.h.cmake
${CMAKE_CURRENT_BINARY_DIR}/config/stack_config.h
)
include_directories(
${CMAKE_CURRENT_LIST_DIR}/hal/inc
)
add_subdirectory("${CMAKE_CURRENT_LIST_DIR}/hal")
if(DEBUG)
set(CMAKE_BUILD_TYPE Debug)
endif(DEBUG)
if(BUILD_EXAMPLES)
add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/examples)
endif(BUILD_EXAMPLES)
add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/src)
install(FILES ${API_HEADERS} DESTINATION include/libiec61850 COMPONENT Development)
if(BUILD_PYTHON_BINDINGS)
add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/pyiec61850)
endif(BUILD_PYTHON_BINDINGS)
set(CPACK_PACKAGE_DESCRIPTION "IEC 61850 MMS/GOOSE client and server library")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "IEC 61850 MMS/GOOSE client and server library")
set(CPACK_PACKAGE_VENDOR "MZ Automation GmbH")
set(CPACK_PACKAGE_CONTACT "info@libiec61850.com")
set(CPACK_PACKAGE_VERSION_MAJOR "${LIB_VERSION_MAJOR}")
set(CPACK_PACKAGE_VERSION_MINOR "${LIB_VERSION_MINOR}")
set(CPACK_PACKAGE_VERSION_PATCH "${LIB_VERSION_PATCH}")
set(CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}_${LIB_VERSION_MAJOR}.${LIB_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}_${CMAKE_SYSTEM_PROCESSOR}")
set(CPACK_SOURCE_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}_${LIB_VERSION_MAJOR}.${LIB_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
set(CPACK_COMPONENTS_ALL Libraries Development Applications)
#set(CPACK_PACKAGE_INSTALL_DIRECTORY "${CMAKE_PROJECT_NAME}")
if(EXISTS "${CMAKE_ROOT}/Modules/CPack.cmake")
include(InstallRequiredSystemLibraries)
include(CPack)
endif(EXISTS "${CMAKE_ROOT}/Modules/CPack.cmake")

View File

@ -1,674 +0,0 @@
GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The GNU General Public License is a free, copyleft license for
software and other kinds of works.
The licenses for most software and other practical works are designed
to take away your freedom to share and change the works. By contrast,
the GNU General Public License is intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains free
software for all its users. We, the Free Software Foundation, use the
GNU General Public License for most of our software; it applies also to
any other work released this way by its authors. You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.
To protect your rights, we need to prevent others from denying you
these rights or asking you to surrender the rights. Therefore, you have
certain responsibilities if you distribute copies of the software, or if
you modify it: responsibilities to respect the freedom of others.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must pass on to the recipients the same
freedoms that you received. You must make sure that they, too, receive
or can get the source code. And you must show them these terms so they
know their rights.
Developers that use the GNU GPL protect your rights with two steps:
(1) assert copyright on the software, and (2) offer you this License
giving you legal permission to copy, distribute and/or modify it.
For the developers' and authors' protection, the GPL clearly explains
that there is no warranty for this free software. For both users' and
authors' sake, the GPL requires that modified versions be marked as
changed, so that their problems will not be attributed erroneously to
authors of previous versions.
Some devices are designed to deny users access to install or run
modified versions of the software inside them, although the manufacturer
can do so. This is fundamentally incompatible with the aim of
protecting users' freedom to change the software. The systematic
pattern of such abuse occurs in the area of products for individuals to
use, which is precisely where it is most unacceptable. Therefore, we
have designed this version of the GPL to prohibit the practice for those
products. If such problems arise substantially in other domains, we
stand ready to extend this provision to those domains in future versions
of the GPL, as needed to protect the freedom of users.
Finally, every program is threatened constantly by software patents.
States should not allow patents to restrict development and use of
software on general-purpose computers, but in those that do, we wish to
avoid the special danger that patents applied to a free program could
make it effectively proprietary. To prevent this, the GPL assures that
patents cannot be used to render the program non-free.
The precise terms and conditions for copying, distribution and
modification follow.
TERMS AND CONDITIONS
0. Definitions.
"This License" refers to version 3 of the GNU General Public License.
"Copyright" also means copyright-like laws that apply to other kinds of
works, such as semiconductor masks.
"The Program" refers to any copyrightable work licensed under this
License. Each licensee is addressed as "you". "Licensees" and
"recipients" may be individuals or organizations.
To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of an
exact copy. The resulting work is called a "modified version" of the
earlier work or a work "based on" the earlier work.
A "covered work" means either the unmodified Program or a work based
on the Program.
To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.
To "convey" a work means any kind of propagation that enables other
parties to make or receive copies. Mere interaction with a user through
a computer network, with no transfer of a copy, is not conveying.
An interactive user interface displays "Appropriate Legal Notices"
to the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
1. Source Code.
The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.
A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.
The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form. A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.
The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities. However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.
The Corresponding Source need not include anything that users
can regenerate automatically from other parts of the Corresponding
Source.
The Corresponding Source for a work in source code form is that
same work.
2. Basic Permissions.
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met. This License explicitly affirms your unlimited
permission to run the unmodified Program. The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work. This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.
You may make, run and propagate covered works that you do not
convey, without conditions so long as your license otherwise remains
in force. You may convey covered works to others for the sole purpose
of having them make modifications exclusively for you, or provide you
with facilities for running those works, provided that you comply with
the terms of this License in conveying all material for which you do
not control copyright. Those thus making or running the covered works
for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.
Conveying under any other circumstances is permitted solely under
the conditions stated below. Sublicensing is not allowed; section 10
makes it unnecessary.
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.
When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.
4. Conveying Verbatim Copies.
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
5. Conveying Modified Source Versions.
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:
a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.
b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to
"keep intact all notices".
c) You must license the entire work, as a whole, under this
License to anyone who comes into possession of a copy. This
License will therefore apply, along with any applicable section 7
additional terms, to the whole of the work, and all its parts,
regardless of how they are packaged. This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.
d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your
work need not make them do so.
A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
6. Conveying Non-Source Forms.
You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:
a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium
customarily used for software interchange.
b) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by a
written offer, valid for at least three years and valid for as
long as you offer spare parts or customer support for that product
model, to give anyone who possesses the object code either (1) a
copy of the Corresponding Source for all the software in the
product that is covered by this License, on a durable physical
medium customarily used for software interchange, for a price no
more than your reasonable cost of physically performing this
conveying of source, or (2) access to copy the
Corresponding Source from a network server at no charge.
c) Convey individual copies of the object code with a copy of the
written offer to provide the Corresponding Source. This
alternative is allowed only occasionally and noncommercially, and
only if you received the object code with such an offer, in accord
with subsection 6b.
d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
that supports equivalent copying facilities, provided you maintain
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these requirements.
e) Convey the object code using peer-to-peer transmission, provided
you inform other peers where the object code and Corresponding
Source of the work are being offered to the general public at no
charge under subsection 6d.
A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.
A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal, family,
or household purposes, or (2) anything designed or sold for incorporation
into a dwelling. In determining whether a product is a consumer product,
doubtful cases shall be resolved in favor of coverage. For a particular
product received by a particular user, "normally used" refers to a
typical or common use of that class of product, regardless of the status
of the particular user or of the way in which the particular user
actually uses, or expects or is expected to use, the product. A product
is a consumer product regardless of whether the product has substantial
commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.
"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source. The information must
suffice to ensure that the continued functioning of the modified object
code is in no case prevented or interfered with solely because
modification has been made.
If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
adversely affects the operation of the network or violates the rules and
protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
7. Additional Terms.
"Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.
When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders of
that material) supplement the terms of this License with terms:
a) Disclaiming warranty or limiting liability differently from the
terms of sections 15 and 16 of this License; or
b) Requiring preservation of specified reasonable legal notices or
author attributions in that material or in the Appropriate Legal
Notices displayed by works containing it; or
c) Prohibiting misrepresentation of the origin of that material, or
requiring that modified versions of such material be marked in
reasonable ways as different from the original version; or
d) Limiting the use for publicity purposes of names of licensors or
authors of the material; or
e) Declining to grant rights under trademark law for use of some
trade names, trademarks, or service marks; or
f) Requiring indemnification of licensors and authors of that
material by anyone who conveys the material (or modified versions of
it) with contractual assumptions of liability to the recipient, for
any liability that these contractual assumptions directly impose on
those licensors and authors.
All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10. If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term. If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.
If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.
Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above requirements apply either way.
8. Termination.
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).
However, if you cease all violation of this License, then your
license from a particular copyright holder is reinstated (a)
provisionally, unless and until the copyright holder explicitly and
finally terminates your license, and (b) permanently, if the copyright
holder fails to notify you of the violation by some reasonable means
prior to 60 days after the cessation.
Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.
Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
9. Acceptance Not Required for Having Copies.
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
10. Automatic Licensing of Downstream Recipients.
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License. You are not responsible
for enforcing compliance by third parties with this License.
An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations. If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.
You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License. For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
11. Patents.
A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
work thus licensed is called the contributor's "contributor version".
A contributor's "essential patent claims" are all patent claims
owned or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.
Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.
In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement). To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.
If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.
If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.
A patent license is "discriminatory" if it does not include within
the scope of its coverage, prohibits the exercise of, or is
conditioned on the non-exercise of one or more of the rights that are
specifically granted under this License. You may not convey a covered
work if you are a party to an arrangement with a third party that is
in the business of distributing software, under which you make payment
to the third party based on the extent of your activity of conveying
the work, and under which the third party grants, to any of the
parties who would receive the covered work from you, a discriminatory
patent license (a) in connection with copies of the covered work
conveyed by you (or copies made from those copies), or (b) primarily
for and in connection with specific products or compilations that
contain the covered work, unless you entered into that arrangement,
or that patent license was granted, prior to 28 March 2007.
Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
12. No Surrender of Others' Freedom.
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot convey a
covered work so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you may
not convey it at all. For example, if you agree to terms that obligate you
to collect a royalty for further conveying from those to whom you convey
the Program, the only way you could satisfy both those terms and this
License would be to refrain entirely from conveying the Program.
13. Use with the GNU Affero General Public License.
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU Affero General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.
14. Revised Versions of this License.
The Free Software Foundation may publish revised and/or new versions of
the GNU General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the
Program specifies that a certain numbered version of the GNU General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation. If the Program does not specify a version number of the
GNU General Public License, you may choose any version ever published
by the Free Software Foundation.
If the Program specifies that a proxy can decide which future
versions of the GNU General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.
Later license versions may give you additional or different
permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
15. Disclaimer of Warranty.
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. Limitation of Liability.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES.
17. Interpretation of Sections 15 and 16.
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
Also add information on how to contact you by electronic and paper mail.
If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:
<program> Copyright (C) <year> <name of author>
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, your program's commands
might be different; for a GUI interface, you would use an "about box".
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<http://www.gnu.org/licenses/>.
The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
<http://www.gnu.org/philosophy/why-not-lgpl.html>.

View File

@ -1,191 +0,0 @@
LIBIEC_HOME=.
include make/target_system.mk
LIB_SOURCE_DIRS = src/mms/iso_acse
LIB_SOURCE_DIRS += src/mms/iso_acse/asn1c
LIB_SOURCE_DIRS += src/mms/iso_presentation/asn1c
LIB_SOURCE_DIRS += src/mms/iso_presentation
LIB_SOURCE_DIRS += src/mms/iso_session
LIB_SOURCE_DIRS += src/common
LIB_SOURCE_DIRS += src/mms/asn1
LIB_SOURCE_DIRS += src/mms/iso_cotp
LIB_SOURCE_DIRS += src/mms/iso_mms/server
LIB_SOURCE_DIRS += src/mms/iso_mms/client
LIB_SOURCE_DIRS += src/mms/iso_client
LIB_SOURCE_DIRS += src/mms/iso_common
LIB_SOURCE_DIRS += src/mms/iso_mms/common
LIB_SOURCE_DIRS += src/mms/iso_mms/asn1c
LIB_SOURCE_DIRS += src/mms/iso_server
LIB_SOURCE_DIRS += src/logging
ifndef EXCLUDE_ETHERNET_WINDOWS
LIB_SOURCE_DIRS += src/goose
LIB_SOURCE_DIRS += src/sampled_values
endif
LIB_SOURCE_DIRS += src/iec61850/client
LIB_SOURCE_DIRS += src/iec61850/common
LIB_SOURCE_DIRS += src/iec61850/server
LIB_SOURCE_DIRS += src/iec61850/server/model
LIB_SOURCE_DIRS += src/iec61850/server/mms_mapping
LIB_SOURCE_DIRS += src/iec61850/server/impl
ifeq ($(HAL_IMPL), WIN32)
LIB_SOURCE_DIRS += hal/socket/win32
LIB_SOURCE_DIRS += hal/thread/win32
LIB_SOURCE_DIRS += hal/ethernet/win32
LIB_SOURCE_DIRS += hal/filesystem/win32
LIB_SOURCE_DIRS += hal/time/win32
LIB_SOURCE_DIRS += hal/serial/win32
LIB_SOURCE_DIRS += hal/memory
else ifeq ($(HAL_IMPL), POSIX)
LIB_SOURCE_DIRS += hal/socket/linux
LIB_SOURCE_DIRS += hal/thread/linux
LIB_SOURCE_DIRS += hal/ethernet/linux
LIB_SOURCE_DIRS += hal/filesystem/linux
LIB_SOURCE_DIRS += hal/time/unix
LIB_SOURCE_DIRS += hal/serial/linux
LIB_SOURCE_DIRS += hal/memory
else ifeq ($(HAL_IMPL), BSD)
LIB_SOURCE_DIRS += hal/socket/bsd
LIB_SOURCE_DIRS += hal/thread/bsd
LIB_SOURCE_DIRS += hal/ethernet/bsd
LIB_SOURCE_DIRS += hal/filesystem/linux
LIB_SOURCE_DIRS += hal/time/unix
LIB_SOURCE_DIRS += hal/memory
else ifeq ($(HAL_IMPL), MACOS)
LIB_SOURCE_DIRS += hal/socket/bsd
LIB_SOURCE_DIRS += hal/thread/macos
LIB_SOURCE_DIRS += hal/ethernet/bsd
LIB_SOURCE_DIRS += hal/filesystem/linux
LIB_SOURCE_DIRS += hal/time/unix
LIB_SOURCE_DIRS += hal/memory
endif
LIB_INCLUDE_DIRS += config
LIB_INCLUDE_DIRS += hal/inc
LIB_INCLUDE_DIRS += src/common/inc
LIB_INCLUDE_DIRS += src/mms/iso_mms/asn1c
LIB_INCLUDE_DIRS += src/mms/inc
LIB_INCLUDE_DIRS += src/mms/inc_private
LIB_INCLUDE_DIRS += src/goose
LIB_INCLUDE_DIRS += src/sampled_values
LIB_INCLUDE_DIRS += src/iec61850/inc
LIB_INCLUDE_DIRS += src/iec61850/inc_private
LIB_INCLUDE_DIRS += src/logging
LIB_INCLUDE_DIRS += src/tls
ifeq ($(HAL_IMPL), WIN32)
LIB_INCLUDE_DIRS += third_party/winpcap/Include
endif
ifdef WITH_MBEDTLS
LIB_SOURCE_DIRS += third_party/mbedtls/mbedtls-2.28/library
LIB_SOURCE_DIRS += hal/tls/mbedtls
LIB_INCLUDE_DIRS += third_party/mbedtls/mbedtls-2.28/include
LIB_INCLUDE_DIRS += hal/tls/mbedtls
CFLAGS += -D'MBEDTLS_CONFIG_FILE="mbedtls_config.h"'
CFLAGS += -D'CONFIG_MMS_SUPPORT_TLS=1'
endif
LIB_INCLUDES = $(addprefix -I,$(LIB_INCLUDE_DIRS))
ifndef INSTALL_PREFIX
INSTALL_PREFIX = ./.install
endif
LIB_API_HEADER_FILES = hal/inc/hal_time.h
LIB_API_HEADER_FILES += hal/inc/hal_thread.h
LIB_API_HEADER_FILES += hal/inc/hal_filesystem.h
LIB_API_HEADER_FILES += hal/inc/tls_config.h
LIB_API_HEADER_FILES += hal/inc/lib_memory.h
LIB_API_HEADER_FILES += hal/inc/hal_base.h
LIB_API_HEADER_FILES += src/common/inc/libiec61850_common_api.h
LIB_API_HEADER_FILES += src/common/inc/linked_list.h
LIB_API_HEADER_FILES += src/iec61850/inc/iec61850_client.h
LIB_API_HEADER_FILES += src/iec61850/inc/iec61850_common.h
LIB_API_HEADER_FILES += src/iec61850/inc/iec61850_server.h
LIB_API_HEADER_FILES += src/iec61850/inc/iec61850_model.h
LIB_API_HEADER_FILES += src/iec61850/inc/iec61850_cdc.h
LIB_API_HEADER_FILES += src/iec61850/inc/iec61850_dynamic_model.h
LIB_API_HEADER_FILES += src/iec61850/inc/iec61850_config_file_parser.h
LIB_API_HEADER_FILES += src/mms/inc/mms_value.h
LIB_API_HEADER_FILES += src/mms/inc/mms_common.h
LIB_API_HEADER_FILES += src/mms/inc/mms_types.h
LIB_API_HEADER_FILES += src/mms/inc/mms_type_spec.h
LIB_API_HEADER_FILES += src/mms/inc/mms_client_connection.h
LIB_API_HEADER_FILES += src/mms/inc/mms_server.h
LIB_API_HEADER_FILES += src/mms/inc/iso_connection_parameters.h
LIB_API_HEADER_FILES += src/goose/goose_subscriber.h
LIB_API_HEADER_FILES += src/goose/goose_receiver.h
LIB_API_HEADER_FILES += src/goose/goose_publisher.h
LIB_API_HEADER_FILES += src/sampled_values/sv_subscriber.h
LIB_API_HEADER_FILES += src/sampled_values/sv_publisher.h
LIB_API_HEADER_FILES += src/logging/logging_api.h
get_sources_from_directory = $(wildcard $1/*.c)
get_sources = $(foreach dir, $1, $(call get_sources_from_directory,$(dir)))
src_to = $(addprefix $(LIB_OBJS_DIR)/,$(subst .c,$1,$2))
LIB_SOURCES = $(call get_sources,$(LIB_SOURCE_DIRS))
LIB_OBJS = $(call src_to,.o,$(LIB_SOURCES))
CFLAGS += -std=gnu99
CFLAGS += -Wno-error=format
CFLAGS += -Wstrict-prototypes
ifneq ($(HAL_IMPL), WIN32)
CFLAGS += -Wuninitialized
endif
CFLAGS += -Wsign-compare
CFLAGS += -Wpointer-arith
CFLAGS += -Wnested-externs
CFLAGS += -Wmissing-declarations
CFLAGS += -Wshadow
CFLAGS += -Wall
CFLAGS += -Wextra
CFLAGS += -Wno-format
#CFLAGS += -Wconditional-uninitialized
#CFLAGS += -Werror
all: lib
static_checks: lib
splint -preproc +posixlib +skip-sys-headers +gnuextensions $(LIB_INCLUDES) $(LIB_SOURCES)
cppcheck: lib
cppcheck --force --std=c99 --enable=all $(LIB_INCLUDES) $(LIB_SOURCES) 2> cppcheck-output.xml
lib: $(LIB_NAME)
dynlib: CFLAGS += -fPIC
dynlib: $(DYN_LIB_NAME)
.PHONY: examples
examples:
cd examples; $(MAKE)
$(LIB_NAME): $(LIB_OBJS)
$(AR) r $(LIB_NAME) $(LIB_OBJS)
$(RANLIB) $(LIB_NAME)
$(DYN_LIB_NAME): $(LIB_OBJS)
$(CC) $(LDFLAGS) $(DYNLIB_LDFLAGS) -shared -o $(DYN_LIB_NAME) $(LIB_OBJS) $(LDLIBS)
$(LIB_OBJS_DIR)/%.o: %.c config
@echo compiling $(notdir $<)
$(SILENCE)mkdir -p $(dir $@)
$(CC) $(CFLAGS) -c $(LIB_INCLUDES) $(OUTPUT_OPTION) $<
install: $(LIB_NAME)
mkdir -p $(INSTALL_PREFIX)/include
mkdir -p $(INSTALL_PREFIX)/lib
cp $(LIB_API_HEADER_FILES) $(INSTALL_PREFIX)/include
cp $(LIB_NAME) $(INSTALL_PREFIX)/lib
clean:
rm -f $(EXAMPLES)
rm -rf $(LIB_OBJS_DIR)

View File

@ -1,189 +0,0 @@
# README libIEC61850
[![Build Status](https://travis-ci.org/mz-automation/libiec61850.svg?branch=master)](https://travis-ci.org/mz-automation/libiec61850)
This file is part of the documentation of **libIEC61850**. More documentation can be found online at http://libiec61850.com.
The API documentation can be found here:
* C API: https://support.mz-automation.de/doc/libiec61850/c/latest/
* .NET API: https://support.mz-automation.de/doc/libiec61850/net/latest/
Also consider to review the examples to understand how to use the library.
Content:
* [Overview](#overview)
* [Features](#features)
* [Examples](#examples)
* [Building and running the examples](#building-and-running-the-examples-with-the-provided-makefiles)
* [Building the library with TLS support](#building-the-library-with-tls-support)
* [Installing the library and the API headers](#installing-the-library-and-the-api-headers)
* [Building on Windows with GOOSE support](#building-on-windows-with-goose-support)
* [Building with the cmake build script](#building-with-the-cmake-build-script)
* [Using the log service with sqlite](#using-the-log-service-with-sqlite)
* [C# API](#c-api)
* [Experimental Python bindings](#experimental-python-bindings)
* [Licensing](#commercial-licenses-and-support)
* [Contributing](#contributing)
## Overview
libiec61850 is an open-source (GPLv3) implementation of an IEC 61850 client and server library implementing the protocols MMS, GOOSE and SV. It is implemented in C (according to the C99 standard) to provide maximum portability. It can be used to implement IEC 61850 compliant client and server applications on embedded systems and PCs running Linux, Windows, and MacOS. Included is a set of simple example applications that can be used as a starting point to implement own IEC 61850 compliant devices or to communicate with IEC 61850 devices. The library has been successfully used in many commercial software products and devices.
For commercial projects licenses and support is provided by MZ Automation GmbH. Please contact info@mz-automation.de for more details on licensing options.
## Features
The library support the following IEC 61850 protocol features:
* MMS client/server, GOOSE (IEC 61850-8-1)
* Sampled Values (SV - IEC 61850-9-2)
* Support for buffered and unbuffered reports
* Online report control block configuration
* Data access service (get data, set data)
* online data model discovery and browsing
* all data set services (get values, set values, browse)
* dynamic data set services (create and delete)
* log service
** flexible API to connect custom data bases
** comes with sqlite implementation
* MMS file services (browse, get file, set file, delete/rename file)
** required to download COMTRADE files
* Setting group handling
* Support for service tracking
* GOOSE and SV control block handling
* TLS support
* C and C#/.NET API
## Examples
The examples are built automatically when CMake is used to build the library.
NOTE: Most examples are intended to show a specific function of the library. They are designed to show this function as simple as possible and may miss error handling that has to be present in real applications!
## Building and running the examples with the provided makefiles
In the project root directory type
```
make examples
```
If the build succeeds you can find a few binary files in the projects root directory. You can also find a binary version of the library ("libiec61850.a") in the "build" directory.
Run the sample applications in the example folders. E.g.:
```
cd examples/server_example_basic_io
sudo ./server_example_basic_io
```
on the Linux command line.
You can test the server examples by using a generic client or the provided client example applications.
## Building the library with TLS support
Download, unpack, and copy mbedtls-2.28 into the third_party/mbedtls folder.
NOTE: The current version support mbedtls version 2.28. When you download the source archive from https://tls.mbed.org/ you have to rename the extracted folder to "mbedtls-2.28".
In the main libiec61850 folder run
```
make WITH_MBEDTLS=1
```
When using CMake the library is built automatically with TLS support when the folder third_party/mbedtls/mbedtls-2.28 is present.
## Installing the library and the API headers
The make and cmake build scripts provide an install target. This target copies the API header files and the static library to a single directory for the headers (INSTALL_PREFIX/include) and the static library (INSTALL_PREFIX/lib). With this feature it is more easy to integrate libiec61850 in an external application since you only have to add a simple include directory to the build tool of your choice.
This can be invoked with
`make install`
The default install directory for the make build script is ".install".
You can modify this by setting the INSTALL_PREFIX environment variable (e.g.):
`make INSTALL_PREFIX=/usr/local install`
For the cmake build script you have to provide the CMAKE_INSTALL_PREFIX variable
## Building on windows with GOOSE support
To build the library and run libiec61850 applications with GOOSE support on Windows (7/8/10) the use of a third-party library (winpcap) is required. This is necessary because current versions of Windows have no working support for raw sockets. You can download winpcap here (http://www.winpcap.org).
1. Download and install winpcap. Make sure that the winpcap driver is loaded at boot time (you can choose this option at the last screen of the winpcap installer).
2. Reboot the system (you can do this also later, but you need to reboot or load the winpcap driver before running any llibiec61850 applications that use GOOSE).
3. Download the winpcap developers pack from here (http://www.winpcap.org/install/bin/WpdPack_4_1_2.zip)
4. Unpack the zip file. Copy the folders Lib and Include from the WpdPack directory in the third_party/winpcap directory of libiec61850
## Building with the cmake build script
With the help of the cmake build script it is possible to create platform independent project descriptions and let cmake create specific project or build files for other tools like Make or Visual Studio.
If you have cmake installed fire up a command line (cmd.exe) and create a new subdirectory in the libiec61850 folder. Change to this subdirectory. Then you can invoke cmake. As an command line argument you have to supply a "generator" that is used by cmake to create the project file for the actual build tool (in our case Visual Studio 2015).
`cmake -G "Visual Studio 14 2015" ..`
will instruct cmake to create a "solution" for Visual Studio 2015. The resulting project files will be 32 bit.
To build 64 bit libraries the "Win64" generator option has to be added.
`cmake -G "Visual Studio 14 2015 Win64" ..`
Note: The ".." at the end of the command line tells cmake where to find the main build script file (called CMakeLists.txt). This should point to the folder libiec61850 which is in our case the parent directory (..).
Depending on the system you don't have to provide a generator to the cmake command.
To select some configuration options you can use ccmake or cmake-gui.
For newer version of Visual Studio you can use one of the following commands (for 64 bit builds):
For Visual Studio 2017:
cmake -G "Visual Studio 15 2017 Win64" ..
For Visual Studio 2019 (new way to specify the x64 platform):
cmake -G "Visual Studio 16 2019" .. -A x64
## Using the log service with sqlite
The library provides support for the IEC 61850 log service. It provides an abstract interface for a logging database. Included is a driver for using sqlite for logging. This driver can be seen as an example on how to use the abstract logging interface.
You can use the driver by including the src/logging/drivers/sqlite/log_storage_sqlite.c file into your application build.
On Ubuntu Linux (and simpilar Linux distributions) it is enough to install the sqlite dev packages from the standard repository. For other OSes (e.g. Windows) and cross-compiling it is recomended to download the amalagation source code (from https://www.sqlite.org/download.html) of sqlite and copy them to the third_party/sqlite folder.
On windows the cmake skript will detect the sqlite source code and also creates the example project for logging.
## C# API
A C#/.NET wrapper and examples and Visual Studio/MonoDevelop project files can be found in the dotnet folder. The examples and the C# wrapper API can be build and run on .NET or Mono.
## Experimental Python bindings
The experimental Python binding can be created using SWIG with cmake.
To enable the bindings you have to select the phyton configuration option with ccmake of cmake-gui.
We don't provide any support for the Python bindings!
## Commercial licenses and support
Support and commercial license options are provided by MZ Automation GmbH. Please contact info@mz-automation.de for more details.
## Contributing
If you want to contribute to the improvement and development of the library please send me comments, feature requests, bug reports, or patches. For more than trivial contributions I require you to sign a Contributor License Agreement. Please contact info@libiec61850.com.
Please don't send pull requests before signing the Contributor License Agreement! Such pull requests may be silently ignored.

View File

@ -1,5 +0,0 @@
# Security Policy
## Reporting a Vulnerability
Please report security issues to `info@libiec61850.com`

Some files were not shown because too many files have changed in this diff Show More