Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support use of opc.https endpoint url for client and server. #2140

Merged
merged 15 commits into from
Jun 12, 2023

Conversation

mregen
Copy link
Contributor

@mregen mregen commented May 1, 2023

Proposed changes

Currently the https protocol doesn't support a spec compliant endpoint with a opc.https prefix., as client and server.
Fix:

  • Add the client and server support for the opc.https prefix.
  • Continue support for https prefix for non compliant implementations.
  • Any CancellationTokenSource should be disposed after being used.
  • Follow coding guidelines

Related Issues

Types of changes

What types of changes does your code introduce?
Put an x in the boxes that apply. You can also fill these out after creating the PR.

  • Bugfix (non-breaking change which fixes an issue)
  • Enhancement (non-breaking change which adds functionality)
  • Test enhancement (non-breaking change to increase test coverage)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected, requires version increase of Nuget packages)
  • Documentation Update (if none of the other choices apply)

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have read the CONTRIBUTING doc.
  • I have signed the CLA.
  • I ran tests locally with my changes, all passed.
  • I fixed all failing tests in the CI pipelines.
  • I fixed all introduced issues with CodeQL and LGTM.
  • I have added tests that prove my fix is effective or that my feature works and increased code coverage.
  • I have added necessary documentation (if appropriate).
  • Any dependent changes have been merged and published in downstream modules.

@mregen mregen marked this pull request as draft May 1, 2023 10:49
@mregen mregen added this to the 1.4.372 service update milestone May 1, 2023
@codecov
Copy link

codecov bot commented May 1, 2023

Codecov Report

Merging #2140 (56880f9) into master (29a3be5) will decrease coverage by 0.04%.
The diff coverage is 66.08%.

❗ Current head 56880f9 differs from pull request most recent head f2c56ee. Consider uploading reports for the commit f2c56ee to get more accurate results

@@            Coverage Diff             @@
##           master    #2140      +/-   ##
==========================================
- Coverage   57.97%   57.93%   -0.04%     
==========================================
  Files         324      324              
  Lines       61680    61718      +38     
==========================================
- Hits        35756    35755       -1     
- Misses      25924    25963      +39     
Impacted Files Coverage Δ
...Ua.Core/Stack/Configuration/ConfiguredEndpoints.cs 24.09% <0.00%> (-0.45%) ⬇️
...a.Core/Stack/Transport/TransportChannelSettings.cs 100.00% <ø> (ø)
...Ua.Core/Stack/Configuration/EndpointDescription.cs 60.00% <16.66%> (ø)
Stack/Opc.Ua.Core/Stack/Server/ServerBase.cs 71.67% <60.00%> (-0.32%) ⬇️
...ndings.Https/Stack/Https/HttpsTransportListener.cs 71.27% <66.66%> (-4.42%) ⬇️
....Ua.Bindings.Https/Stack/Https/HttpsServiceHost.cs 85.41% <81.48%> (-0.30%) ⬇️
...indings.Https/Stack/Https/HttpsTransportChannel.cs 82.03% <87.23%> (+0.27%) ⬆️
Stack/Opc.Ua.Core/Stack/Client/DiscoveryClient.cs 67.66% <100.00%> (-10.53%) ⬇️
Stack/Opc.Ua.Core/Stack/Client/UaChannelBase.cs 21.57% <100.00%> (-0.53%) ⬇️
Stack/Opc.Ua.Core/Types/Utils/Utils.cs 58.71% <100.00%> (+0.13%) ⬆️

... and 12 files with indirect coverage changes

@mregen mregen marked this pull request as ready for review June 3, 2023 06:50
@mregen mregen requested a review from mrsuciu June 3, 2023 07:18
@mregen mregen added compliance An issue was found which is not compliant with the OPC UA specification. https Https transport labels Jun 3, 2023
@mregen mregen self-assigned this Jun 3, 2023
@mregen
Copy link
Contributor Author

mregen commented Jun 9, 2023

some issue still arises with macOS...

@mregen mregen merged commit c7bd19d into OPCFoundation:master Jun 12, 2023
43 of 44 checks passed
@mregen mregen deleted the opchttps branch June 12, 2023 07:05
TimJoehnk pushed a commit to TimJoehnk/UA-.NETStandard that referenced this pull request Aug 4, 2023
…dation#2140)

Currently the https protocol doesn't support a spec compliant endpoint with a `opc.https` prefix., as client and server.
Fix:
- Add the client and server support for the `opc.https` prefix. 
- Continue support for `https` prefix for non compliant implementations.
- Any CancellationTokenSource should be disposed after being used.
- Follow coding guidelines
- Use macOS cert callback
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compliance An issue was found which is not compliant with the OPC UA specification. https Https transport
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Resource leak possibility due to not disposing of CancellationTokenSource with Timer
2 participants