Comments (4)
@eggapauli -
What is the preferred way when we want to rotate SAS's regularly?
- If you mean "renewing" of the SAS token, today the SDKs will do that for you automatically at 1 hour intervals.
Should the device then have two connection strings (one with primary and one with secondary key) and just try both of them? Is something like this supported in the SDK or is it even a common scenario?
- Today this is not implemented out of the box in the SDK. However, this can be implemented on top of the SDK by using the SAS token as part of the connection string.
from azure-iot-sdk-csharp.
It's nice that the SDK automatically regenerates SAS Tokens.
But I think I used the wrong terminology, sorry. We want to rotate Shared Access Keys (the things that are part of the connection string). So if a shared access key is stolen we want to disable the key while keeping the device online (using the secondary key).
Is there some guidance or documentation if this is a good idea or if there are alternatives?
from azure-iot-sdk-csharp.
@eggapauli - The primary and secondary keys are provided to support rollover scenarios.
I've attached a sample on how to do that.
from azure-iot-sdk-csharp.
Nice, thanks. We thought of something like that, but we just weren't sure if it's a good idea because we couldn't find anything going in this direction. All the samples we found use a single connection string directly. This is now solved for me. Thanks for your support.
from azure-iot-sdk-csharp.
Related Issues (20)
- [Technical Question] How to use Device Registration Status Lookup API HOT 2
- Not able to restart the custom edge module while using the inbuilt "RestartModule" direct method of $edgeAgent from custom iot edge module. HOT 14
- How can parent child relationship be established between Iotdevices without utilizing azure Iotedge ?? HOT 2
- Json Format Exception to get payload from Direct Method Request and Twin Json Wrongly formatted
- [Bug Report] Cannot invoke direct methods with payload in IotEdge devices. HOT 8
- [Bug Report] [v2] [IoTSDK] ModuleClient.SendMessageToRoute() not firing IncomingMessageCallback when routing M2M
- IoT Edge not connecting to IOT Hub HOT 2
- Route data directly from opc publisher to rabbit mq is possible? HOT 2
- [Technical Question] [v2] How to set Properties on TelemetryMessage HOT 1
- [Bug Report] Upgrade dependency on Microsoft.Rest.ClientRuntime to Azure.Core HOT 2
- Microsoft.Azure.Devices.Client v1.42.0 has indirect security vulnerabilies HOT 3
- AOT-compatible Microsoft.Azure.Devices.Client HOT 1
- SDK version :2.0.0-preview007 CreateAsync() Json Error
- [Bug Report] WebSockets not working on Web Assembly HOT 1
- Latest device client does not connect over MQTT HOT 9
- Errors while running e2e tests with .NET 8.0 HOT 1
- How to use tpm private key for TLS with IoT Hub SDK (Not TPM Attestation) - for DeviceAuthenticationWithX509Certificate HOT 4
- [Bug Report] AMQP DeviceClient is slow to respond to device being disabled
- Desired Properties callback not triggering after a reconnect HOT 5
- [feature request] Move to System.Text.Json to support AOT HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from azure-iot-sdk-csharp.