private const string ConfigVersioningConstant = "configversion";
public static void Main()
"1d328fad-bc67-4a63-aaf6-0fddffc2b63f",
"ba781147-631d-4351-8dd8-1a8c04989ce4",
"4b1085db-a579-4037-a7ba-579d39f2f3d6",
"180fb7a8-00d7-4368-ae08-cd636443baf0",
"e07792d8-8dc9-4dcb-aef1-29c3a0b51871",
"42d00c7b-47f5-4680-bece-fe8ba8f5c973",
"48d1d532-7aeb-4b05-b0d5-e781b55ce227",
"3837099b-f928-44ce-b3e5-b354e4257a73",
"9651aaf9-23b8-485a-ba24-89e29ce8a67f",
"1d2d2621-a570-4beb-9331-2beff39ad821",
"369f8b8c-7299-42fb-bf92-025dcd3bfeff"
foreach (var agentId in agentIds) {
var valueMetadataId = GuidGenerator.Deterministic(agentId, ConfigVersioningConstant);
Console.WriteLine($"AgentId: {agentId}, ValueMetadataId: {valueMetadataId}");
public static class GuidGenerator
public static Guid Deterministic(params string[] identifiers)
string sourceString = string.Concat(identifiers);
byte[] stringbytes = Encoding.UTF8.GetBytes(sourceString);
byte[] hashedBytes = new System.Security.Cryptography
.SHA1CryptoServiceProvider()
.ComputeHash(stringbytes);
Array.Resize(ref hashedBytes, 16);
return new Guid(hashedBytes);