Hi there,
I'm getting the "The request was aborted: Could not create SSL/TLS secure channel." error in updater log file, when using an https link in publishing Installation URL. If I use the same link, but with http, then everything is OK.
Following
https://www.add-in-express.com/forum/read.php?FID=5&TID=15706
, I added the ServicePointManager.SecurityProtocol line first in Addin module constructor. No change.
Then I created a separate dll project, with a ClickTwiceModule item, added the ServicePointManager.SecurityProtocol line to the clicktwice module and use the dll as custom action for the downloader and updater when publishing. Still no change.
The .NET framework used in the add-in project is 4.7.2. I'm using automatic silent updates feature.
Any idea how to fix this? It seems to be an issue with the Add-in Express downloader program, a C# .NET 472 sample program that downloads the installer from the same https link works fine, without any ServicePointManager.SecurityProtocol line added.
Thank you for your time!
Adrian
Hello Adrian,
Ionut Adrian writes:
a C# .NET 472 sample program
.NET *applications* using 4.7.2 use TLS 1.3 out of the box. A class library doesn't.
There are two possibilities: 1) that workaround doesn't work any longer (for whatever reason), 2) your code isn't invoked at all. Add a debug message, say using System.Diagnostic.Debug.WriteLine(); you collect such messages at the run time using the DebugView utility.
Andrei Smolin
Add-in Express Team Leader
Hello Andrei,
Following this:
There are two possibilities: 1) that workaround doesn't work any longer (for whatever reason), 2) your code isn't invoked at all. Add a debug message, say using System.Diagnostic.Debug.WriteLine(); you collect such messages at the run time using the DebugView utility.
I added some logging messages to both the Addinmodule constructor and ClickTwiceModule constructor, logging the ServicePointManager.SecurityProtocol state before and after changing it. Here are the code and the log messages.
AddinModule
public AddinModule()
Application.EnableVisualStyles();
InitializeComponent();
// Please add any initialization code to the AddinInitialize event handler
LogWrite("AddinModule. Before. ServicePointManager.SecurityProtocol: " + ServicePointManager.SecurityProtocol.ToString());
ServicePointManager.SecurityProtocol =
SecurityProtocolType.Ssl3 | SecurityProtocolType.Tls
| (SecurityProtocolType)768 /*Tls 1.1*/
| (SecurityProtocolType)3072 /*Tls 1.2*/
| (SecurityProtocolType)12288 /*Tls 1.3*/;
LogWrite("AddinModule. After. ServicePointManager.SecurityProtocol: " + ServicePointManager.SecurityProtocol.ToString());
ClickTwiceModule
public SetupCustomUIClickTwiceModule()
InitializeComponent();
LogWrite("ClickTwiceModule. Before. ServicePointManager.SecurityProtocol: " + ServicePointManager.SecurityProtocol.ToString());
ServicePointManager.SecurityProtocol =
SecurityProtocolType.Ssl3 | SecurityProtocolType.Tls
| (SecurityProtocolType)768 /*Tls 1.1*/
| (SecurityProtocolType)3072 /*Tls 1.2*/
| (SecurityProtocolType)12288 /*Tls 1.3*/;
LogWrite("ClickTwiceModule. After. ServicePointManager.SecurityProtocol: " + ServicePointManager.SecurityProtocol.ToString());
AddinModule. Before. ServicePointManager.SecurityProtocol: SystemDefault
AddinModule.After. ServicePointManager.SecurityProtocol: Ssl3, Tls, Tls11, Tls12, Tls13
ClickTwiceModule. Before. ServicePointManager.SecurityProtocol: Ssl3, Tls
ClickTwiceModule. After. ServicePointManager.SecurityProtocol: Ssl3, Tls, Tls11, Tls12, Tls13
AddinModule. Before. ServicePointManager.SecurityProtocol: Ssl3, Tls
AddinModule. After. ServicePointManager.SecurityProtocol: Ssl3, Tls, Tls11, Tls12, Tls13
As expected, the code is invoked, but the updater log still shows the error:
Add-in Express Updater Log File: 7/31/2021 10:17 AM
Updater version: 1.0.1
Command Line: C:ProgramDataxxx.addinD56A42970B3B430FA5F31744B87CD66B.0.1xxx.AddIn.updater.exe
Operating System: Microsoft Windows NT 6.2.9200.0
------------------------------------------------------------------------
10:17:56 Start
10:17:56 Downloader command line: /updaterPath="C:ProgramDataxxx.addinD56A42970B3B430FA5F31744B87CD66B.0.1xxx.AddIn.updater.exe" /updaterPID=4852 /sid="" /productDir="C:Program Files (x86)xxx" /silentMode="true" /pipeName="98d70dd1591f4b7596d840da3a46881b_1_0_1_UpdaterService" /appId="D56A42970B3B430FA5F31744B87CD66B" /updaterService="On"
10:17:56 Product registry key: SoftwareClickTwiceD56A42970B3B430FA5F31744B87CD66B
10:17:56 'Show Icon' is enabled.'
10:17:56 Loading custom actions: C:ProgramDataxxx.addinD56A42970B3B430FA5F31744B87CD66B.0.1ctionsSetupCustomUI.dll
10:17:56 Success.
10:17:56 Running the updater application...
10:18:06 The background thread started. The update mode: OnInterval
10:18:06 Thread check point 1: IsUpdatable = true
10:18:06 Thread check point 2: NextUpdateTime = 1/1/0001 12:00:00 AM
10:18:07 Thread check point 3: AutoUpdateEnabled = True, IsInstallingUpdate = 0, ConnectionsCount = 0
10:18:07 Thread check point 4: NextUpdateTime = 1/1/0001 12:00:00 AM
10:18:07 Set UI State: CheckingUpdates
10:18:07 Thread check point 5: RootUpdateUrl = https://xxx.yyy/addin/
10:18:07 Set UI State: CheckUpdates
10:18:07 Thread check point 10: NextUpdateTime = 7/31/2021 10:23:07 AM
10:18:07 Date and Time: 7/31/2021 10:18:07 AM
Machine Name: ADI-XPS-NEW
IP Address: fe80::b921:d294:105:a1be%12
Current User: NT AUTHORITYSYSTEM
Application Domain: xxx.AddIn.updater.exe
Assembly Codebase: file:///C:/ProgramData/xxx.addin/D56A42970B3B430FA5F31744B87CD66B/1.0.1/xxx.AddIn.updater.exe
Assembly Full Name: xxx.addin.updater.exe, Version=1.0.0.0, Culture=neutral, PublicKeyToken=4416dd98f0861965
Assembly Version: 1.0.0.0
Exception Source: System
Exception Type: System.Net.WebException
Exception Message: The request was aborted: Could not create SSL/TLS secure channel.
---- Stack Trace ----
at System.Net.WebClient.DownloadFile(Uri address, String fileName)
at System.Net.WebClient.DownloadFile(String address, String fileName)
at AddinExpress.Projects.Common.Utilities.DownloadFile(String url, String destFile, IWebProxy proxy)
at AddinExpress.Projects.Common.Utilities.CheckForUpdates(Object module, String url, IWebProxy proxy, String appDir, CTVersionInfo& versionInfo, String currentVersion, String currentLanguage)
at AddinExpress.Deployment.Updater.ADXUpdaterModule.CheckForUpdates(CTVersionInfo& versionInfo)
at AddinExpress.Deployment.Updater.UpdaterEngine.updateWorker_DoWork(Object sender)
In
https://www.add-in-express.com/forum/read.php?FID=5&TID=15706
I mentioned before, which presents the same issue, you said
The updater is built using .NET 2.0 which doesn't support Tls11 and Tls12. We will think on how we would fix this. As to now, you should use a channel that supports Ssl3 or Tls only.
and also
I expect a fix for this issue will be available in 3-4 weeks. An update: A new build is expected in 2-3 weeks after the New Year.
. This was back in December 2019. So was this updater issue fixed? If yes, is there any patch that can be downloaded and applied?
After help received from the Add-in Express team, the working solution is to add the ServicePointManager.SecurityProtocol line both in
ClickTwiceModule1_OnInitialize
and in
ClickTwiceModule1_OnUpdaterInitialize
.
So if an https server is used for publishing, you need to add a ClickTwice module, add the below code and use the module in custom actions of the publishing options.
private void ClickTwiceModule1_OnInitialize(object sender, ADXClickTwiceInitializeEventArgs e)
ServicePointManager.SecurityProtocol =
SecurityProtocolType.Ssl3 | SecurityProtocolType.Tls
| (SecurityProtocolType)768 /*Tls 1.1*/
| (SecurityProtocolType)3072 /*Tls 1.2*/
| (SecurityProtocolType)12288 /*Tls 1.3*/;
private void ClickTwiceModule1_OnUpdaterInitialize(object sender, ADXClickTwiceUpdaterInitializeEventArgs e)
ServicePointManager.SecurityProtocol =
SecurityProtocolType.Ssl3 | SecurityProtocolType.Tls
| (SecurityProtocolType)768 /*Tls 1.1*/
| (SecurityProtocolType)3072 /*Tls 1.2*/
| (SecurityProtocolType)12288 /*Tls 1.3*/;
Add-in Express™
for Microsoft® Office and .net
Solid framework for deep customization of Microsoft Office. Use solution templates,
visual designers and components to develop version-neutral, secure and easy deployable extensions for all Office versions.
Supported Office extensions
COM add-ins, Outlook plug-ins, RTD servers, smart tags, Excel XLL and UDF
Requirements
Office versions: 2021 - 2000
IDE: VS 2022 - 2012; VB.NET, C#, C++/CLI
Overview
Take a tour
Customers say
This technology is now available for our custom development services only. Based on the Add-in Express for Office core, it is designed for building custom-tailored Office add-ins with far less coding than you usually have to do. Plus, it includes all Add-in Express features such as True RAD, visual designers, Outlook view and form regions, etc.
Extensions: VSTO-based application-level Office add-ins
Applications: Outlook, Excel, Word, PowerPoint, Visio, InfoPath
Office versions: 2003, 2007, 2010 (x86 and x64)
IDE: VSTO 2005 SE, 2008, 2010; VB.NET, C#
Overview Outlook-specific features
Add-in Express™
for Microsoft® Office and Delphi® VCL
Get the best platform for building version-neutral, fast and easy deployable plug-ins by using Add-in Express projects templates, visual designers, components and wizards in combination with a perfect Delphi compiler.
Supported Office extensions
COM add-ins, Outlook plug-ins, smart tags, Excel RTD and UDF
Requirements
Office versions: 2021 - 2000
IDE: Embarcadero Delphi XE2 - Delphi 11 Alexandria
Overview
Customers say
Add-in Express blogs
Add-in Express™
for Internet Explorer® and Microsoft® .net
Use this visual tool to create thread-safe, secure, isolated, deployable and context-sensitive Internet Explorer add-ons.
Use visual designers and components to customize the IE interface with your own buttons, menu items, context menus, side-bars etc.
Requirements
Internet Explorer versions: 6 - 11 (x86, x64)
IDE: VS 2010 - 2019; VB.NET, C#, C++/CLI
Overview
Customers say
Add-in Express blogs
Add-in Express™ Regions
for Microsoft® Outlook® and VSTO
Use this VSTO extension to develop advanced view and form regions for 17 different areas of the main Outlook Explorer window and all Outlook Inspector windows.
Supported extensions
Application-level Outlook add-ins
Requirements
Outlook versions: 2021 - 2003
IDE: Visual Studio 2022 - 2012 with VSTO installed
This is an extension for Visual Studio that allows developers to quickly create WiX-based setup projects in a familiar Visual Studio way.
The Designer for WiX Toolset lets you forget the plain Windows Installer XML and concentrate on your deployment logic. It integrates several editors with the Visual Studio IDE and provides a set of vdproj designers to configure the file system, registry, user interface, custom actions, launch conditions and more for your setup projects.
Requirements
Visual Studio versions: 2010, 2012, 2013, 2015, 2017, 2019
WiX versions: 3.6 and higher
Overview
This technology is now available for our custom development services only. This visual toolkit allows creating secure, managed, isolated, deployable and version-neutral plug-ins for Outlook Express and Windows Mail. It provides powerful solution templates, Outlook Express - specific components, visual designers and wizards for advanced customization of Outlook Express menus, toolbars, panes and regions.
Extensions: Outlook Express plug-ins
Versions: Outlook Express 6.x, Windows Mail 6.x
IDE: VS 2005, 2008; VB.NET, C#, C++/CLI
Overview Getting started
VDProj to WiX Converter
for Microsoft® Visual Studio®
This Visual Studio extension lets you convert any VDProj setup projects to WiX in a click.
All Visual Studio versions and all vdproj features are supported, including variables, msm and msi packages, custom actions, built-in dialogs, etc.
Requirements
Visual Studio versions: 2005, 2008, 2010, 2012, 2013, 2017, 2019
WiX versions: 3.6 and higher
Overview Supported features
Security Manager
for Microsoft® Outlook
Add just a few lines of code to bypass the Outlook Object Model guard and avoid security warnings in add-ins and applications that automate Microsoft Outlook.
Supported application types
Stand-alone apps, Outlook add-ins
Requirements
Outlook versions: 2021 - 2000
Languages: VB.NET, C#, Delphi XE2 - Delphi 11 Alexandria, C++ (MFC/ATL/CLI), VBA, etc.
3 editions in 1 package: .NET, VCL and ActiveX
Overview
Customers say
Add-in Express blogs
The innovative technology for customizing Outlook views and forms. It is included in all Add-in Express for Office products and can be used to extend Outlook views, e-mail, task and appointment windows, To-Do bar, Reading and Navigation panes with your own custom sub-panes.
Extensions: application-level Outlook add-ins
Outlook versions: 2000, 2002, 2003, 2007, 2010 (x86 and x64)
.NET Edition: VS 2005, 2008, 2010; VB.NET, C#, C++/CLI
.NET Framework: 2.0 and higher
VCL Edition: Delphi 5 - XE
Outlook regions in .NET Outlook regions in Delphi
Microsoft and the Office logo are trademarks or registered trademarks of Microsoft Corporation in
the United States and/or other countries. All other trademarks are property of their respective owners.
Use of this site constitutes acceptance of our
Privacy Policy and Cookies Policy.