Add keys to register in azure

WebTGI Tecnologia 5 Reputation points
2024-05-06T14:10:22.4+00:00

In order to access a extern API, i need to create a key and some values on this register path:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Messaging,

otherwise all my resquests to this API receive no content in a response, with a status code = 0.

I have done some local tests and only got to this solution on a developers forum of the company that owns the API. The solution worked fine locally as soon as I added this key with this key value: "MessageLimitServerClientAuth" /t REG_DWORD /d 0x00065536.

Is it possible to add this keys on azure? Tried commands in CMD that works locally, but i receive a error message in azure's CMD. Example:

reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Messaging /v "MessageLimitServerClientAuth" /t REG_DWORD /d 0x00065536

Azure App Configuration
Azure App Configuration
An Azure service that provides hosted, universal storage for Azure app configurations.
211 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Ryan Hill 26,856 Reputation points Microsoft Employee
    2024-05-06T22:02:06.37+00:00

    Hi @WebTGI Tecnologia,

    Due to the restrictions of the app service sandbox, you can't write to any registry keys of any sort. It would be helpful to understand more about the use case of needing to add reg key for accessing an external API.

    The best option is to leverage App Configuration and create a key and value where the key is MessageLimitServerClientAuth and the value to your hexadecimal number. If you're not familiar with using App Configuration, see the following quickstart; https://learn.microsoft.com/en-us/azure/azure-app-configuration/quickstart-dotnet-core-app?tabs=linux, to get started.

    If the need of a registry key is coming from a requirement of a 3rd party library or software, then your only option is to use an Azure Virtual Machine.