DEV-1565 поддержка Global Catalog#147
Conversation
| /// Нужен при поиске через Global Catalog, где sAMAccountName формально уникален | ||
| /// только в рамках домена (не леса). | ||
| /// </summary> | ||
| IReadOnlyList<ILdapProfile> ExecuteMany(FindUserDto request); |
There was a problem hiding this comment.
Не надо так
Пиши тонкие порты
Выделим отдельный интерфейс
| /// Нужен, чтобы явно указанный пользователем домен в DOMAIN\user не терялся при поиске | ||
| /// через Global Catalog. Возвращает null, если сопоставление не найдено. | ||
| /// </summary> | ||
| string? ResolveDomainDnsNameByNetBiosName( |
There was a problem hiding this comment.
не имеет отношение к интерфейсу
Скорее к UserIdentity
| return null; | ||
| } | ||
|
|
||
| var globalCatalogConnectionString = new LdapConnectionString(context.LdapConfiguration.ConnectionString); |
There was a problem hiding this comment.
LdapConnectionString
Инфра просачивается в application
| List<LdapAttributeName> attributes, | ||
| RadiusPipelineContext context) | ||
| { | ||
| var stopwatch = Stopwatch.StartNew(); |
There was a problem hiding this comment.
Подозреваю что это нужно в инфре
| ArgumentNullException.ThrowIfNull(globalCatalogConnectionString); | ||
| ArgumentException.ThrowIfNullOrWhiteSpace(domainDnsName); | ||
|
|
||
| var isSsl = globalCatalogConnectionString.Port == GlobalCatalogSslPort |
There was a problem hiding this comment.
кажется это функционал для ldap.core
There was a problem hiding this comment.
Да и почти все остальное
| /// Извлекает DNS-имя домена (например, "child.test.group") из DN пользователя, | ||
| /// найденного через GC (например, "CN=User1,OU=Users,DC=child,DC=test,DC=group"). | ||
| /// </summary> | ||
| public static string ExtractDomainDnsName(this DistinguishedName dn) |
There was a problem hiding this comment.
Кажется что метод не на своем месте
| { | ||
| ArgumentNullException.ThrowIfNull(dn); | ||
|
|
||
| var parts = dn.StringRepresentation |
There was a problem hiding this comment.
лучше dn.Components
| userIdentity.Identity, | ||
| searchBase); | ||
|
|
||
| if (context.LdapConfiguration!.IsGlobalCatalog()) |
There was a problem hiding this comment.
Наверно всё таки этим должна инфра заниматься
application должно быть без разницы GC или Domain
What's new: