PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WINDEV 2024 → Installation of https webservice
Installation of https webservice
Débuté par Lee Shroder, 22 mai 2020 18:22 - 11 réponses
Posté le 22 mai 2020 - 18:22
Hi everyone,

Got another challenge for you wonderful windev guru's :D

We have a client who has a SQL Server solution that we are developing a Windev 24 & Windev Mobile 24 solution to integrate with using the Reserved Server and using SQLConnect and SQLConnectWS commands with no issues so far with the exception of storing images into this database.

As a workaround we have written a webservice that we can send compressed buffer data into and it in turn writes to the SQL server and this works perfectly well.

However the clients IT prohibits us from setting up the windev webservice on standard http and therefore we must use https on a specific port and therefore we are being instructed to use https on this specfic port.

The problem we are facing is we cannot figure out how to specify https on a specific port on webservice installer or on the webdev server adminstrator.

We are using the 10 connection webserver. From within Webdev Administrator, under Advanced tab and clicking diagnostics you can specify HTTPS conneciton but not the port:-





Also on the installation screen of the webservice it specifically states http with no option for https or the port needed to be used.





Can anyone please advise me how we can setup a webservice to use https on a specific port?

Thank you all for your time and assistance
Membre enregistré
50 messages
Popularité : +7 (9 votes)
Posté le 24 mai 2020 - 06:02
the default/standard port for HTTPS is 443 and it has nothing to do with windev.... remember that WAS is nothing else than a type of web engine that runs and depends on IIS. IIS is the one you nee to configure and where you need to install the digital certificates you need.
Membre enregistré
7 messages
Posté le 24 mai 2020 - 13:41
Hi WINDEVCOL, thank you for your response. In this instance ISS is configured and the certificate is installed but the port is not using the standard https port of 443 but port no 446.
The question is how do we setup a windev webservice to use https on a specific port?
Membre enregistré
50 messages
Popularité : +7 (9 votes)
Posté le 24 mai 2020 - 19:45
first of all, you should not change the standard HTTPS port unless your solution is only going to be run locally on an intranet. because if you change that port thousands of people will not be able to use or see your system due to port blocks on corporate firewalls. so beginning with that ... if that is a public site that is a terrible idea. and like i told you before the WAS is just an add-on on top of IIS. you need to configure your site in IIS properly the port configuration has nothing to do with Windev it has only to do with your IIS.
Membre enregistré
7 messages
Posté le 25 mai 2020 - 19:15
Hi WINDEVCOL, the configuration of IIS in this instance is being handled by my clients trusted IT company who have developed their existing solution to its current status. We have been requested to build a solution on top of this existing infrastructure built around a HTTPS site on port 446. We have no influence or choice in this matter, we are simply being instructed to install our Windev developed webservice on https configured for port 446.
We were able to do this for the WDRServer as the installation with no issues and it is working to the requirement of my clients IT company. We cant figure out how to make a windev webservice conform to the same settings.
Membre enregistré
50 messages
Popularité : +7 (9 votes)
Posté le 26 mai 2020 - 03:10
ok Lee, let me put it this way to see if you understand.... 1) again it does not matter if you run in port 443 or 666 the configuration MUST BE DONE IN IIS 2) if you dont have access to the server because they dont let you touch it then you have two (2) options 1) get the deployment files (JUST THE FILES DO NOT BUILD A SETUP OR INSTALLATION MEDIA WITH WEBDEV), Then make a document step by step in how they manually install that in the webserver IIS and how they configure the virtual directory, configuration of application pool and application pool user, bindings etc etc. you as a web developer MUST know all these things. These should be your bread and butter if you are a web developer. And after you finish that how to step by step document then deliver the files and the document to that company and you are done. 2) if they are lazy and you have already spoiled them with the installer, and they are not willing to install the site using a manual approach (by the way the manual approach SHOULD BE always the approach used on a serious production system because then you know how things are configured), if they are not willing to install like the should the solution manually and configure things properly, then you are only left with 1 option, using a tool like Installshield or installaware to use the manual files and then build an installer you can provide the customer. because only with a REAL INSTALLER TOOL, you will be able to customize every step of the way and automatize a process using CUSTOM PORT and CUSTOM BINDINGS and CUSTOM APPLICATION SETTINGS (BECAUSE WEBDEV USES EVERYTHING IN INTERNATIONAL STANDARD MODE). And again i remind you what you are asking to do IT MUST BE DONE IN IIS NOT IN WINDE/WEBDEV.
Membre enregistré
50 messages
Popularité : +7 (9 votes)
Posté le 26 mai 2020 - 07:12
And by the way @LEE your last answers raises more questions than answers, if you did not build the system, and this company did. did they build the system you have to enhance or build the webservice for in webdev or windev ? you are talking in your original post about the WAS 10 connection server, i hope you are not thinking about using that server on a client production environment, because even though is completely legal to use that version as you see fit, that version will never work on a production environment specially using web-services where depending on the threads opened those 10 session will be reached in no time. so if you are thinking in putting that on production they need already to have a FULL LICENSED WAS on that server. Now... if the original development of the solution was not developed entirely in WEBDEV using WAS. why would you ever build a webservice using windev ? that is just bringing too much overhead for nothing to a system that did not had any overhead to begin with.... anyways i just want it to help and have been around for many years as a system architect, and i cannot just stop been critical when i dont see a logic o good reason for a certain architecture. good luck with your project and wish for you the best.
Membre enregistré
7 messages
Posté le 26 mai 2020 - 11:07
Hi WINDEVCOL, the complete picture is as follows. We are developing a solution that updates a SQL database from both a windows and Android application using Windev and Windev Mobile and the Windev Reserved Server configured for accessing external databases. The client already has a CRM system configured for HTTPS on port 446 that we cannot use, therefore we were provided with a new server and IIS configured with a certificate on port 446. The installation of the Reserved Server was simple and works perfectly for 99.9% of the application and has been configured easily for HTTPS on port 446. This is working and the installation allowed us to specifiy HTTPS and enter the port as part of the installer address. IIS is configured correctly and the Reserved Server is working. The problem arose when we needed to add pictures to the SQL database and we could not get the Reserved Server functions to pass an image using {WBBinaryMemo} (please see my other posting). This made us have to think outside the box in terms of how to get an image into the SQL server from a mobile device. Therefore we created a simple webservice for the handling of adding a picture to the SQL instance, the amount of users is less than 10 and will be very infrequent so there is no need for anything other than the 10 connection server.

