{"id":489655,"date":"2026-08-04T08:21:40","date_gmt":"2026-08-04T08:21:40","guid":{"rendered":"https:\/\/savepearlharbor.com\/?p=489655"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=489655","title":{"rendered":"\u0414\u043e\u0432\u0435\u0440\u0438\u0435 \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u043c\u0443 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u0443 \u0441 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u043d\u044b\u043c \u0441\u043f\u0438\u0441\u043a\u043e\u043c \u0445\u043e\u0441\u0442\u043e\u0432 \u0432 Chrome"},"content":{"rendered":"<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p>\u0412 \u0421hrome (\u0438 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0432\u0441\u0435\u0445 chrome-\u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0445 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430\u0445) \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0434\u0430\u0432\u043d\u043e \u0435\u0441\u0442\u044c \u043f\u043e\u043b\u0438\u0442\u0438\u043a\u0430 CACertificatesWithConstraints, \u043a\u043e\u0442\u043e\u0440\u0430\u044f, \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0434\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u043c\u0443 \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u043c\u0443 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u0443 \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f \u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u0441\u043f\u0438\u0441\u043a\u0430 \u0434\u043e\u043c\u0435\u043d\u043e\u0432. \u0421\u0430\u043c \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442 \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0440\u0430\u0437\u043c\u0435\u0449\u0430\u0442\u044c \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u043c \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u043c \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435. \u042d\u0442\u043e \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e \u0434\u043b\u044f \u0442\u0435\u043a\u0443\u0449\u0438\u0445 \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u0441 \u043e\u0442\u0437\u044b\u0432\u0430\u043c\u0438 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0432 \u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u043c \u0431\u0430\u043d\u043a\u043e\u0432 \u043d\u0430 \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0439 \u041c\u0438\u043d\u0446\u0438\u0444\u0440\u044b <a href=\"https:\/\/habr.com\/en\/news\/1066284\/\" rel=\"noopener noreferrer nofollow\">https:\/\/habr.com\/en\/news\/1066284\/<\/a><\/p>\n<p>\u041d\u0438\u0436\u0435 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 powershell \u0441\u043a\u0440\u0438\u043f\u0442 \u0434\u043b\u044f \u0432\u0438\u043d\u0434\u044b \u0438 ungoogled-chromium, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c:<\/p>\n<p>1) CertPath &#8212; \u043f\u043e\u043b\u043d\u044b\u0439 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u0443 \u041c\u0438\u043d\u0446\u0438\u0444\u0440\u044b (\u043d\u0443\u0436\u0435\u043d \u0444\u0430\u0439\u043b russian_trusted_root_ca.cer \u0438\u0437 \u0430\u0440\u0445\u0438\u0432\u0430 <a href=\"https:\/\/gu-st.ru\/content\/lending\/android_russian_trusted_root_ca.zip\" rel=\"noopener noreferrer nofollow\">https:\/\/gu-st.ru\/content\/lending\/android_russian_trusted_root_ca.zip<\/a>) <\/p>\n<p>2) PermittedDnsNames &#8212; \u043c\u0430\u0441\u0441\u0438\u0432 \u0434\u043e\u043c\u0435\u043d\u043e\u0432, \u0434\u043b\u044f \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442 \u041c\u0438\u043d\u0446\u0438\u0444\u0440\u044b \u0440\u0430\u0437\u0440\u0435\u0448\u0451\u043d \u043a\u0430\u043a \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0439. \u0423\u0434\u043e\u0431\u043d\u043e, \u0447\u0442\u043e \u043f\u043e\u043b\u0438\u0442\u0438\u043a\u0430 \u0432\u043b\u0438\u044f\u0435\u0442 \u0441\u0440\u0430\u0437\u0443 \u0438 \u043d\u0430 \u0432\u0441\u0435 \u043f\u043e\u0434\u0434\u043e\u043c\u0435\u043d\u044b \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0433\u043e \u0434\u043e\u043c\u0435\u043d\u0430.<\/p>\n<p>3) PolicyKey &#8212; \u043f\u0443\u0442\u044c \u043a \u0432\u0435\u0442\u043a\u0435 \u043f\u043e\u043b\u0438\u0442\u0438\u043a. \u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 &#8212; \u043f\u0443\u0442\u044c \u0434\u043b\u044f chromium, \u0434\u043b\u044f chrome \u043e\u043d, \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u043e,  HKLM:\\SOFTWARE\\Policies\\Google\\Chrome\\CACertificatesWithConstraints<\/p>\n<pre><code class=\"powershell\">#requires -RunAsAdministrator$CertPath = '.\\russian_trusted_root_ca.cer'$PermittedDnsNames = @('alfabank.ru', 'vtb.ru')$PolicyKey = 'HKLM:\\SOFTWARE\\Policies\\Chromium\\CACertificatesWithConstraints'# --- 1. Load cert and emit single-line base64 (handles both PEM and DER input) ---$cert = [System.Security.Cryptography.X509Certificates.X509Certificate2]::new($CertPath)$b64  = [Convert]::ToBase64String($cert.RawData)Write-Host \"Subject : $($cert.Subject)\"Write-Host \"Issuer  : $($cert.Issuer)\"Write-Host \"Expires : $($cert.NotAfter)\"if ($cert.Subject -ne $cert.Issuer) {    Write-Warning \"Subject != Issuer - this is not a self-signed root. Confirm it's the intended trust anchor.\"}# --- 2. Build the policy entry JSON ---$obj = [ordered]@{    certificate = $b64    constraints = [ordered]@{        permitted_dns_names = @($PermittedDnsNames)    }}$entry = $obj | ConvertTo-Json -Compress -Depth 5# Guard against PowerShell collapsing a single-element array into a scalarif ($PermittedDnsNames.Count -eq 1 -and $entry -notmatch '\"permitted_dns_names\":\\[') {    $entry = $entry -replace '\"permitted_dns_names\":(\"[^\"]*\")', '\"permitted_dns_names\":[$1]'}# --- 3. Write it ---New-Item -Path $PolicyKey -Force | Out-NullGet-Item $PolicyKey | Select-Object -ExpandProperty Property |    ForEach-Object { Remove-ItemProperty -Path $PolicyKey -Name $_ }   # clear stale entriesNew-ItemProperty -Path $PolicyKey -Name '1' -Value $entry -PropertyType String -Force | Out-NullWrite-Host \"`nWrote to $PolicyKey value '1':\"Write-Host $entry<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><img style=\"width:87px;height:14px;object-fit:cover;object-position:left;\"\/><\/a><\/div><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u043f\u0440\u043e\u0433\u043e\u043d\u0430 \u0441\u043a\u0440\u0438\u043f\u0442\u0430, \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c Reload policies \u0432 chrome:\/\/policy\/ \u0438 \u0443\u0431\u0435\u0434\u0438\u0442\u044c\u0441\u044f, \u0447\u0442\u043e \u043f\u043e\u043b\u0438\u0442\u0438\u043a\u0430 \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u0441\u043e \u0441\u0442\u0430\u0442\u0443\u0441\u043e\u043c OK.<\/p>\n<\/div>\n<p>\u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/articles\/1066372\/\">https:\/\/habr.com\/ru\/articles\/1066372\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0412 \u0421hrome (\u0438 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0432\u0441\u0435\u0445 chrome-\u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0445 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430\u0445) \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0434\u0430\u0432\u043d\u043e \u0435\u0441\u0442\u044c \u043f\u043e\u043b\u0438\u0442\u0438\u043a\u0430 CACertificatesWithConstraints, \u043a\u043e\u0442\u043e\u0440\u0430\u044f, \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0434\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u043c\u0443 \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u043c\u0443 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u0443 \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f \u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u0441\u043f\u0438\u0441\u043a\u0430 \u0434\u043e\u043c\u0435\u043d\u043e\u0432. \u0421\u0430\u043c \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442 \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0440\u0430\u0437\u043c\u0435\u0449\u0430\u0442\u044c \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u043c \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u043c \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435. \u042d\u0442\u043e \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e \u0434\u043b\u044f \u0442\u0435\u043a\u0443\u0449\u0438\u0445 \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u0441 \u043e\u0442\u0437\u044b\u0432\u0430\u043c\u0438 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0432 \u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u043c \u0431\u0430\u043d\u043a\u043e\u0432 \u043d\u0430 \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0439 \u041c\u0438\u043d\u0446\u0438\u0444\u0440\u044b https:\/\/habr.com\/en\/news\/1066284\/\u041d\u0438\u0436\u0435 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 powershell \u0441\u043a\u0440\u0438\u043f\u0442 \u0434\u043b\u044f \u0432\u0438\u043d\u0434\u044b \u0438 ungoogled-chromium, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c:1) CertPath &#8212; \u043f\u043e\u043b\u043d\u044b\u0439 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u0443 \u041c\u0438\u043d\u0446\u0438\u0444\u0440\u044b (\u043d\u0443\u0436\u0435\u043d \u0444\u0430\u0439\u043b russian_trusted_root_ca.cer \u0438\u0437 \u0430\u0440\u0445\u0438\u0432\u0430 https:\/\/gu-st.ru\/content\/lending\/android_russian_trusted_root_ca.zip) 2) PermittedDnsNames &#8212; \u043c\u0430\u0441\u0441\u0438\u0432 \u0434\u043e\u043c\u0435\u043d\u043e\u0432, \u0434\u043b\u044f \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442 \u041c\u0438\u043d\u0446\u0438\u0444\u0440\u044b \u0440\u0430\u0437\u0440\u0435\u0448\u0451\u043d \u043a\u0430\u043a \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0439. \u0423\u0434\u043e\u0431\u043d\u043e, \u0447\u0442\u043e \u043f\u043e\u043b\u0438\u0442\u0438\u043a\u0430 \u0432\u043b\u0438\u044f\u0435\u0442 \u0441\u0440\u0430\u0437\u0443 \u0438 \u043d\u0430 \u0432\u0441\u0435 \u043f\u043e\u0434\u0434\u043e\u043c\u0435\u043d\u044b \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0433\u043e \u0434\u043e\u043c\u0435\u043d\u0430.3) PolicyKey &#8212; \u043f\u0443\u0442\u044c \u043a \u0432\u0435\u0442\u043a\u0435 \u043f\u043e\u043b\u0438\u0442\u0438\u043a. \u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 &#8212; \u043f\u0443\u0442\u044c \u0434\u043b\u044f chromium, \u0434\u043b\u044f chrome \u043e\u043d, \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u043e,  HKLM:\\SOFTWARE\\Policies\\Google\\Chrome\\CACertificatesWithConstraints#requires -RunAsAdministrator$CertPath = &#8216;.\\russian_trusted_root_ca.cer&#8217;$PermittedDnsNames = @(&#8216;alfabank.ru&#8217;, &#8216;vtb.ru&#8217;)$PolicyKey = &#8216;HKLM:\\SOFTWARE\\Policies\\Chromium\\CACertificatesWithConstraints&#8217;# &#8212; 1. Load cert and emit single-line base64 (handles both PEM and DER input) &#8212;$cert = [System.Security.Cryptography.X509Certificates.X509Certificate2]::new($CertPath)$b64  = [Convert]::ToBase64String($cert.RawData)Write-Host &#171;Subject : $($cert.Subject)&#187;Write-Host &#171;Issuer  : $($cert.Issuer)&#187;Write-Host &#171;Expires : $($cert.NotAfter)&#187;if ($cert.Subject -ne $cert.Issuer) {    Write-Warning &#171;Subject != Issuer &#8212; this is not a self-signed root. Confirm it&#8217;s the intended trust anchor.&#187;}# &#8212; 2. Build the policy entry JSON &#8212;$obj = [ordered]@{    certificate = $b64    constraints = [ordered]@{        permitted_dns_names = @($PermittedDnsNames)    }}$entry = $obj | ConvertTo-Json -Compress -Depth 5# Guard against PowerShell collapsing a single-element array into a scalarif ($PermittedDnsNames.Count -eq 1 -and $entry -notmatch &#8216;&#187;permitted_dns_names&#187;:\\[&#8216;) {    $entry = $entry -replace &#8216;&#187;permitted_dns_names&#187;:(&#171;[^&#187;]*&#187;)&#8217;, &#8216;&#187;permitted_dns_names&#187;:[$1]&#8217;}# &#8212; 3. Write it &#8212;New-Item -Path $PolicyKey -Force | Out-NullGet-Item $PolicyKey | Select-Object -ExpandProperty Property |    ForEach-Object { Remove-ItemProperty -Path $PolicyKey -Name $_ }   # clear stale entriesNew-ItemProperty -Path $PolicyKey -Name &#8216;1&#8217; -Value $entry -PropertyType String -Force | Out-NullWrite-Host &#171;`nWrote to $PolicyKey value &#8216;1&#8217;:&#187;Write-Host $entry\u041f\u043e\u0441\u043b\u0435 \u043f\u0440\u043e\u0433\u043e\u043d\u0430 \u0441\u043a\u0440\u0438\u043f\u0442\u0430, \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c Reload policies \u0432 chrome:\/\/policy\/ \u0438 \u0443\u0431\u0435\u0434\u0438\u0442\u044c\u0441\u044f, \u0447\u0442\u043e \u043f\u043e\u043b\u0438\u0442\u0438\u043a\u0430 \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u0441\u043e \u0441\u0442\u0430\u0442\u0443\u0441\u043e\u043c OK.\u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 https:\/\/habr.com\/ru\/articles\/1066372\/<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-489655","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/489655","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=489655"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/489655\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=489655"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=489655"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=489655"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}