Commit Graph

113 Commits

Author SHA1 Message Date
Martin Regen 75d8b2ca3c Fix .Net 4.6 Https client and server (#359)
- best possible fix for #189 to reenable https servers 
- `UA Sample Client` and `UA Sample Server` expose https server. libuv.dll is by default for x64. Change 
```
<PropertyGroup>
   <RuntimeIdentifier>win7-x64</RuntimeIdentifier>
   <BaseNuGetRuntimeIdentifier>win7-x64</BaseNuGetRuntimeIdentifier>
</PropertyGroup>
```
to win7-x86 if required.
- fix exception in https client when setting the Timeout
- fix travis build script for linux. kestrel server on ubuntu doesn't respond on ipv6Any ipaddress.
- fix a timing problem in the travis script.
2018-02-20 11:27:00 +01:00
Martin Regen e21f99eaf6 Fixes for https client and server (#346)
* Fixes for https client and server (#38)

HTTPS server fixes:
- Kestrel 2.0 in netcoreapp 2.0 server samples: only responds to some clients, not to UA samples at all. Fix configuration (listen to all ip addresses) 

HTTPS client fixes:

- bug: client gets stuck if subscription is active by nesting too many calls (use async callback)
- https client needs server cert in a trusted store or it refuses connection (auto accept server certs, but fix is not supported on all platforms, e.g. UWP apps still require a cert in the trusted store)
- runtime issues with .Net 4.6. apps (cannot find diagnostics dll) --> workaround is to manually add nuget package of System.Net.http 4.3.3

- Add https connection to travis test script (only .Net Core)

* fix shell script exe

* also listen on ipv6 port

* do not use auto validation on OSX
2018-02-08 13:58:07 +01:00
Martin Regen 9792df49eb IOP workshop fixes for reference server (#341)
* DataValue cannot contain a DataValue by spec
* default to Basic256Sha256
* default DataValue should return null
2018-02-05 14:54:55 +01:00
Martin Regen dbef06aa82 Fix ip address parser, domain name check and reconnect (#333)
* bug fix in cert parser: return normalized ipaddress string instead of hex byte array string
* connect with domain cert check,
* fix ip address compares,
* add dialog to connect anyway if cert domain check fails
* fix reconnect case when cert domain check fails
2018-01-25 08:55:26 -07:00
Martin Regen 9f8affb05f Determine RSA dispose at runtime 2018-01-09 15:38:38 +01:00
Martin Regen 6c417322ea Merge remote-tracking branch 'origin/master' into mono 2018-01-09 13:36:29 +01:00
Martin Regen b627b89797 Merge version update from 1.03 2018-01-05 16:42:19 +01:00
Martin Regen b4d0c3200f Change versioning to allow for patching of nuget packages (#312)
* Fix library versions

* version properly for strong names
2018-01-05 16:31:05 +01:00
Martin Regen 032bc6ade7 remove all dispose from RSA objects to work around mono bug 2017-12-21 15:41:46 +01:00
Martin Regen 8e89b941ed Revert "missed a few usings..."
This reverts commit 4720125a37.
2017-12-21 13:20:43 +01:00
Martin Regen 4720125a37 missed a few usings... 2017-12-20 22:24:59 +01:00
Martin Regen eeec2a8389 Update cert without restarting the TCP listener 2017-12-07 12:05:31 +01:00
Martin Regen 9926e40be8 my own CR feedback 2017-12-06 16:55:43 +01:00
Martin Regen 89b0a652b7 listener socket loss if AcceptAsync returns synchronous 2017-11-28 13:58:25 +01:00
Martin Regen d78b614cb3 Revert "race condition during connect"
This reverts commit e5ce6ccd56.
2017-11-26 16:42:56 +01:00
Martin Regen b615cf20ea listener socket loss if AcceptAsync returns synchronous 2017-11-26 16:41:39 +01:00
Martin Regen e5ce6ccd56 race condition during connect 2017-11-25 13:31:13 +01:00
Martin Regen 05463e8790 Merge branch 'connect_race' into gds_work_certs 2017-11-21 16:26:17 +01:00
Martin Regen da07e3b430 race condition during connect, CTT client may hang on .Net Standard 2.0 server GetEndpoints call 2017-11-21 15:13:08 +01:00
Martin Regen d2356df0fb fix warnings 2017-11-12 19:44:05 +01:00
Martin Regen a5bb127089 Merge remote-tracking branch 'mregen/pushserver' into gds_work_certs 2017-11-07 16:37:16 +01:00
Martin Regen 915ad5b87c - add cert configuration nodes
- Update cert and sign request is still missing
- no security!
2017-11-07 16:33:15 +01:00
Martin Regen 84920ad7ff Opc.Ua.Gds constants and types now in Opc.Ua.Core 2017-10-20 13:14:02 +02:00
Martin Regen 8c57d477db fix a race condition during connect, when both addresses return quickly with an error condition TaskCompletionSource could be signaled twice, causing an exception.
Fix: Advance connection counters before connecting
2017-10-09 15:27:22 +02:00
Martin Regen 5832fc93ac Merge pull request #255 from mregen/adressesasync
Refactor connect code
2017-09-29 11:26:54 +02:00
AlinMoldovean f9bae02357 Fixes #214 - TransportChannel not disposed in ClientBase 2017-09-27 16:58:57 +03:00
Martin Regen e120dd3006 Callback also for error cases and allow to test all IP Adresses, if responses time out. 2017-09-26 22:29:33 +02:00
Martin Regen 2742d4585c enable sha256 in ref server and fix cert validation check 038 (#247)
* enable sha256 in ref server and fix cert validation check 038

* fix localisation issue in authority key parser

* IOP Workshop: ref server doesn't set source timestamp

* Fix localisation issue with cert extension parsing

* fix exception when issuer cert has no auth key serial number/issuer
2017-09-25 17:13:41 +02:00
Martin Regen c0c6833b4c try more addresses if connection is refused 2017-09-17 22:35:51 +02:00
Martin Regen b3c9ce7bc7 Merge pull request #27 from EddiG/refactor
Refactor
2017-09-17 11:21:45 +02:00
Alin Moldovean ce426ae089 Merge pull request #245 from alexandrudicu/master
bugfix in AlarmsConditionState
2017-09-17 11:02:23 +03:00
Martin Regen d850f64f81 Support .netstandard2.0 (#237)
* add missing ref for build in VSO hosted VS 2017 build

* project to just build Dlls

* target multiple frameworks

* switch to net46/netstandard1.3

* fix projects to allow for netcoreapp 2.0 build

* fix networking for .Net Core 2.0:
SendAsync and ReceiveAsync now frequently return synchronously even if successful. These cases had not been properly handled yet, previous versions never hit these codepaths.

* fix travis build / nugets

* change travis build target

* fix Kestrel https option for netstandard 2.0
tested with Ua Expert against standard and ref server

* Handle special case correctly, when zero bytes are received its ok, or BadTimeout will occur

* simplify connect, reduce DiscoverEndpoint calls
2017-09-15 09:37:32 +02:00
Alexandru Dicu 6591f0aa4e AlarmsConditionsState bug
Based on the old code, the conditions are wrong and redundant. The lines 345 and 353 should check for null.
2017-09-15 07:29:14 +03:00
Alin Moldovean 2178fcdb4e Merge pull request #236 from K47S/master
Fix: Multiple servers cannot add their certs to the DiscoveryServer t…
2017-09-06 15:51:18 +03:00
K47S 4726f04c9b Fix: Multiple servers cannot add their certs to the DiscoveryServer trust list when started at the same time 2017-08-29 08:23:34 +02:00
Eduard Gilmutdinov f323ad24d9 Make the socket closing more safely 2017-08-10 23:52:49 -07:00
Eduard Gilmutdinov d112888613 Remove unnecessary lock in TcpMessageSocket 2017-08-10 14:35:08 -07:00
Eduard Gilmutdinov da2d9cf2c1 Remove unnecessary fields in TcpMessageSocket 2017-08-10 14:21:16 -07:00
Eduard Gilmutdinov 6df6828828 Refactoring in TcpMessageSocket 2017-08-10 14:15:28 -07:00
Eduard Gilmutdinov e88d3ab5e3 Fix memory leak 2017-08-10 11:45:19 -07:00
Martin Regen 26881aab7a Client discovery and cert check improvements (#213)
Client discovery and cert check improvements
2017-08-01 17:04:35 +02:00
Erich Barnstedt 56b32c8df2 Remove some legacy code which created trust between a server and an LDS "on the sly", fixed access permission in log file and fixed security level comparision. 2017-07-17 14:52:35 +02:00
Erich Barnstedt cfd82bd704 Fixed HTTPS for .NetCore and disabled it for .Net due to an issue with LibUV (see https://github.com/aspnet/Hosting/issues/1115) 2017-07-03 16:42:16 +02:00
Erich Barnstedt ef8fe340b6 1. Removed SecurityLevel from server config, it is now automatically calculated for each endpoint description.
2. Fixed spelling/grammar in a few places.
2017-05-08 12:29:57 +02:00
Martin Regen 732e7c7a42 issues found in testing 2017-05-02 13:32:41 +02:00
Martin Regen 52af9fdeab Merge branch 'martin_certs' of https://github.com/mregen/UA-.NetStandardLibrary.git 2017-04-29 08:22:10 +02:00
Martin Regen 8053c14468 clean up nonce calls 2017-04-29 08:22:03 +02:00
Martin Regen 86e9714d6c Fix hang1 (#15)
* correctly terminate when remote side closes

* Fix build issue
2017-04-29 08:19:18 +02:00
Martin Regen 3c52cf7761 - allow subjectnames with CN=xxx, O= etc.
- misc. bugfixes
- pen: set default security to highest
- pen: cert default lifetime 12 month
2017-04-27 14:21:47 +02:00
Marc Schier 2af2a4dd75 Add visual studio 2017 solution file to allow building .net Standard … (#150)
* Add visual studio 2017 solution file to allow building .net Standard stack and console samples

* Enable VS 2015 when VS 2017 is installed

* Update readme
2017-03-23 11:17:39 +01:00