Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Anonymous
Not applicable

On Premises Data Gateway (Personal Mode) Offline

Hi, I'm currently having issues with our Gateway showing as offline and i'm having trouble.
The following error is being shown when trying to open it:

MaxIsherwood_0-1662974568878.png

When trying to sign we get the following error:

 

Error generating an asymmetric key.

Exception message: Key not valid for use in specified state.

 

Key not valid for use in specified state.

 

Server stack trace: 

   at System.ServiceModel.Channels.ServiceChannel.ThrowIfFaultUnderstood(Message reply, MessageFault fault, String action, MessageVersion version, FaultConverter faultConverter)

   at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc)

   at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)

   at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)

   at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

 

Exception rethrown at [0]: 

   at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)

   at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)

   at Microsoft.PowerBI.DataMovement.Pipeline.ConfigurationContracts.IGatewayConfigurationService.GenerateAsymmetricKey()

   at Microsoft.PowerBI.DataMovement.Pipeline.GatewayClient.GatewayConfigurationClient.GenerateAsymmetricKey()An ExceptionDetail, likely created by IncludeExceptionDetailInFaults=true, whose value is:

System.Security.Cryptography.CryptographicException: Key not valid for use in specified state.

 

   at System.Security.Cryptography.Utils.CreateProvHandle(CspParameters parameters, Boolean randomKeyContainer)

   at System.Security.Cryptography.Utils.GetKeyPairHelper(CspAlgorithmType keyType, CspParameters parameters, Boolean randomKeyContainer, Int32 dwKeySize, SafeProvHandle& safeProvHandle, SafeKeyHandle& safeKeyHandle)

   at System.Security.Cryptography.RSACryptoServiceProvider.GetKeyPair()

   at System.Security.Cryptography.RSACryptoServiceProvider..ctor(Int32 dwKeySize, CspParameters parameters, Boolean useDefaultKeySize)

   at Microsoft.PowerBI.DataMovement.Pipeline.GatewayServiceHost.AsymmetricKeyGenerator.ProduceAsymmetricKey(String containerName, Boolean cleanUpOldKeys, Int32 rsaKeySize)

   at Microsoft.PowerBI.DataMovement.Pipeline.GatewayPipelineTelemetry.PipelineTelemetryService.ExecuteInActivity[T](PipelineActivityType pipelineActivityType, Func`1 action)

   at SyncInvokeGenerateAsymmetricKey(Object , Object[] , Object[] )

   at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)

   at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc& rpc)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc& rpc)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage11(MessageRpc& rpc)

   at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)

 

 

I've tried reinstalling and restarting, which tells us the key is invalid but other than that we have no idea what could be causing this issue.

 

Any ideas as to what the issue could be, or is there some update which has gone through this weekend I'm unaware of?

 

Thanks.

1 ACCEPTED SOLUTION
Levi_Huck
Regular Visitor

Hi,

 

I know the solution to this.

 

For "Key not valid for use in specified state" errors try moving the folder RSA from

C:\Users\<User>\AppData\Roaming\Microsoft\Crypto\RSA to:

 

C:\RSA (just in case there should be a need to restore it) then try installing your personal gateway again, where the folder will automatically be regenerated. This folder appears to act as a cache.

View solution in original post

2 REPLIES 2
Levi_Huck
Regular Visitor

Hi,

 

I know the solution to this.

 

For "Key not valid for use in specified state" errors try moving the folder RSA from

C:\Users\<User>\AppData\Roaming\Microsoft\Crypto\RSA to:

 

C:\RSA (just in case there should be a need to restore it) then try installing your personal gateway again, where the folder will automatically be regenerated. This folder appears to act as a cache.

Anonymous
Not applicable

Worked like a charm, thank you!

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Fabric Monthly Update - May 2024

Check out the May 2024 Fabric update to learn about new features.

LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

Top Kudoed Authors