The problem we are facing is we cannot seem to get the windev webservice configured correctly to support HTTPS on port 446 but the Reserved Server for accessing external databases is working fine.

We go through all of the settings on the webserver for the webservice and we are able to browse the webservice on the https address with the correct port, but the response from the webservice seems to always resolve back to http.

So lets say the address for the webservice is as follows:-

HTTPS://10.11.12.13/WebServiceURL

We open this url in a web browser and we can then see the procedures available in the browser, you then select a function and run it and the resulting URL returned by the webservice is always http

Example Result
HTTP://10.11.12.13/WebServiceURL/Result

So the situation is the Windev Reserved Server is working perfectly well on HTTPS port 446 (IIS is configured with a cerrtificate and working for the Reserved Server), but the 10 cnx WebDev server with a simple webservice just doesn't want to work correctly.

Do you have any ideas as to what we may not be doing on the config on the 10 cnx Server or the Webservice as the Reserved Server is working fine?
Membre enregistré
50 messages
Popularité : +7 (9 votes)
Posté le 26 mai 2020 - 17:36
Yes my friend, i already told you.... the problem is not windev.... the problem is IIS. can I 100% configure a server to work well on 446 with a windev webservice or any other webservice made on ANY programming language ?.... yes i could 5 minutes.... but like i said ... you as a developer must know how to configure properly an IIS virtual directory and everything in it. WAS is nothing more than a kind of translation engine that lives on TOP OF IIS.
You need to get a guy that is either a full web developer with IIS experience or an infrastructure guy that has knowledge about IIS. and when i say that IIS is NOT configured properly i am talking about the virtual directory where you have the webservice not been configured properly and if i needed to bet on it, my money is on the bindings that are not properly done. because that will result 100% in the behavior you describe. and again i am 1000% sure that you have a configuration problem on the virtual directory and website in your IIS. i have seen these configuration errors 10000 times. and they come from IIS system administrators or developers with no real experience on IIS.
Membre enregistré
50 messages
Popularité : +7 (9 votes)
Posté le 26 mai 2020 - 17:42
by the way for the images if you are using SOAP you should use MTOM instead of the buffer
Membre enregistré
50 messages
Popularité : +7 (9 votes)
Posté le 26 mai 2020 - 17:46
your problem is either on the bindings of the web directory and application settings or the security bindings of the webservice is one of the 2 places you have the configuration error
Membre enregistré
7 messages
Posté le 28 mai 2020 - 20:40
hi WINDEVCOL,, thank you for the direction, I will get the clients IT support company to look into this and let you know how we get on and I am going to look into using MTOM for the sending the images.

:thank you: