Skip to main content


 

Symptoms


After editing the following section of K2HostServer.exe.config:












URL

http://K2Server.domain.com:82/SmartObjectServices/endpoints/endpoints.xml

returns:

HTTP Error 401.2 - Unauthorized
You are not authorized to view this page due to invalid authentication headers

How to configure SmartObjectServices Endpoints?
 

Diagnoses


First of all based on the configuration listed above correct URL supposed to be:

http://K2Server.domain.com:8888/SmartObjectServices/endpoints/endpoints.xml

As we have parameter port="8888" specified there. Next it is also necessary to configure bindingConfiguration sections for wsHttpBinding+Windows and webHttpBinding+Windows and specifiy security mode as "None":











It is also necessary to make sure that URL reservation for http://K2server.domain.com:8888 is exist and if not create it:

Issue this command to check if URL reservation already exist:

netsh http show urlacl url=http://K2server.domain.com:8888/

If this command returns no results, create URL reservation by issuing this command:

netsh http add urlacl url=http://K2server.domain.com:8888/ User=Everyone

Issue first command once again to verify that reservation has been created:

netsh http show urlacl url=http://K2server.domain.com:8888/

* In all commands mentioned above make sure to include trailing slash at the very end of your URL.

NOTE: Preferred configuration from the security prospective for SmartObjectServices Endpoints is HTTPS, and when you use HTTP settings above is just minimum working configuration which you can adjust more configured security mode based on your needs.

Security mode settings are defined in Microsoft documentation - "How to: Use basicHttpBinding with Windows Authentication and TransportCredentialOnly in WCF from Windows Forms" and you can refer to it for further details:

https://msdn.microsoft.com/en-us/library/ff648505.aspx

See also official K2 documentation on this topic:
https://help.k2.com/onlinehelp/k2blackpearl/devref/4.6.9/default.htm#configuration2.html
 

Resolution

See information above to configure SmartObjectServices Endpoints.




 
Be the first to reply!

Reply