diff --git a/.all-contributorsrc b/.all-contributorsrc index 61799d103ae..e92f45f6f69 100644 --- a/.all-contributorsrc +++ b/.all-contributorsrc @@ -1805,10 +1805,10 @@ ] }, { - "login": "DAud-IcI", - "name": "El-Saig Dávid", + "login": "sarahelsaig", + "name": "Sára El-Saig", "avatar_url": "https://avatars1.githubusercontent.com/u/4007293?v=4", - "profile": "https://github.com/DAud-IcI", + "profile": "https://github.com/sarahelsaig", "contributions": [ "code" ] @@ -2825,6 +2825,15 @@ "contributions": [ "code" ] + }, + { + "login": "w-ko", + "name": "Holerö", + "avatar_url": "https://avatars.githubusercontent.com/u/126988022?v=4", + "profile": "https://github.com/w-ko", + "contributions": [ + "code" + ] } ], "skipCi": true, diff --git a/.github/workflows/contributor_map.yml b/.github/workflows/contributor_map.yml index 2efe95f1e8b..88fa1ec0736 100644 --- a/.github/workflows/contributor_map.yml +++ b/.github/workflows/contributor_map.yml @@ -1,10 +1,10 @@ name: Contributor Map on: + # Running this automatically would require jumping through a lot of hoops because tunaitis/contributor-map commits to + # the branch where the workflow was triggered, i.e. `main` for the schedule trigger. So, better to occasionally run + # it manually in a PR. workflow_dispatch: - schedule: - # At 3:00 AM UTC every Monday. - - cron: "0 3 * * 1" jobs: update-contributor-map: diff --git a/OrchardCore.sln b/OrchardCore.sln index a390bc69109..f8cc4092156 100644 --- a/OrchardCore.sln +++ b/OrchardCore.sln @@ -511,9 +511,13 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OrchardCore.Search.AzureAI" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OrchardCore.Search.AzureAI.Core", "src\OrchardCore\OrchardCore.Search.AzureAI.Core\OrchardCore.Search.AzureAI.Core.csproj", "{E9428DE8-5D81-4359-BF84-31435041FF1A}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "OrchardCore.Media.Indexing.Pdf", "src\OrchardCore.Modules\OrchardCore.Media.Indexing.Pdf\OrchardCore.Media.Indexing.Pdf.csproj", "{95187E6A-5B74-4475-8FEB-758ACD012DCC}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OrchardCore.Media.Indexing.Pdf", "src\OrchardCore.Modules\OrchardCore.Media.Indexing.Pdf\OrchardCore.Media.Indexing.Pdf.csproj", "{95187E6A-5B74-4475-8FEB-758ACD012DCC}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "OrchardCore.Media.Indexing.OpenXML", "src\OrchardCore.Modules\OrchardCore.Media.Indexing.OpenXML\OrchardCore.Media.Indexing.OpenXML.csproj", "{47777735-7432-4CCA-A8C5-672E9EE65121}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OrchardCore.Media.Indexing.OpenXML", "src\OrchardCore.Modules\OrchardCore.Media.Indexing.OpenXML\OrchardCore.Media.Indexing.OpenXML.csproj", "{47777735-7432-4CCA-A8C5-672E9EE65121}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OrchardCore.Email.Azure", "src\OrchardCore.Modules\OrchardCore.Email.Azure\OrchardCore.Email.Azure.csproj", "{C35AB37B-5A09-4896-BEEE-B126B7E7018A}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OrchardCore.Email.Smtp", "src\OrchardCore.Modules\OrchardCore.Email.Smtp\OrchardCore.Email.Smtp.csproj", "{E8A1097D-A65A-4B17-A3A2-F50D79552732}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -1359,6 +1363,14 @@ Global {47777735-7432-4CCA-A8C5-672E9EE65121}.Debug|Any CPU.Build.0 = Debug|Any CPU {47777735-7432-4CCA-A8C5-672E9EE65121}.Release|Any CPU.ActiveCfg = Release|Any CPU {47777735-7432-4CCA-A8C5-672E9EE65121}.Release|Any CPU.Build.0 = Release|Any CPU + {C35AB37B-5A09-4896-BEEE-B126B7E7018A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {C35AB37B-5A09-4896-BEEE-B126B7E7018A}.Debug|Any CPU.Build.0 = Debug|Any CPU + {C35AB37B-5A09-4896-BEEE-B126B7E7018A}.Release|Any CPU.ActiveCfg = Release|Any CPU + {C35AB37B-5A09-4896-BEEE-B126B7E7018A}.Release|Any CPU.Build.0 = Release|Any CPU + {E8A1097D-A65A-4B17-A3A2-F50D79552732}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {E8A1097D-A65A-4B17-A3A2-F50D79552732}.Debug|Any CPU.Build.0 = Debug|Any CPU + {E8A1097D-A65A-4B17-A3A2-F50D79552732}.Release|Any CPU.ActiveCfg = Release|Any CPU + {E8A1097D-A65A-4B17-A3A2-F50D79552732}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -1594,6 +1606,8 @@ Global {E9428DE8-5D81-4359-BF84-31435041FF1A} = {F23AC6C2-DE44-4699-999D-3C478EF3D691} {95187E6A-5B74-4475-8FEB-758ACD012DCC} = {90030E85-0C4F-456F-B879-443E8A3F220D} {47777735-7432-4CCA-A8C5-672E9EE65121} = {90030E85-0C4F-456F-B879-443E8A3F220D} + {C35AB37B-5A09-4896-BEEE-B126B7E7018A} = {A066395F-6F73-45DC-B5A6-B4E306110DCE} + {E8A1097D-A65A-4B17-A3A2-F50D79552732} = {A066395F-6F73-45DC-B5A6-B4E306110DCE} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {46A1D25A-78D1-4476-9CBF-25B75E296341} diff --git a/mkdocs.yml b/mkdocs.yml index a3f914db30e..abc0748e6e8 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -208,6 +208,8 @@ nav: - Data Migrations: docs/reference/modules/Migrations/README.md - Dynamic Cache: docs/reference/modules/DynamicCache/README.md - Email: docs/reference/modules/Email/README.md + - SMTP Provider: docs/reference/modules/Email.Smtp/README.md + - Azure Email Provider: docs/reference/modules/Email.Azure/README.md - GraphQL: docs/reference/modules/Apis.GraphQL/README.md - GraphQL queries: docs/reference/core/Apis.GraphQL.Abstractions/README.md - Health Check: docs/reference/modules/HealthChecks/README.md diff --git a/src/OrchardCore.Build/Dependencies.AspNetCore.props b/src/OrchardCore.Build/Dependencies.AspNetCore.props index 213d63860e0..ea300bc3e6f 100644 --- a/src/OrchardCore.Build/Dependencies.AspNetCore.props +++ b/src/OrchardCore.Build/Dependencies.AspNetCore.props @@ -20,8 +20,8 @@ - 8.0.2 - 8.0.2 + 8.0.3 + 8.0.3 diff --git a/src/OrchardCore.Cms.Web/appsettings.json b/src/OrchardCore.Cms.Web/appsettings.json index 30d17294534..d8e6f6e8ac8 100644 --- a/src/OrchardCore.Cms.Web/appsettings.json +++ b/src/OrchardCore.Cms.Web/appsettings.json @@ -201,7 +201,7 @@ //"OrchardCore_HealthChecks": { // "Url": "/health/live" //}, - //"OrchardCore_Email": { + //"OrchardCore_Email_Smtp": { // "DefaultSender": "", // "DeliveryMethod": "Network", // "PickupDirectoryLocation": "", @@ -217,6 +217,10 @@ // "Username": "", // "Password": "" //}, + //"OrchardCore_Email_Azure": { + // "DefaultSender": "", + // "ConnectionString": "" + //} //"OrchardCore_ReverseProxy": { // "ForwardedHeaders": "None" //}, diff --git a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Deployment/AdminMenuDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Deployment/AdminMenuDeploymentSource.cs index 0cb65240c45..007e4797fd6 100644 --- a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Deployment/AdminMenuDeploymentSource.cs +++ b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Deployment/AdminMenuDeploymentSource.cs @@ -4,6 +4,7 @@ using Microsoft.Extensions.Options; using OrchardCore.AdminMenu.Services; using OrchardCore.Deployment; +using OrchardCore.Json; namespace OrchardCore.AdminMenu.Deployment { @@ -12,10 +13,11 @@ public class AdminMenuDeploymentSource : IDeploymentSource private readonly IAdminMenuService _adminMenuService; private readonly JsonSerializerOptions _serializationOptions; - public AdminMenuDeploymentSource(IAdminMenuService adminMenuService, IOptions serializationOptions) + public AdminMenuDeploymentSource(IAdminMenuService adminMenuService, + IOptions serializationOptions) { _adminMenuService = adminMenuService; - _serializationOptions = serializationOptions.Value; + _serializationOptions = serializationOptions.Value.SerializerOptions; } public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result) diff --git a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Recipes/AdminMenuStep.cs b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Recipes/AdminMenuStep.cs index dff8ef5d672..9f4faaf5286 100644 --- a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Recipes/AdminMenuStep.cs +++ b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Recipes/AdminMenuStep.cs @@ -5,6 +5,7 @@ using System.Threading.Tasks; using Microsoft.Extensions.Options; using OrchardCore.AdminMenu.Services; +using OrchardCore.Json; using OrchardCore.Recipes.Models; using OrchardCore.Recipes.Services; @@ -20,12 +21,12 @@ public class AdminMenuStep : IRecipeStepHandler public AdminMenuStep( IAdminMenuService adminMenuService, - IOptions serializationOptions) + IOptions serializationOptions) { _adminMenuService = adminMenuService; // The recipe step contains polymorphic types (menu items) which need to be resolved - _serializationOptions = serializationOptions.Value; + _serializationOptions = serializationOptions.Value.SerializerOptions; } public async Task ExecuteAsync(RecipeExecutionContext context) diff --git a/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/Models/BackgroundTaskDocument.cs b/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/Models/BackgroundTaskDocument.cs index cef98c7754c..4096bb107a3 100644 --- a/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/Models/BackgroundTaskDocument.cs +++ b/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/Models/BackgroundTaskDocument.cs @@ -2,10 +2,9 @@ using System.Collections.Generic; using OrchardCore.Data.Documents; -namespace OrchardCore.BackgroundTasks.Models +namespace OrchardCore.BackgroundTasks.Models; + +public class BackgroundTaskDocument : Document { - public class BackgroundTaskDocument : Document - { - public Dictionary Settings { get; } = new(StringComparer.OrdinalIgnoreCase); - } + public Dictionary Settings { get; init; } = new(StringComparer.OrdinalIgnoreCase); } diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/AuditTrail/Drivers/AuditTrailContentsDriver.cs b/src/OrchardCore.Modules/OrchardCore.Contents/AuditTrail/Drivers/AuditTrailContentsDriver.cs index 363357986b4..3288f89ac94 100644 --- a/src/OrchardCore.Modules/OrchardCore.Contents/AuditTrail/Drivers/AuditTrailContentsDriver.cs +++ b/src/OrchardCore.Modules/OrchardCore.Contents/AuditTrail/Drivers/AuditTrailContentsDriver.cs @@ -1,3 +1,6 @@ +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Http; +using OrchardCore.AuditTrail; using OrchardCore.ContentManagement; using OrchardCore.ContentManagement.Display.ContentDisplay; using OrchardCore.ContentManagement.Display.ViewModels; @@ -8,10 +11,22 @@ namespace OrchardCore.Contents.AuditTrail.Drivers { public class AuditTrailContentsDriver : ContentDisplayDriver { - // TODO: What permission are we looking for here? + private readonly IHttpContextAccessor _httpContextAccessor; + private readonly IAuthorizationService _authorizationService; + + public AuditTrailContentsDriver( + IHttpContextAccessor httpContextAccessor, + IAuthorizationService authorizationService) + { + _httpContextAccessor = httpContextAccessor; + _authorizationService = authorizationService; + } + public override IDisplayResult Display(ContentItem contentItem, IUpdateModel updater) { - return Initialize("AuditTrailContentsAction_SummaryAdmin", m => m.ContentItem = contentItem).Location("SummaryAdmin", "ActionsMenu:10"); + return Initialize("AuditTrailContentsAction_SummaryAdmin", m => m.ContentItem = contentItem) + .Location("SummaryAdmin", "ActionsMenu:10") + .RenderWhen(() => _authorizationService.AuthorizeAsync(_httpContextAccessor.HttpContext?.User, AuditTrailPermissions.ViewAuditTrail)); } } } diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/AdminController.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/AdminController.cs index 33ffa0dd8f7..6a4796edce4 100644 --- a/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/AdminController.cs +++ b/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/AdminController.cs @@ -9,7 +9,6 @@ using Microsoft.AspNetCore.Mvc.Rendering; using Microsoft.AspNetCore.Routing; using Microsoft.Extensions.Localization; -using Microsoft.Extensions.Logging; using Microsoft.Extensions.Options; using OrchardCore.Admin; using OrchardCore.ContentManagement; @@ -31,20 +30,15 @@ namespace OrchardCore.Contents.Controllers { - public class AdminController : Controller + public class AdminController : Controller, IUpdateModel { + private readonly IAuthorizationService _authorizationService; private readonly IContentManager _contentManager; + private readonly IContentItemDisplayManager _contentItemDisplayManager; private readonly IContentDefinitionManager _contentDefinitionManager; - private readonly PagerOptions _pagerOptions; + private readonly IDisplayManager _contentOptionsDisplayManager; private readonly ISession _session; - private readonly IContentItemDisplayManager _contentItemDisplayManager; private readonly INotifier _notifier; - private readonly IAuthorizationService _authorizationService; - private readonly IDisplayManager _contentOptionsDisplayManager; - private readonly IContentsAdminListQueryService _contentsAdminListQueryService; - private readonly IUpdateModelAccessor _updateModelAccessor; - private readonly IShapeFactory _shapeFactory; - private readonly ILogger _logger; protected readonly IHtmlLocalizer H; protected readonly IStringLocalizer S; @@ -54,37 +48,29 @@ public AdminController( IContentManager contentManager, IContentItemDisplayManager contentItemDisplayManager, IContentDefinitionManager contentDefinitionManager, - IOptions pagerOptions, - INotifier notifier, - ISession session, - IShapeFactory shapeFactory, IDisplayManager contentOptionsDisplayManager, - IContentsAdminListQueryService contentsAdminListQueryService, - ILogger logger, + ISession session, + INotifier notifier, IHtmlLocalizer htmlLocalizer, - IStringLocalizer stringLocalizer, - IUpdateModelAccessor updateModelAccessor) + IStringLocalizer stringLocalizer) { _authorizationService = authorizationService; - _notifier = notifier; - _contentItemDisplayManager = contentItemDisplayManager; - _session = session; - _pagerOptions = pagerOptions.Value; _contentManager = contentManager; + _contentItemDisplayManager = contentItemDisplayManager; _contentDefinitionManager = contentDefinitionManager; - _updateModelAccessor = updateModelAccessor; _contentOptionsDisplayManager = contentOptionsDisplayManager; - _contentsAdminListQueryService = contentsAdminListQueryService; - _shapeFactory = shapeFactory; - _logger = logger; + _session = session; + _notifier = notifier; H = htmlLocalizer; S = stringLocalizer; } - [HttpGet] [Admin("Contents/ContentItems/{contentTypeId?}", "ListContentItems")] public async Task List( + [FromServices] IOptions pagerOptions, + [FromServices] IShapeFactory shapeFactory, + [FromServices] IContentsAdminListQueryService contentsAdminListQueryService, [ModelBinder(BinderType = typeof(ContentItemFilterEngineModelBinder), Name = "q")] QueryFilterResult queryFilterResult, ContentOptionsViewModel options, PagerParameters pagerParameters, @@ -93,7 +79,7 @@ public async Task List( { var contentTypeDefinitions = (await _contentDefinitionManager.ListTypeDefinitionsAsync()) .OrderBy(ctd => ctd.DisplayName) - .ToList(); + .ToArray(); if (!await _authorizationService.AuthorizeContentTypeDefinitionsAsync(User, CommonPermissions.ListContent, contentTypeDefinitions, _contentManager)) { @@ -155,23 +141,23 @@ public async Task List( // We populate the remaining SelectLists. options.ContentStatuses = [ - new SelectListItem(S["Latest"], nameof(ContentsStatus.Latest), options.ContentsStatus == ContentsStatus.Latest), - new SelectListItem(S["Published"], nameof(ContentsStatus.Published), options.ContentsStatus == ContentsStatus.Published), - new SelectListItem(S["Unpublished"], nameof(ContentsStatus.Draft), options.ContentsStatus == ContentsStatus.Draft), - new SelectListItem(S["All versions"], nameof(ContentsStatus.AllVersions), options.ContentsStatus == ContentsStatus.AllVersions), + new SelectListItem(S["Latest"], nameof(ContentsStatus.Latest)), + new SelectListItem(S["Published"], nameof(ContentsStatus.Published)), + new SelectListItem(S["Unpublished"], nameof(ContentsStatus.Draft)), + new SelectListItem(S["All versions"], nameof(ContentsStatus.AllVersions)), ]; if (await IsAuthorizedAsync(Permissions.ListContent)) { - options.ContentStatuses.Insert(1, new SelectListItem() { Text = S["Owned by me"], Value = nameof(ContentsStatus.Owner) }); + options.ContentStatuses.Insert(1, new SelectListItem(S["Owned by me"], nameof(ContentsStatus.Owner))); } options.ContentSorts = [ - new SelectListItem(S["Recently created"], nameof(ContentsOrder.Created), options.OrderBy == ContentsOrder.Created), - new SelectListItem(S["Recently modified"], nameof(ContentsOrder.Modified), options.OrderBy == ContentsOrder.Modified), - new SelectListItem(S["Recently published"], nameof(ContentsOrder.Published), options.OrderBy == ContentsOrder.Published), - new SelectListItem(S["Title"], nameof(ContentsOrder.Title), options.OrderBy == ContentsOrder.Title), + new SelectListItem(S["Recently created"], nameof(ContentsOrder.Created)), + new SelectListItem(S["Recently modified"], nameof(ContentsOrder.Modified)), + new SelectListItem(S["Recently published"], nameof(ContentsOrder.Published)), + new SelectListItem(S["Title"], nameof(ContentsOrder.Title)), ]; options.ContentsBulkAction = @@ -191,7 +177,7 @@ public async Task List( options.ContentTypeOptions ??= []; // With the populated options, filter the query allowing the filters to alter the options. - var query = await _contentsAdminListQueryService.QueryAsync(options, _updateModelAccessor.ModelUpdater); + var query = await contentsAdminListQueryService.QueryAsync(options, this); // The search text is provided back to the UI. options.SearchText = options.FilterResult.ToString(); @@ -200,17 +186,24 @@ public async Task List( // Populate route values to maintain previous route data when generating page links. options.RouteValues.TryAdd("q", options.FilterResult.ToString()); - var pager = new Pager(pagerParameters, _pagerOptions.GetPageSize()); - dynamic pagerShape = await _shapeFactory.PagerAsync(pager, _pagerOptions.MaxPagedCount > 0 ? _pagerOptions.MaxPagedCount : await query.CountAsync(), options.RouteValues); + var pager = new Pager(pagerParameters, pagerOptions.Value.GetPageSize()); + + var itemsPerPage = pagerOptions.Value.MaxPagedCount > 0 + ? pagerOptions.Value.MaxPagedCount + : await query.CountAsync(); + + dynamic pagerShape = await shapeFactory.PagerAsync(pager, itemsPerPage, options.RouteValues); // Load items so that loading handlers are invoked. - var pageOfContentItems = await query.Skip(pager.GetStartIndex()).Take(pager.PageSize).ListAsync(_contentManager); + var pageOfContentItems = await query.Skip(pager.GetStartIndex()) + .Take(pager.PageSize) + .ListAsync(_contentManager); // We prepare the content items SummaryAdmin shape. var contentItemSummaries = new List(); foreach (var contentItem in pageOfContentItems) { - contentItemSummaries.Add(await _contentItemDisplayManager.BuildDisplayAsync(contentItem, _updateModelAccessor.ModelUpdater, "SummaryAdmin")); + contentItemSummaries.Add(await _contentItemDisplayManager.BuildDisplayAsync(contentItem, this, "SummaryAdmin")); } // Populate options pager summary values. @@ -220,9 +213,9 @@ public async Task List( options.ContentItemsCount = contentItemSummaries.Count; options.TotalItemCount = pagerShape.TotalItemCount; - var header = await _contentOptionsDisplayManager.BuildEditorAsync(options, _updateModelAccessor.ModelUpdater, false, string.Empty, string.Empty); + var header = await _contentOptionsDisplayManager.BuildEditorAsync(options, this, false, string.Empty, string.Empty); - var shapeViewModel = await _shapeFactory.CreateAsync("ContentsAdminList", viewModel => + var shapeViewModel = await shapeFactory.CreateAsync("ContentsAdminList", viewModel => { viewModel.ContentItems = contentItemSummaries; viewModel.Pager = pagerShape; @@ -233,18 +226,22 @@ public async Task List( return View(shapeViewModel); } - [HttpPost, ActionName(nameof(List))] + [HttpPost] + [ActionName(nameof(List))] [FormValueRequired("submit.Filter")] public async Task ListFilterPOST(ContentOptionsViewModel options) { // When the user has typed something into the search input no further evaluation of the form post is required. if (!string.Equals(options.SearchText, options.OriginalSearchText, StringComparison.OrdinalIgnoreCase)) { - return RedirectToAction(nameof(List), new RouteValueDictionary { { "q", options.SearchText } }); + return RedirectToAction(nameof(List), new RouteValueDictionary + { + { "q", options.SearchText }, + }); } // Evaluate the values provided in the form post and map them to the filter result and route values. - await _contentOptionsDisplayManager.UpdateEditorAsync(options, _updateModelAccessor.ModelUpdater, false, string.Empty, string.Empty); + await _contentOptionsDisplayManager.UpdateEditorAsync(options, this, false, string.Empty, string.Empty); // The route value must always be added after the editors have updated the models. options.RouteValues.TryAdd("q", options.FilterResult.ToString()); @@ -252,14 +249,18 @@ public async Task ListFilterPOST(ContentOptionsViewModel options) return RedirectToAction(nameof(List), options.RouteValues); } - [HttpPost, ActionName(nameof(List))] + [HttpPost] + [ActionName(nameof(List))] [FormValueRequired("submit.BulkAction")] - public async Task ListPOST(ContentOptionsViewModel options, IEnumerable itemIds) + public async Task ListPOST(ContentOptionsViewModel options, long[] itemIds) { - if (itemIds?.Count() > 0) + if (itemIds.Length > 0) { // Load items so that loading handlers are invoked. - var checkedContentItems = await _session.Query().Where(x => x.DocumentId.IsIn(itemIds) && x.Latest).ListAsync(_contentManager); + var checkedContentItems = await _session.Query() + .Where(x => x.DocumentId.IsIn(itemIds) && x.Latest) + .ListAsync(_contentManager); + switch (options.BulkAction) { case ContentsBulkAction.None: @@ -307,7 +308,7 @@ public async Task ListPOST(ContentOptionsViewModel options, IEnume await _notifier.SuccessAsync(H["Content removed successfully."]); break; default: - throw new ArgumentOutOfRangeException(options.BulkAction.ToString(), "Invalid bulk action."); + return BadRequest(); } } @@ -329,14 +330,18 @@ public async Task Create(string id) return Forbid(); } - var model = await _contentItemDisplayManager.BuildEditorAsync(contentItem, _updateModelAccessor.ModelUpdater, true); + var model = await _contentItemDisplayManager.BuildEditorAsync(contentItem, this, true); return View(model); } - [HttpPost, ActionName(nameof(Create))] + [HttpPost] + [ActionName(nameof(Create))] [FormValueRequired("submit.Save")] - public Task CreatePOST(string id, [Bind(Prefix = "submit.Save")] string submitSave, string returnUrl) + public Task CreatePOST( + string id, + [Bind(Prefix = "submit.Save")] string submitSave, + string returnUrl) { var stayOnSamePage = submitSave == "submit.SaveAndContinue"; return CreatePOST(id, returnUrl, stayOnSamePage, async contentItem => @@ -351,9 +356,13 @@ await _notifier.SuccessAsync(string.IsNullOrWhiteSpace(typeDefinition?.DisplayNa }); } - [HttpPost, ActionName(nameof(Create))] + [HttpPost] + [ActionName(nameof(Create))] [FormValueRequired("submit.Publish")] - public async Task CreateAndPublishPOST(string id, [Bind(Prefix = "submit.Publish")] string submitPublish, string returnUrl) + public async Task CreateAndPublishPOST( + string id, + [Bind(Prefix = "submit.Publish")] string submitPublish, + string returnUrl) { if (string.IsNullOrEmpty(id)) { @@ -394,7 +403,7 @@ public async Task Display(string contentItemId) return Forbid(); } - var model = await _contentItemDisplayManager.BuildDisplayAsync(contentItem, _updateModelAccessor.ModelUpdater, "DetailAdmin"); + var model = await _contentItemDisplayManager.BuildDisplayAsync(contentItem, this, "DetailAdmin"); return View(model); } @@ -414,14 +423,18 @@ public async Task Edit(string contentItemId) return Forbid(); } - var model = await _contentItemDisplayManager.BuildEditorAsync(contentItem, _updateModelAccessor.ModelUpdater, false); + var model = await _contentItemDisplayManager.BuildEditorAsync(contentItem, this, false); return View(model); } - [HttpPost, ActionName(nameof(Edit))] + [HttpPost] + [ActionName(nameof(Edit))] [FormValueRequired("submit.Save")] - public Task EditPOST(string contentItemId, [Bind(Prefix = "submit.Save")] string submitSave, string returnUrl) + public Task EditPOST( + string contentItemId, + [Bind(Prefix = "submit.Save")] string submitSave, + string returnUrl) { var stayOnSamePage = submitSave == "submit.SaveAndContinue"; return EditPOST(contentItemId, returnUrl, stayOnSamePage, async contentItem => @@ -436,9 +449,13 @@ await _notifier.SuccessAsync(string.IsNullOrWhiteSpace(typeDefinition?.DisplayNa }); } - [HttpPost, ActionName(nameof(Edit))] + [HttpPost] + [ActionName(nameof(Edit))] [FormValueRequired("submit.Publish")] - public async Task EditAndPublishPOST(string contentItemId, [Bind(Prefix = "submit.Publish")] string submitPublish, string returnUrl) + public async Task EditAndPublishPOST( + string contentItemId, + [Bind(Prefix = "submit.Publish")] string submitPublish, + string returnUrl) { var stayOnSamePage = submitPublish == "submit.PublishAndContinue"; @@ -489,12 +506,16 @@ public async Task Clone(string contentItemId, string returnUrl) catch (InvalidOperationException) { await _notifier.WarningAsync(H["Could not clone the content item."]); - return Url.IsLocalUrl(returnUrl) ? (IActionResult)this.LocalRedirect(returnUrl, true) : RedirectToAction(nameof(List)); + return Url.IsLocalUrl(returnUrl) + ? this.LocalRedirect(returnUrl, true) + : RedirectToAction(nameof(List)); } await _notifier.InformationAsync(H["Successfully cloned. The clone was saved as a draft."]); - return Url.IsLocalUrl(returnUrl) ? (IActionResult)this.LocalRedirect(returnUrl, true) : RedirectToAction(nameof(List)); + return Url.IsLocalUrl(returnUrl) + ? this.LocalRedirect(returnUrl, true) + : RedirectToAction(nameof(List)); } [HttpPost] @@ -524,7 +545,9 @@ await _notifier.SuccessAsync(string.IsNullOrWhiteSpace(typeDefinition?.DisplayNa : H["The {0} draft has been removed.", typeDefinition.DisplayName]); } - return Url.IsLocalUrl(returnUrl) ? (IActionResult)this.LocalRedirect(returnUrl, true) : RedirectToAction(nameof(List)); + return Url.IsLocalUrl(returnUrl) + ? this.LocalRedirect(returnUrl, true) + : RedirectToAction(nameof(List)); } [HttpPost] @@ -549,7 +572,9 @@ await _notifier.SuccessAsync(string.IsNullOrWhiteSpace(typeDefinition?.DisplayNa : H["That {0} has been removed.", typeDefinition.DisplayName]); } - return Url.IsLocalUrl(returnUrl) ? (IActionResult)this.LocalRedirect(returnUrl, true) : RedirectToAction(nameof(List)); + return Url.IsLocalUrl(returnUrl) + ? this.LocalRedirect(returnUrl, true) + : RedirectToAction(nameof(List)); } [HttpPost] @@ -580,7 +605,9 @@ public async Task Publish(string contentItemId, string returnUrl) await _notifier.SuccessAsync(H["That {0} has been published.", typeDefinition.DisplayName]); } - return Url.IsLocalUrl(returnUrl) ? (IActionResult)this.LocalRedirect(returnUrl, true) : RedirectToAction(nameof(List)); + return Url.IsLocalUrl(returnUrl) + ? this.LocalRedirect(returnUrl, true) + : RedirectToAction(nameof(List)); } [HttpPost] @@ -611,10 +638,16 @@ public async Task Unpublish(string contentItemId, string returnUr await _notifier.SuccessAsync(H["The {0} has been unpublished.", typeDefinition.DisplayName]); } - return Url.IsLocalUrl(returnUrl) ? (IActionResult)this.LocalRedirect(returnUrl, true) : RedirectToAction(nameof(List)); + return Url.IsLocalUrl(returnUrl) + ? this.LocalRedirect(returnUrl, true) + : RedirectToAction(nameof(List)); } - private async Task CreatePOST(string id, string returnUrl, bool stayOnSamePage, Func conditionallyPublish) + private async Task CreatePOST( + string id, + string returnUrl, + bool stayOnSamePage, + Func conditionallyPublish) { var contentItem = await CreateContentItemOwnedByCurrentUserAsync(id); @@ -623,7 +656,7 @@ private async Task CreatePOST(string id, string returnUrl, bool s return Forbid(); } - var model = await _contentItemDisplayManager.UpdateEditorAsync(contentItem, _updateModelAccessor.ModelUpdater, true); + var model = await _contentItemDisplayManager.UpdateEditorAsync(contentItem, this, true); if (ModelState.IsValid) { @@ -653,7 +686,11 @@ private async Task CreatePOST(string id, string returnUrl, bool s return RedirectToRoute(adminRouteValues); } - private async Task EditPOST(string contentItemId, string returnUrl, bool stayOnSamePage, Func conditionallyPublish) + private async Task EditPOST( + string contentItemId, + string returnUrl, + bool stayOnSamePage, + Func conditionallyPublish) { var contentItem = await _contentManager.GetAsync(contentItemId, VersionOptions.DraftRequired); @@ -667,7 +704,7 @@ private async Task EditPOST(string contentItemId, string returnUr return Forbid(); } - var model = await _contentItemDisplayManager.UpdateEditorAsync(contentItem, _updateModelAccessor.ModelUpdater, false); + var model = await _contentItemDisplayManager.UpdateEditorAsync(contentItem, this, false); if (!ModelState.IsValid) { @@ -679,18 +716,27 @@ private async Task EditPOST(string contentItemId, string returnUr if (returnUrl == null) { - return RedirectToAction(nameof(Edit), new RouteValueDictionary { { "ContentItemId", contentItem.ContentItemId } }); + return RedirectToAction(nameof(Edit), new RouteValueDictionary + { + { "ContentItemId", contentItem.ContentItemId }, + }); } if (stayOnSamePage) { - return RedirectToAction(nameof(Edit), new RouteValueDictionary { { "ContentItemId", contentItem.ContentItemId }, { "returnUrl", returnUrl } }); + return RedirectToAction(nameof(Edit), new RouteValueDictionary + { + { "ContentItemId", contentItem.ContentItemId }, + { "returnUrl", returnUrl }, + }); } return this.LocalRedirect(returnUrl, true); } - private async Task> GetCreatableTypeOptionsAsync(bool canCreateSelectedContentType, params ContentTypeDefinition[] contentTypeDefinitions) + private async Task> GetCreatableTypeOptionsAsync( + bool canCreateSelectedContentType, + params ContentTypeDefinition[] contentTypeDefinitions) { var options = new List(); @@ -709,7 +755,10 @@ private async Task> GetCreatableTypeOptionsAsync(bool canCr return options; } - private async Task> GetListableContentTypeOptionsAsync(IEnumerable definitions, string selectedContentType, bool showSelectAll = true) + private async Task> GetListableContentTypeOptionsAsync( + IEnumerable definitions, + string selectedContentType, + bool showSelectAll = true) { var currentUserId = CurrentUserId(); diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/ApiController.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/ApiController.cs index 8b0826f11c1..59e07313e6c 100644 --- a/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/ApiController.cs +++ b/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/ApiController.cs @@ -18,11 +18,15 @@ namespace OrchardCore.Contents.Controllers [Authorize(AuthenticationSchemes = "Api"), IgnoreAntiforgeryToken, AllowAnonymous] public class ApiController : Controller { - private static readonly JsonMergeSettings _updateJsonMergeSettings = new() { MergeArrayHandling = MergeArrayHandling.Replace }; + private static readonly JsonMergeSettings _updateJsonMergeSettings = new() + { + MergeArrayHandling = MergeArrayHandling.Replace + }; private readonly IContentManager _contentManager; private readonly IContentDefinitionManager _contentDefinitionManager; private readonly IAuthorizationService _authorizationService; + protected readonly IStringLocalizer S; public ApiController( @@ -37,7 +41,8 @@ public ApiController( S = stringLocalizer; } - [Route("{contentItemId}"), HttpGet] + [HttpGet] + [Route("{contentItemId}")] public async Task Get(string contentItemId) { if (!await _authorizationService.AuthorizeAsync(User, Permissions.AccessContentApi)) diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/ItemController.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/ItemController.cs index 5f6c9cee5d8..66f5aaeb5c5 100644 --- a/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/ItemController.cs +++ b/src/OrchardCore.Modules/OrchardCore.Contents/Controllers/ItemController.cs @@ -7,23 +7,20 @@ namespace OrchardCore.Contents.Controllers { - public class ItemController : Controller + public class ItemController : Controller, IUpdateModel { private readonly IContentManager _contentManager; private readonly IContentItemDisplayManager _contentItemDisplayManager; private readonly IAuthorizationService _authorizationService; - private readonly IUpdateModelAccessor _updateModelAccessor; public ItemController( IContentManager contentManager, IContentItemDisplayManager contentItemDisplayManager, - IAuthorizationService authorizationService, - IUpdateModelAccessor updateModelAccessor) + IAuthorizationService authorizationService) { - _authorizationService = authorizationService; - _contentItemDisplayManager = contentItemDisplayManager; _contentManager = contentManager; - _updateModelAccessor = updateModelAccessor; + _contentItemDisplayManager = contentItemDisplayManager; + _authorizationService = authorizationService; } public async Task Display(string contentItemId, string jsonPath) @@ -40,7 +37,7 @@ public async Task Display(string contentItemId, string jsonPath) return this.ChallengeOrForbid(); } - var model = await _contentItemDisplayManager.BuildDisplayAsync(contentItem, _updateModelAccessor.ModelUpdater); + var model = await _contentItemDisplayManager.BuildDisplayAsync(contentItem, this); return View(model); } @@ -66,7 +63,7 @@ public async Task Preview(string contentItemId) return this.ChallengeOrForbid(); } - var model = await _contentItemDisplayManager.BuildDisplayAsync(contentItem, _updateModelAccessor.ModelUpdater); + var model = await _contentItemDisplayManager.BuildDisplayAsync(contentItem, this); return View(model); } diff --git a/src/OrchardCore.Modules/OrchardCore.Deployment/Deployment/DeploymentPlanDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.Deployment/Deployment/DeploymentPlanDeploymentSource.cs index 8f3c6f1b867..4e1c7450262 100644 --- a/src/OrchardCore.Modules/OrchardCore.Deployment/Deployment/DeploymentPlanDeploymentSource.cs +++ b/src/OrchardCore.Modules/OrchardCore.Deployment/Deployment/DeploymentPlanDeploymentSource.cs @@ -4,6 +4,7 @@ using System.Text.Json.Nodes; using System.Threading.Tasks; using Microsoft.Extensions.Options; +using OrchardCore.Json; namespace OrchardCore.Deployment.Deployment { @@ -16,11 +17,11 @@ public class DeploymentPlanDeploymentSource : IDeploymentSource public DeploymentPlanDeploymentSource( IDeploymentPlanService deploymentPlanService, IEnumerable deploymentStepFactories, - IOptions jsonSerializerOptions) + IOptions jsonSerializerOptions) { _deploymentPlanService = deploymentPlanService; _deploymentStepFactories = deploymentStepFactories; - _jsonSerializerOptions = jsonSerializerOptions.Value; + _jsonSerializerOptions = jsonSerializerOptions.Value.SerializerOptions; } public async Task ProcessDeploymentStepAsync(DeploymentStep deploymentStep, DeploymentPlanResult result) diff --git a/src/OrchardCore.Modules/OrchardCore.Deployment/Recipes/DeploymentPlansRecipeStep.cs b/src/OrchardCore.Modules/OrchardCore.Deployment/Recipes/DeploymentPlansRecipeStep.cs index aa4b85650f4..fe4870facce 100644 --- a/src/OrchardCore.Modules/OrchardCore.Deployment/Recipes/DeploymentPlansRecipeStep.cs +++ b/src/OrchardCore.Modules/OrchardCore.Deployment/Recipes/DeploymentPlansRecipeStep.cs @@ -6,6 +6,7 @@ using System.Threading.Tasks; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Options; +using OrchardCore.Json; using OrchardCore.Recipes.Models; using OrchardCore.Recipes.Services; @@ -22,11 +23,11 @@ public class DeploymentPlansRecipeStep : IRecipeStepHandler public DeploymentPlansRecipeStep( IServiceProvider serviceProvider, - IOptions jsonSerializerOptions, + IOptions jsonSerializerOptions, IDeploymentPlanService deploymentPlanService) { _serviceProvider = serviceProvider; - _jsonSerializerOptions = jsonSerializerOptions.Value; + _jsonSerializerOptions = jsonSerializerOptions.Value.SerializerOptions; _deploymentPlanService = deploymentPlanService; } diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Drivers/AzureEmailSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Drivers/AzureEmailSettingsDisplayDriver.cs new file mode 100644 index 00000000000..e2d5fecd337 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Drivers/AzureEmailSettingsDisplayDriver.cs @@ -0,0 +1,161 @@ +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.DataProtection; +using Microsoft.AspNetCore.Http; +using Microsoft.AspNetCore.Mvc.ModelBinding; +using Microsoft.Extensions.Localization; +using OrchardCore.DisplayManagement.Entities; +using OrchardCore.DisplayManagement.Handlers; +using OrchardCore.DisplayManagement.ModelBinding; +using OrchardCore.DisplayManagement.Views; +using OrchardCore.Email; +using OrchardCore.Email.Azure; +using OrchardCore.Email.Azure.Services; +using OrchardCore.Email.Azure.ViewModels; +using OrchardCore.Email.Core; +using OrchardCore.Email.Services; +using OrchardCore.Entities; +using OrchardCore.Environment.Shell; +using OrchardCore.Modules; +using OrchardCore.Mvc.ModelBinding; +using OrchardCore.Settings; + +namespace OrchardCore.Azure.Email.Drivers; + +public class AzureEmailSettingsDisplayDriver : SectionDisplayDriver +{ + private readonly IHttpContextAccessor _httpContextAccessor; + private readonly IAuthorizationService _authorizationService; + private readonly IDataProtectionProvider _dataProtectionProvider; + private readonly IShellHost _shellHost; + private readonly ShellSettings _shellSettings; + private readonly IEmailAddressValidator _emailValidator; + + protected IStringLocalizer S; + + public AzureEmailSettingsDisplayDriver( + IHttpContextAccessor httpContextAccessor, + IAuthorizationService authorizationService, + IDataProtectionProvider dataProtectionProvider, + IShellHost shellHost, + ShellSettings shellSettings, + IEmailAddressValidator emailValidator, + IStringLocalizer stringLocalizer) + { + _httpContextAccessor = httpContextAccessor; + _authorizationService = authorizationService; + _dataProtectionProvider = dataProtectionProvider; + _shellHost = shellHost; + _shellSettings = shellSettings; + _emailValidator = emailValidator; + S = stringLocalizer; + } + + public override async Task EditAsync(AzureEmailSettings settings, BuildEditorContext context) + { + if (!context.GroupId.EqualsOrdinalIgnoreCase(EmailSettings.GroupId)) + { + return null; + } + + if (!await _authorizationService.AuthorizeAsync(_httpContextAccessor.HttpContext?.User, Permissions.ManageEmailSettings)) + { + return null; + } + + return Initialize("AzureEmailSettings_Edit", model => + { + model.IsEnabled = settings.IsEnabled; + model.DefaultSender = settings.DefaultSender; + model.HasConnectionString = !string.IsNullOrWhiteSpace(settings.ConnectionString); + }).Location("Content:5#Azure") + .OnGroup(EmailSettings.GroupId); + } + + public override async Task UpdateAsync(ISite site, AzureEmailSettings settings, IUpdateModel updater, BuildEditorContext context) + { + if (!context.GroupId.EqualsOrdinalIgnoreCase(EmailSettings.GroupId)) + { + return null; + } + + if (!await _authorizationService.AuthorizeAsync(_httpContextAccessor.HttpContext?.User, Permissions.ManageEmailSettings)) + { + return null; + } + + var model = new AzureEmailSettingsViewModel(); + + if (await updater.TryUpdateModelAsync(model, Prefix)) + { + var emailSettings = site.As(); + + var hasChanges = model.IsEnabled != settings.IsEnabled; + + settings.IsEnabled = model.IsEnabled; + + if (!model.IsEnabled) + { + if (hasChanges && emailSettings.DefaultProviderName == AzureEmailProvider.TechnicalName) + { + emailSettings.DefaultProviderName = null; + + site.Put(emailSettings); + } + } + else + { + hasChanges |= model.DefaultSender != settings.DefaultSender; + + if (string.IsNullOrEmpty(model.DefaultSender)) + { + context.Updater.ModelState.AddModelError(Prefix, nameof(model.DefaultSender), S["The Default Sender is a required field."]); + } + else if (!_emailValidator.Validate(model.DefaultSender)) + { + context.Updater.ModelState.AddModelError(Prefix, nameof(model.DefaultSender), S["The Default Sender is invalid."]); + } + + settings.DefaultSender = model.DefaultSender; + + if (string.IsNullOrWhiteSpace(model.ConnectionString) + && settings.ConnectionString is null) + { + context.Updater.ModelState.AddModelError(Prefix, nameof(model.ConnectionString), S["Connection string is required."]); + } + else if (!string.IsNullOrWhiteSpace(model.ConnectionString)) + { + // Encrypt the connection string. + var protector = _dataProtectionProvider.CreateProtector(AzureEmailOptionsConfiguration.ProtectorName); + + var protectedConnection = protector.Protect(model.ConnectionString); + + // Check if the connection string changed before setting it. + hasChanges |= protectedConnection != settings.ConnectionString; + + settings.ConnectionString = protectedConnection; + } + } + + if (context.Updater.ModelState.IsValid) + { + if (settings.IsEnabled && string.IsNullOrEmpty(emailSettings.DefaultProviderName)) + { + // If we are enabling the only provider, set it as the default one. + emailSettings.DefaultProviderName = AzureEmailProvider.TechnicalName; + site.Put(emailSettings); + + hasChanges = true; + } + + if (hasChanges) + { + // Release the tenant to apply the settings when something changed. + await _shellHost.ReleaseShellContextAsync(_shellSettings); + } + } + } + + return await EditAsync(settings, context); + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Manifest.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Manifest.cs new file mode 100644 index 00000000000..921f06486e4 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Manifest.cs @@ -0,0 +1,14 @@ +using OrchardCore.Modules.Manifest; + +[assembly: Module( + Name = "Azure Email Provider", + Author = ManifestConstants.OrchardCoreTeam, + Website = ManifestConstants.OrchardCoreWebsite, + Version = ManifestConstants.OrchardCoreVersion, + Description = "Provides an email service provider leveraging Azure Communication Services (ACS).", + Dependencies = + [ + "OrchardCore.Email" + ], + Category = "Messaging" +)] diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Models/AzureEmailOptions.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Models/AzureEmailOptions.cs new file mode 100644 index 00000000000..e83afa49f0e --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Models/AzureEmailOptions.cs @@ -0,0 +1,13 @@ +namespace OrchardCore.Email.Azure.Models; + +public class AzureEmailOptions +{ + public bool IsEnabled { get; set; } + + public string DefaultSender { get; set; } + + public string ConnectionString { get; set; } + + public bool ConfigurationExists() + => !string.IsNullOrWhiteSpace(DefaultSender) && !string.IsNullOrWhiteSpace(ConnectionString); +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Models/AzureEmailSettings.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Models/AzureEmailSettings.cs new file mode 100644 index 00000000000..1b40295c041 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Models/AzureEmailSettings.cs @@ -0,0 +1,16 @@ +namespace OrchardCore.Email.Azure; + +/// +/// Represents a settings for Azure email. +/// +public class AzureEmailSettings +{ + public bool IsEnabled { get; set; } + + public string DefaultSender { get; set; } + + /// + /// Gets or sets the connection string. + /// + public string ConnectionString { get; set; } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Models/DefaultAzureEmailOptions.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Models/DefaultAzureEmailOptions.cs new file mode 100644 index 00000000000..4af8b72853d --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Models/DefaultAzureEmailOptions.cs @@ -0,0 +1,5 @@ +namespace OrchardCore.Email.Azure.Models; + +public class DefaultAzureEmailOptions : AzureEmailOptions +{ +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/OrchardCore.Email.Azure.csproj b/src/OrchardCore.Modules/OrchardCore.Email.Azure/OrchardCore.Email.Azure.csproj new file mode 100644 index 00000000000..4578458c8a0 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/OrchardCore.Email.Azure.csproj @@ -0,0 +1,31 @@ + + + + true + + OrchardCore Azure Email + + $(OCFrameworkDescription) + + Provides the configuration of email settings and a default email service utilizing Azure Communication Services (ACS). + + $(PackageTags) OrchardCoreFramework + + + + + + + + + + + + + + + + + + + diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailOptionsConfiguration.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailOptionsConfiguration.cs new file mode 100644 index 00000000000..5b639b6d285 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailOptionsConfiguration.cs @@ -0,0 +1,41 @@ +using Microsoft.AspNetCore.DataProtection; +using Microsoft.Extensions.Options; +using OrchardCore.Email.Azure; +using OrchardCore.Email.Azure.Models; +using OrchardCore.Settings; + +namespace OrchardCore.Email.Services; + +public class AzureEmailOptionsConfiguration : IConfigureOptions +{ + public const string ProtectorName = "AzureEmailProtector"; + + private readonly ISiteService _siteService; + private readonly IDataProtectionProvider _dataProtectionProvider; + + public AzureEmailOptionsConfiguration( + ISiteService siteService, + IDataProtectionProvider dataProtectionProvider) + { + _siteService = siteService; + _dataProtectionProvider = dataProtectionProvider; + } + + public void Configure(AzureEmailOptions options) + { + var settings = _siteService.GetSiteSettingsAsync() + .GetAwaiter() + .GetResult() + .As(); + + options.IsEnabled = settings.IsEnabled; + options.DefaultSender = settings.DefaultSender; + + if (!string.IsNullOrEmpty(settings.ConnectionString)) + { + var protector = _dataProtectionProvider.CreateProtector(ProtectorName); + + options.ConnectionString = protector.Unprotect(settings.ConnectionString); + } + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailProvider.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailProvider.cs new file mode 100644 index 00000000000..3a159f485e7 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailProvider.cs @@ -0,0 +1,22 @@ +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Logging; +using Microsoft.Extensions.Options; +using OrchardCore.Email.Azure.Models; + +namespace OrchardCore.Email.Azure.Services; + +public class AzureEmailProvider : AzureEmailProviderBase +{ + public const string TechnicalName = "Azure"; + + public AzureEmailProvider( + IOptions options, + IEmailAddressValidator emailAddressValidator, + ILogger logger, + IStringLocalizer stringLocalizer) + : base(options.Value, emailAddressValidator, logger, stringLocalizer) + { + } + + public override LocalizedString DisplayName => S["Azure Communication Service"]; +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailProviderBase.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailProviderBase.cs new file mode 100644 index 00000000000..ea2e2171fb8 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailProviderBase.cs @@ -0,0 +1,229 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Threading.Tasks; +using Azure; +using Azure.Communication.Email; +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Logging; +using OrchardCore.Email.Azure.Models; + +namespace OrchardCore.Email.Azure.Services; + +public abstract class AzureEmailProviderBase : IEmailProvider +{ + // Common supported file extensions and their corresponding MIME types for email attachments + // using Azure Communication Services Email. + // For more info + protected static readonly Dictionary _allowedMimeTypes = new() + { + { ".3gp", "video/3gpp" }, + { ".3g2", "video/3gpp2" }, + { ".7z", "application/x-7z-compressed" }, + { ".aac", "audio/aac" }, + { ".avi", "video/x-msvideo" }, + { ".bmp", "image/bmp" }, + { ".csv", "text/csv" }, + { ".doc", "application/msword" }, + { ".docm", "application/vnd.ms-word.document.macroEnabled.12" }, + { ".docx", "application/vnd.openxmlformats-officedocument.wordprocessingml.document" }, + { ".eot", "application/vnd.ms-fontobject" }, + { ".epub", "application/epub+zip" }, + { ".gif", "image/gif" }, + { ".gz", "application/gzip" }, + { ".ico", "image/vnd.microsoft.icon" }, + { ".ics", "text/calendar" }, + { ".jpg", "image/jpeg" }, + { ".jpeg", "image/jpeg" }, + { ".json", "application/json" }, + { ".mid", ".midi audio/midi" }, + { ".midi", ".midi audio/midi" }, + { ".mp3", "audio/mpeg" }, + { ".mp4", "video/mp4" }, + { ".mpeg", "video/mpeg" }, + { ".oga", "audio/ogg" }, + { ".ogv", "video/ogg" }, + { ".ogx", "application/ogg" }, + { ".one", "application/onenote" }, + { ".opus", "audio/opus" }, + { ".otf", "font/otf" }, + { ".pdf", "application/pdf" }, + { ".png", "image/png" }, + { ".ppsm", "application/vnd.ms-powerpoint.slideshow.macroEnabled.12" }, + { ".ppsx", "application/vnd.openxmlformats-officedocument.presentationml.slideshow" }, + { ".ppt", "application/vnd.ms-powerpoint" }, + { ".pptm", "application/vnd.ms-powerpoint.presentation.macroEnabled.12" }, + { ".pptx", "application/vnd.openxmlformats-officedocument.presentationml.presentation" }, + { ".pub", "application/vnd.ms-publisher" }, + { ".rar", "application/x-rar-compressed" }, + { ".rpmsg", "application/vnd.ms-outlook" }, + { ".rtf", "application/rtf" }, + { ".svg", "image/svg+xml" }, + { ".tar", "application/x-tar" }, + { ".tif", "image/tiff" }, + { ".tiff", "image/tiff" }, + { ".ttf", "font/ttf" }, + { ".txt", "text/plain" }, + { ".vsd", "application/vnd.visio" }, + { ".wav", "audio/wav" }, + { ".weba", "audio/webm" }, + { ".webm", "video/webm" }, + { ".webp", "image/webp" }, + { ".wma", "audio/x-ms-wma" }, + { ".wmv", "video/x-ms-wmv" }, + { ".woff", "font/woff" }, + { ".woff2", "font/woff2" }, + { ".xls", "application/vnd.ms-excel" }, + { ".xlsb", "application/vnd.ms-excel.sheet.binary.macroEnabled.12" }, + { ".xlsm", "application/vnd.ms-excel.sheet.macroEnabled.12" }, + { ".xlsx", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" }, + { ".xml", "application/xml" }, + { ".zip", "application/zip" } + }; + + private readonly AzureEmailOptions _providerOptions; + private readonly IEmailAddressValidator _emailAddressValidator; + private readonly ILogger _logger; + + protected readonly IStringLocalizer S; + + public AzureEmailProviderBase( + AzureEmailOptions options, + IEmailAddressValidator emailAddressValidator, + ILogger logger, + IStringLocalizer stringLocalizer) + { + _providerOptions = options; + _emailAddressValidator = emailAddressValidator; + _logger = logger; + S = stringLocalizer; + } + + public abstract LocalizedString DisplayName { get; } + + public virtual async Task SendAsync(MailMessage message) + { + ArgumentNullException.ThrowIfNull(message); + + if (!_providerOptions.IsEnabled) + { + return EmailResult.FailedResult(S["The Azure Email Provider is disabled."]); + } + + var senderAddress = string.IsNullOrWhiteSpace(message.From) + ? _providerOptions.DefaultSender + : message.From; + + _logger.LogDebug("Attempting to send email to {Email}.", message.To); + + if (!string.IsNullOrWhiteSpace(senderAddress)) + { + if (!_emailAddressValidator.Validate(senderAddress)) + { + return EmailResult.FailedResult(nameof(message.From), S["Invalid email address for the sender: '{0}'.", senderAddress]); + } + + message.From = senderAddress; + } + + var errors = new Dictionary>(); + var emailMessage = FromMailMessage(message, errors); + + if (errors.Count > 0) + { + return EmailResult.FailedResult(errors); + } + + try + { + var client = new EmailClient(_providerOptions.ConnectionString); + var emailResult = await client.SendAsync(WaitUntil.Completed, emailMessage); + + if (emailResult.HasValue) + { + return EmailResult.SuccessResult; + } + + return EmailResult.FailedResult(string.Empty, S["An error occurred while sending an email."]); + } + catch (Exception ex) + { + _logger.LogError(ex, "An error occurred while sending an email using the Azure Email Provider."); + + // IMPORTANT, do not expose ex.Message as it could contain the connection string in a raw format! + return EmailResult.FailedResult(string.Empty, S["An error occurred while sending an email."]); + } + } + + private EmailMessage FromMailMessage(MailMessage message, Dictionary> errors) + { + var recipients = message.GetRecipients(); + + List toRecipients = null; + if (recipients.To.Count > 0) + { + toRecipients = [.. recipients.To.Select(r => new EmailAddress(r))]; + } + + List ccRecipients = null; + if (recipients.Cc.Count > 0) + { + ccRecipients = [.. recipients.Cc.Select(r => new EmailAddress(r))]; + } + + List bccRecipients = null; + if (recipients.Bcc.Count > 0) + { + bccRecipients = [.. recipients.Bcc.Select(r => new EmailAddress(r))]; + } + + var content = new EmailContent(message.Subject); + if (message.IsHtmlBody) + { + content.Html = message.Body; + } + else + { + content.PlainText = message.Body; + } + + var emailMessage = new EmailMessage( + message.From, + new EmailRecipients(toRecipients, ccRecipients, bccRecipients), + content); + + foreach (var address in message.GetReplyTo()) + { + emailMessage.ReplyTo.Add(new EmailAddress(address)); + } + + foreach (var attachment in message.Attachments) + { + if (attachment.Stream == null) + { + continue; + } + var extension = Path.GetExtension(attachment.Filename); + + if (_allowedMimeTypes.TryGetValue(extension, out var contentType)) + { + var data = new byte[attachment.Stream.Length]; + + attachment.Stream.Read(data, 0, (int)attachment.Stream.Length); + + emailMessage.Attachments.Add(new EmailAttachment(attachment.Filename, contentType, new BinaryData(data))); + } + else + { + errors.TryAdd(nameof(message.Attachments), []); + + errors[nameof(message.Attachments)].Add(S["Unable to attach the file named '{0}' since its type is not supported.", attachment.Filename]); + + _logger.LogWarning("The MIME type for the attachment '{attachment}' is not supported.", attachment.Filename); + } + } + + return emailMessage; + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailProviderOptionsConfigurations.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailProviderOptionsConfigurations.cs new file mode 100644 index 00000000000..e37faa1fe9b --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/AzureEmailProviderOptionsConfigurations.cs @@ -0,0 +1,50 @@ +using Microsoft.Extensions.Options; +using OrchardCore.Email.Azure.Models; +using OrchardCore.Email.Core.Services; + +namespace OrchardCore.Email.Azure.Services; + +public class AzureEmailProviderOptionsConfigurations : IConfigureOptions +{ + private readonly AzureEmailOptions _azureOptions; + private readonly DefaultAzureEmailOptions _defaultAzureOptions; + + public AzureEmailProviderOptionsConfigurations( + IOptions azureOptions, + IOptions defaultAzureOptions) + { + _azureOptions = azureOptions.Value; + _defaultAzureOptions = defaultAzureOptions.Value; + } + + public void Configure(EmailProviderOptions options) + { + ConfigureTenantProvider(options); + + if (_defaultAzureOptions.IsEnabled) + { + // Only configure the default provider, if settings are provided by the configuration provider. + ConfigureDefaultProvider(options); + } + } + + private void ConfigureTenantProvider(EmailProviderOptions options) + { + var typeOptions = new EmailProviderTypeOptions(typeof(AzureEmailProvider)) + { + IsEnabled = _azureOptions.IsEnabled, + }; + + options.TryAddProvider(AzureEmailProvider.TechnicalName, typeOptions); + } + + private static void ConfigureDefaultProvider(EmailProviderOptions options) + { + var typeOptions = new EmailProviderTypeOptions(typeof(DefaultAzureEmailProvider)) + { + IsEnabled = true, + }; + + options.TryAddProvider(DefaultAzureEmailProvider.TechnicalName, typeOptions); + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/DefaultAzureEmailProvider.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/DefaultAzureEmailProvider.cs new file mode 100644 index 00000000000..01514660f35 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Services/DefaultAzureEmailProvider.cs @@ -0,0 +1,22 @@ +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Logging; +using Microsoft.Extensions.Options; +using OrchardCore.Email.Azure.Models; + +namespace OrchardCore.Email.Azure.Services; + +public class DefaultAzureEmailProvider : AzureEmailProviderBase +{ + public const string TechnicalName = "DefaultAzure"; + + public DefaultAzureEmailProvider( + IOptions options, + IEmailAddressValidator emailAddressValidator, + ILogger logger, + IStringLocalizer stringLocalizer) + : base(options.Value, emailAddressValidator, logger, stringLocalizer) + { + } + + public override LocalizedString DisplayName => S["Default Azure Communication Service"]; +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Startup.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Startup.cs new file mode 100644 index 00000000000..0d523fbea53 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Startup.cs @@ -0,0 +1,38 @@ +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.DependencyInjection; +using Microsoft.Extensions.Options; +using OrchardCore.Azure.Email.Drivers; +using OrchardCore.DisplayManagement.Handlers; +using OrchardCore.Email.Azure.Models; +using OrchardCore.Email.Azure.Services; +using OrchardCore.Email.Core; +using OrchardCore.Email.Services; +using OrchardCore.Environment.Shell.Configuration; +using OrchardCore.Settings; + +namespace OrchardCore.Email.Azure; + +public class Startup +{ + private readonly IShellConfiguration _shellConfiguration; + + public Startup(IShellConfiguration shellConfiguration) + { + _shellConfiguration = shellConfiguration; + } + + public void ConfigureServices(IServiceCollection services) + { + services.AddTransient, AzureEmailOptionsConfiguration>(); + + services.AddEmailProviderOptionsConfiguration() + .AddScoped, AzureEmailSettingsDisplayDriver>(); + + services.Configure(options => + { + _shellConfiguration.GetSection("OrchardCore_Email_Azure").Bind(options); + + options.IsEnabled = options.ConfigurationExists(); + }); + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/ViewModels/AzureEmailSettingsViewModel.cs b/src/OrchardCore.Modules/OrchardCore.Email.Azure/ViewModels/AzureEmailSettingsViewModel.cs new file mode 100644 index 00000000000..55379436fb7 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/ViewModels/AzureEmailSettingsViewModel.cs @@ -0,0 +1,16 @@ +using Microsoft.AspNetCore.Mvc.ModelBinding; + +namespace OrchardCore.Email.Azure.ViewModels; + +public class AzureEmailSettingsViewModel +{ + public bool IsEnabled { get; set; } + + [EmailAddress] + public string DefaultSender { get; set; } + + public string ConnectionString { get; set; } + + [BindNever] + public bool HasConnectionString { get; set; } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Views/AzureEmailSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Views/AzureEmailSettings.Edit.cshtml new file mode 100644 index 00000000000..d746bb35c6a --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Views/AzureEmailSettings.Edit.cshtml @@ -0,0 +1,28 @@ +@using Microsoft.AspNetCore.Mvc.Localization +@using OrchardCore.Email.Azure.ViewModels + +@model AzureEmailSettingsViewModel + +
+
+ + +
+
+ +
+ +
+ + + + @T["The default email address to use as a sender, unless the email sender is set."] +
+ +
+ + + +
+ +
diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Azure/Views/_ViewImports.cshtml b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Views/_ViewImports.cshtml new file mode 100644 index 00000000000..252fd654bb8 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Azure/Views/_ViewImports.cshtml @@ -0,0 +1,5 @@ +@inherits OrchardCore.DisplayManagement.Razor.RazorPage + +@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers +@addTagHelper *, OrchardCore.DisplayManagement +@addTagHelper *, OrchardCore.ResourceManagement diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Drivers/SmtpSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Drivers/SmtpSettingsDisplayDriver.cs new file mode 100644 index 00000000000..decc75f2aaa --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Drivers/SmtpSettingsDisplayDriver.cs @@ -0,0 +1,211 @@ +using System; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.DataProtection; +using Microsoft.AspNetCore.Http; +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Options; +using OrchardCore.DisplayManagement.Entities; +using OrchardCore.DisplayManagement.Handlers; +using OrchardCore.DisplayManagement.ModelBinding; +using OrchardCore.DisplayManagement.Views; +using OrchardCore.Email.Core; +using OrchardCore.Email.Smtp.Services; +using OrchardCore.Email.Smtp.ViewModels; +using OrchardCore.Entities; +using OrchardCore.Environment.Shell; +using OrchardCore.Modules; +using OrchardCore.Mvc.ModelBinding; +using OrchardCore.Settings; + +namespace OrchardCore.Email.Smtp.Drivers; + +public class SmtpSettingsDisplayDriver : SectionDisplayDriver +{ + [Obsolete("This property should no longer be used. Instead use EmailSettings.GroupId")] + public const string GroupId = EmailSettings.GroupId; + + private readonly IDataProtectionProvider _dataProtectionProvider; + private readonly IShellHost _shellHost; + private readonly ShellSettings _shellSettings; + private readonly IHttpContextAccessor _httpContextAccessor; + private readonly SmtpOptions _smtpOptions; + private readonly IAuthorizationService _authorizationService; + private readonly IEmailAddressValidator _emailValidator; + + protected readonly IStringLocalizer S; + + public SmtpSettingsDisplayDriver( + IDataProtectionProvider dataProtectionProvider, + IShellHost shellHost, + ShellSettings shellSettings, + IHttpContextAccessor httpContextAccessor, + IOptions options, + IAuthorizationService authorizationService, + IEmailAddressValidator emailAddressValidator, + IStringLocalizer stringLocalizer) + { + _dataProtectionProvider = dataProtectionProvider; + _shellHost = shellHost; + _shellSettings = shellSettings; + _httpContextAccessor = httpContextAccessor; + _smtpOptions = options.Value; + _authorizationService = authorizationService; + _emailValidator = emailAddressValidator; + S = stringLocalizer; + } + + public override async Task EditAsync(SmtpSettings settings, BuildEditorContext context) + { + if (!context.GroupId.EqualsOrdinalIgnoreCase(EmailSettings.GroupId)) + { + return null; + } + + if (!await _authorizationService.AuthorizeAsync(_httpContextAccessor.HttpContext?.User, Permissions.ManageEmailSettings)) + { + return null; + } + + return Initialize("SmtpSettings_Edit", model => + { + // For backward compatibility with instances before the SMTP provider was factored out of + // OrchardCore.Email, if IsEnabled is null, we check to see if there's already valid configuration. + model.IsEnabled = settings.IsEnabled ?? _smtpOptions.ConfigurationExists(); + model.DefaultSender = settings.DefaultSender; + model.DeliveryMethod = settings.DeliveryMethod; + model.PickupDirectoryLocation = settings.PickupDirectoryLocation; + model.Host = settings.Host; + model.Port = settings.Port; + model.ProxyHost = settings.ProxyHost; + model.ProxyPort = settings.ProxyPort; + model.EncryptionMethod = settings.EncryptionMethod; + model.AutoSelectEncryption = settings.AutoSelectEncryption; + model.RequireCredentials = settings.RequireCredentials; + model.UseDefaultCredentials = settings.UseDefaultCredentials; + model.UserName = settings.UserName; + model.Password = settings.Password; + model.IgnoreInvalidSslCertificate = settings.IgnoreInvalidSslCertificate; + }).Location("Content:5#SMTP") + .OnGroup(EmailSettings.GroupId); + } + + public override async Task UpdateAsync(ISite site, SmtpSettings settings, IUpdateModel updater, BuildEditorContext context) + { + if (!context.GroupId.EqualsOrdinalIgnoreCase(EmailSettings.GroupId)) + { + return null; + } + + if (!await _authorizationService.AuthorizeAsync(_httpContextAccessor.HttpContext?.User, Permissions.ManageEmailSettings)) + { + return null; + } + + var model = new SmtpSettingsViewModel(); + + if (await context.Updater.TryUpdateModelAsync(model, Prefix)) + { + var emailSettings = site.As(); + + var hasChanges = model.IsEnabled != settings.IsEnabled; + + if (!model.IsEnabled) + { + if (hasChanges && emailSettings.DefaultProviderName == SmtpEmailProvider.TechnicalName) + { + emailSettings.DefaultProviderName = null; + + site.Put(emailSettings); + } + + settings.IsEnabled = false; + } + else + { + if (string.IsNullOrEmpty(model.DefaultSender)) + { + context.Updater.ModelState.AddModelError(Prefix, nameof(model.DefaultSender), S["The Default Sender is a required field."]); + } + else if (!_emailValidator.Validate(model.DefaultSender)) + { + context.Updater.ModelState.AddModelError(Prefix, nameof(model.DefaultSender), S["The Default Sender is invalid."]); + } + + if (model.DeliveryMethod == SmtpDeliveryMethod.Network + && string.IsNullOrWhiteSpace(model.Host)) + { + updater.ModelState.AddModelError(Prefix, nameof(model.Host), S["The {0} field is required.", "Host name"]); + } + else if (model.DeliveryMethod == SmtpDeliveryMethod.SpecifiedPickupDirectory + && string.IsNullOrWhiteSpace(model.PickupDirectoryLocation)) + { + updater.ModelState.AddModelError(Prefix, nameof(model.PickupDirectoryLocation), S["The {0} field is required.", "Pickup directory location"]); + } + + hasChanges |= model.DefaultSender != settings.DefaultSender; + hasChanges |= model.Host != settings.Host; + hasChanges |= model.Port != settings.Port; + hasChanges |= model.AutoSelectEncryption != settings.AutoSelectEncryption; + hasChanges |= model.RequireCredentials != settings.RequireCredentials; + hasChanges |= model.UseDefaultCredentials != settings.UseDefaultCredentials; + hasChanges |= model.EncryptionMethod != settings.EncryptionMethod; + hasChanges |= model.UserName != settings.UserName; + hasChanges |= model.ProxyHost != settings.ProxyHost; + hasChanges |= model.ProxyPort != settings.ProxyPort; + hasChanges |= model.IgnoreInvalidSslCertificate != settings.IgnoreInvalidSslCertificate; + hasChanges |= model.DeliveryMethod != settings.DeliveryMethod; + hasChanges |= model.PickupDirectoryLocation != settings.PickupDirectoryLocation; + + // Store the password when there is a new value. + if (!string.IsNullOrWhiteSpace(model.Password)) + { + // Encrypt the password. + var protector = _dataProtectionProvider.CreateProtector(SmtpOptionsConfiguration.ProtectorName); + + var protectedPassword = protector.Protect(model.Password); + + // Check if the password changed before setting the password. + hasChanges |= protectedPassword != settings.Password; + + settings.Password = protectedPassword; + } + + settings.IsEnabled = true; + settings.DefaultSender = model.DefaultSender; + settings.Host = model.Host; + settings.Port = model.Port; + settings.AutoSelectEncryption = model.AutoSelectEncryption; + settings.RequireCredentials = model.RequireCredentials; + settings.UseDefaultCredentials = model.UseDefaultCredentials; + settings.EncryptionMethod = model.EncryptionMethod; + settings.UserName = model.UserName; + settings.ProxyHost = model.ProxyHost; + settings.ProxyPort = model.ProxyPort; + settings.IgnoreInvalidSslCertificate = model.IgnoreInvalidSslCertificate; + settings.DeliveryMethod = model.DeliveryMethod; + settings.PickupDirectoryLocation = model.PickupDirectoryLocation; + } + + if (context.Updater.ModelState.IsValid) + { + if (settings.IsEnabled == true && string.IsNullOrEmpty(emailSettings.DefaultProviderName)) + { + // If we are enabling the only provider, set it as the default one. + emailSettings.DefaultProviderName = SmtpEmailProvider.TechnicalName; + site.Put(emailSettings); + + hasChanges = true; + } + + if (hasChanges) + { + // Release the tenant to apply the settings when something changed. + await _shellHost.ReleaseShellContextAsync(_shellSettings); + } + } + } + + return await EditAsync(settings, context); + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Extensions/ServiceCollectionExtensions.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Extensions/ServiceCollectionExtensions.cs new file mode 100644 index 00000000000..924fd935436 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Extensions/ServiceCollectionExtensions.cs @@ -0,0 +1,27 @@ +using System; +using Microsoft.Extensions.DependencyInjection; +using OrchardCore.Email.Core; +using OrchardCore.Email.Services; +using OrchardCore.Email.Smtp.Services; + +namespace OrchardCore.Email.Smtp.Extensions; + +public static class ServiceCollectionExtensions +{ + public static IServiceCollection AddSmtpEmailProvider(this IServiceCollection services) + { +#pragma warning disable CS0612 // Type or member is obsolete + services.AddSmtpService(); +#pragma warning restore CS0612 // Type or member is obsolete + + services.AddEmailProviderOptionsConfiguration(); + + return services; + } + + [Obsolete] + private static void AddSmtpService(this IServiceCollection services) + { + services.AddScoped(); + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Manifest.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Manifest.cs new file mode 100644 index 00000000000..976ca49365b --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Manifest.cs @@ -0,0 +1,14 @@ +using OrchardCore.Modules.Manifest; + +[assembly: Module( + Name = "SMTP Email Provider", + Author = ManifestConstants.OrchardCoreTeam, + Website = ManifestConstants.OrchardCoreWebsite, + Version = ManifestConstants.OrchardCoreVersion, + Description = "Provides an email service provider leveraging Simple Mail Transfer Protocol (SMTP).", + Dependencies = + [ + "OrchardCore.Email" + ], + Category = "Messaging" +)] diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/OrchardCore.Email.Smtp.csproj b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/OrchardCore.Email.Smtp.csproj new file mode 100644 index 00000000000..c80c6b4672c --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/OrchardCore.Email.Smtp.csproj @@ -0,0 +1,34 @@ + + + + true + + OrchardCore SMTP Email + + $(OCFrameworkDescription) + + Provides the configuration of email settings and a default email service utilizing Simple Mail Transfer Protocol (SMTP). + + $(PackageTags) OrchardCoreFramework + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/DefaultSmtpEmailProvider.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/DefaultSmtpEmailProvider.cs new file mode 100644 index 00000000000..92e9efb8d9f --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/DefaultSmtpEmailProvider.cs @@ -0,0 +1,21 @@ +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Logging; +using Microsoft.Extensions.Options; + +namespace OrchardCore.Email.Smtp.Services; + +public class DefaultSmtpEmailProvider : SmtpEmailProviderBase +{ + public const string TechnicalName = "DefaultSMTP"; + + public DefaultSmtpEmailProvider( + IOptions options, + IEmailAddressValidator emailAddressValidator, + ILogger logger, + IStringLocalizer stringLocalizer) + : base(options.Value, emailAddressValidator, logger, stringLocalizer) + { + } + + public override LocalizedString DisplayName => S["Simple Mail Transfer Protocol (Default SMTP)"]; +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpEmailProvider.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpEmailProvider.cs new file mode 100644 index 00000000000..835a17fa218 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpEmailProvider.cs @@ -0,0 +1,21 @@ +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Logging; +using Microsoft.Extensions.Options; + +namespace OrchardCore.Email.Smtp.Services; + +public class SmtpEmailProvider : SmtpEmailProviderBase +{ + public const string TechnicalName = "SMTP"; + + public SmtpEmailProvider( + IOptions options, + IEmailAddressValidator emailAddressValidator, + ILogger logger, + IStringLocalizer stringLocalizer) + : base(options.Value, emailAddressValidator, logger, stringLocalizer) + { + } + + public override LocalizedString DisplayName => S["Simple Mail Transfer Protocol (SMTP)"]; +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpEmailProviderBase.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpEmailProviderBase.cs new file mode 100644 index 00000000000..56cf283029a --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpEmailProviderBase.cs @@ -0,0 +1,222 @@ +using System; +using System.IO; +using System.Linq; +using System.Net.Security; +using System.Security.Cryptography.X509Certificates; +using System.Threading; +using System.Threading.Tasks; +using MailKit.Net.Proxy; +using MailKit.Net.Smtp; +using MailKit.Security; +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Logging; +using MimeKit; + +namespace OrchardCore.Email.Smtp.Services; + +public abstract class SmtpEmailProviderBase : IEmailProvider +{ + private const string EmailExtension = ".eml"; + + private readonly SmtpOptions _providerOptions; + private readonly IEmailAddressValidator _emailAddressValidator; + private readonly ILogger _logger; + + protected readonly IStringLocalizer S; + + public SmtpEmailProviderBase( + SmtpOptions options, + IEmailAddressValidator emailAddressValidator, + ILogger logger, + IStringLocalizer stringLocalizer) + { + _providerOptions = options; + _emailAddressValidator = emailAddressValidator; + _logger = logger; + S = stringLocalizer; + } + + public abstract LocalizedString DisplayName { get; } + + public virtual async Task SendAsync(MailMessage message) + { + ArgumentNullException.ThrowIfNull(message); + + if (!_providerOptions.IsEnabled) + { + return EmailResult.FailedResult(S["The SMTP Email Provider is disabled."]); + } + + var senderAddress = string.IsNullOrWhiteSpace(message.From) + ? _providerOptions.DefaultSender + : message.From; + + _logger.LogDebug("Attempting to send email to {Email}.", message.To); + + // Set the MailMessage.From, to avoid the confusion between DefaultSender (Author) and submitter (Sender). + if (!string.IsNullOrWhiteSpace(senderAddress)) + { + if (!_emailAddressValidator.Validate(senderAddress)) + { + return EmailResult.FailedResult(nameof(message.From), S["Invalid email address for the sender: '{0}'.", senderAddress]); + } + + message.From = senderAddress; + } + + var mimeMessage = GetMimeMessage(message); + + try + { + if (_providerOptions.DeliveryMethod == SmtpDeliveryMethod.Network) + { + var response = await SendOnlineMessageAsync(mimeMessage); + + return EmailResult.GetSuccessResult(response); + } + + if (_providerOptions.DeliveryMethod == SmtpDeliveryMethod.SpecifiedPickupDirectory) + { + await SendOfflineMessageAsync(mimeMessage, _providerOptions.PickupDirectoryLocation); + + return EmailResult.SuccessResult; + } + + throw new NotSupportedException($"The '{_providerOptions.DeliveryMethod}' delivery method is not supported."); + } + catch (Exception ex) + { + return EmailResult.FailedResult([S["An error occurred while sending an email: '{0}'", ex.Message]]); + } + } + + private MimeMessage GetMimeMessage(MailMessage message) + { + var mimeMessage = new MimeMessage(); + var submitterAddress = string.IsNullOrWhiteSpace(message.Sender) + ? _providerOptions.DefaultSender + : message.Sender; + + if (!string.IsNullOrEmpty(submitterAddress)) + { + mimeMessage.Sender = MailboxAddress.Parse(submitterAddress); + } + + mimeMessage.From.AddRange(message.GetSender().Select(MailboxAddress.Parse)); + + var recipients = message.GetRecipients(); + mimeMessage.To.AddRange(recipients.To.Select(MailboxAddress.Parse)); + mimeMessage.Cc.AddRange(recipients.Cc.Select(MailboxAddress.Parse)); + mimeMessage.Bcc.AddRange(recipients.Bcc.Select(MailboxAddress.Parse)); + + mimeMessage.ReplyTo.AddRange(message.GetReplyTo().Select(MailboxAddress.Parse)); + + mimeMessage.Subject = message.Subject; + + var body = new BodyBuilder(); + + if (message.IsHtmlBody) + { + body.HtmlBody = message.Body; + } + else + { + body.TextBody = message.Body; + } + + foreach (var attachment in message.Attachments) + { + // Stream must not be null, otherwise it would try to get the filesystem path + if (attachment.Stream != null) + { + body.Attachments.Add(attachment.Filename, attachment.Stream); + } + } + + mimeMessage.Body = body.ToMessageBody(); + + return mimeMessage; + } + + private async Task SendOnlineMessageAsync(MimeMessage message) + { + var secureSocketOptions = SecureSocketOptions.Auto; + + if (!_providerOptions.AutoSelectEncryption) + { + secureSocketOptions = _providerOptions.EncryptionMethod switch + { + SmtpEncryptionMethod.None => SecureSocketOptions.None, + SmtpEncryptionMethod.SslTls => SecureSocketOptions.SslOnConnect, + SmtpEncryptionMethod.StartTls => SecureSocketOptions.StartTls, + _ => SecureSocketOptions.Auto, + }; + } + + using var client = new SmtpClient(); + + client.ServerCertificateValidationCallback = CertificateValidationCallback; + + await client.ConnectAsync(_providerOptions.Host, _providerOptions.Port, secureSocketOptions); + + if (_providerOptions.RequireCredentials) + { + if (_providerOptions.UseDefaultCredentials) + { + // There's no notion of 'UseDefaultCredentials' in MailKit, so empty credentials is passed in. + await client.AuthenticateAsync(string.Empty, string.Empty); + } + else if (!string.IsNullOrWhiteSpace(_providerOptions.UserName)) + { + await client.AuthenticateAsync(_providerOptions.UserName, _providerOptions.Password); + } + } + + if (!string.IsNullOrEmpty(_providerOptions.ProxyHost)) + { + client.ProxyClient = new Socks5Client(_providerOptions.ProxyHost, _providerOptions.ProxyPort); + } + + var response = await client.SendAsync(message); + + await client.DisconnectAsync(true); + + return response; + } + + private static Task SendOfflineMessageAsync(MimeMessage message, string pickupDirectory) + { + var mailPath = Path.Combine(pickupDirectory, Guid.NewGuid().ToString() + EmailExtension); + + return message.WriteToAsync(mailPath, CancellationToken.None); + } + + private bool CertificateValidationCallback(object sender, X509Certificate certificate, X509Chain chain, SslPolicyErrors sslPolicyErrors) + { + if (sslPolicyErrors == SslPolicyErrors.None) + { + return true; + } + + const string logErrorMessage = "SMTP Server's certificate {CertificateSubject} issued by {CertificateIssuer} " + + "with thumbprint {CertificateThumbprint} and expiration date {CertificateExpirationDate} " + + "is considered invalid with {SslPolicyErrors} policy errors"; + + _logger.LogError(logErrorMessage, + certificate.Subject, + certificate.Issuer, + certificate.GetCertHashString(), + certificate.GetExpirationDateString(), + sslPolicyErrors); + + if (sslPolicyErrors.HasFlag(SslPolicyErrors.RemoteCertificateChainErrors) && chain?.ChainStatus != null) + { + foreach (var chainStatus in chain.ChainStatus) + { + _logger.LogError("Status: {Status} - {StatusInformation}", chainStatus.Status, chainStatus.StatusInformation); + } + } + + return _providerOptions.IgnoreInvalidSslCertificate; + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpOptionsConfiguration.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpOptionsConfiguration.cs new file mode 100644 index 00000000000..0ac92e3870f --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpOptionsConfiguration.cs @@ -0,0 +1,62 @@ +using Microsoft.AspNetCore.DataProtection; +using Microsoft.Extensions.Logging; +using Microsoft.Extensions.Options; +using OrchardCore.Settings; + +namespace OrchardCore.Email.Smtp.Services; + +public class SmtpOptionsConfiguration : IConfigureOptions +{ + public const string ProtectorName = "SmtpSettingsConfiguration"; + + private readonly ISiteService _siteService; + private readonly IDataProtectionProvider _dataProtectionProvider; + private readonly ILogger _logger; + + public SmtpOptionsConfiguration( + ISiteService siteService, + IDataProtectionProvider dataProtectionProvider, + ILogger logger) + { + _siteService = siteService; + _dataProtectionProvider = dataProtectionProvider; + _logger = logger; + } + + public void Configure(SmtpOptions options) + { + var settings = _siteService.GetSiteSettingsAsync() + .GetAwaiter().GetResult() + .As(); + + options.DefaultSender = settings.DefaultSender; + options.DeliveryMethod = settings.DeliveryMethod; + options.PickupDirectoryLocation = settings.PickupDirectoryLocation; + options.Host = settings.Host; + options.Port = settings.Port; + options.ProxyHost = settings.ProxyHost; + options.ProxyPort = settings.ProxyPort; + options.EncryptionMethod = settings.EncryptionMethod; + options.AutoSelectEncryption = settings.AutoSelectEncryption; + options.RequireCredentials = settings.RequireCredentials; + options.UseDefaultCredentials = settings.UseDefaultCredentials; + options.UserName = settings.UserName; + options.Password = settings.Password; + options.IgnoreInvalidSslCertificate = settings.IgnoreInvalidSslCertificate; + + if (!string.IsNullOrWhiteSpace(settings.Password)) + { + try + { + var protector = _dataProtectionProvider.CreateProtector(ProtectorName); + options.Password = protector.Unprotect(settings.Password); + } + catch + { + _logger.LogError("The Smtp password could not be decrypted. It may have been encrypted using a different key."); + } + } + + options.IsEnabled = settings.IsEnabled ?? options.ConfigurationExists(); + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpProviderOptionsConfigurations.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpProviderOptionsConfigurations.cs new file mode 100644 index 00000000000..35289b51373 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpProviderOptionsConfigurations.cs @@ -0,0 +1,48 @@ +using Microsoft.Extensions.Options; +using OrchardCore.Email.Core.Services; + +namespace OrchardCore.Email.Smtp.Services; + +public class SmtpProviderOptionsConfigurations : IConfigureOptions +{ + private readonly SmtpOptions _smtpOptions; + private readonly DefaultSmtpOptions _defaultSmtpOptions; + + public SmtpProviderOptionsConfigurations( + IOptions smtpOptions, + IOptions defaultSmtpOptions) + { + _smtpOptions = smtpOptions.Value; + _defaultSmtpOptions = defaultSmtpOptions.Value; + } + + public void Configure(EmailProviderOptions options) + { + ConfigureTenantProvider(options); + + if (_defaultSmtpOptions.IsEnabled) + { + ConfigureDefaultProvider(options); + } + } + + private void ConfigureTenantProvider(EmailProviderOptions options) + { + var typeOptions = new EmailProviderTypeOptions(typeof(SmtpEmailProvider)) + { + IsEnabled = _smtpOptions.IsEnabled, + }; + + options.TryAddProvider(SmtpEmailProvider.TechnicalName, typeOptions); + } + + private static void ConfigureDefaultProvider(EmailProviderOptions options) + { + var typeOptions = new EmailProviderTypeOptions(typeof(DefaultSmtpEmailProvider)) + { + IsEnabled = true, + }; + + options.TryAddProvider(DefaultSmtpEmailProvider.TechnicalName, typeOptions); + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpService.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpService.cs new file mode 100644 index 00000000000..0d6993f9f06 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Services/SmtpService.cs @@ -0,0 +1,64 @@ +using System; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Options; +using OrchardCore.Email.Core.Services; +using OrchardCore.Email.Smtp.Services; +using OrchardCore.Environment.Shell.Builders; + +namespace OrchardCore.Email.Services; + +[Obsolete] +public class SmtpService : ISmtpService +{ + private readonly EmailProviderOptions _emailProviderOptions; + private readonly IServiceProvider _serviceProvider; + + protected readonly IStringLocalizer S; + + public SmtpService( + IOptions emailProviderOptions, + IServiceProvider serviceProvider, + IStringLocalizer stringLocalizer) + { + _emailProviderOptions = emailProviderOptions.Value; + _serviceProvider = serviceProvider; + S = stringLocalizer; + } + + public async Task SendAsync(MailMessage message) + { + var provider = GetSmtpProvider(); + + if (provider == null) + { + return SmtpResult.Failed([S["Unable to find any SMTP providers."]]); + } + + var result = await provider.SendAsync(message); + + if (result.Succeeded) + { + return SmtpResult.Success; + } + + return SmtpResult.Failed(result.Errors.SelectMany(x => x.Value).ToArray()); + } + + private IEmailProvider GetSmtpProvider() + { + var type = _emailProviderOptions.Providers.Where(x => x.Key.Contains("SMTP")) + .OrderBy(entry => !entry.Value.IsEnabled ? 0 : 1) + .ThenBy(entry => entry.Key != DefaultSmtpEmailProvider.TechnicalName ? 0 : 1) + .Select(x => x.Value) + .LastOrDefault()?.Type; + + if (type is not null) + { + return _serviceProvider.CreateInstance(type); + } + + return null; + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Startup.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Startup.cs new file mode 100644 index 00000000000..4a482379b59 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Startup.cs @@ -0,0 +1,38 @@ +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.DependencyInjection; +using Microsoft.Extensions.Options; +using OrchardCore.DisplayManagement.Handlers; +using OrchardCore.Email.Smtp.Drivers; +using OrchardCore.Email.Smtp.Extensions; +using OrchardCore.Email.Smtp.Services; +using OrchardCore.Environment.Shell.Configuration; +using OrchardCore.Settings; + +namespace OrchardCore.Email.Smtp; + +public class Startup +{ + private readonly IShellConfiguration _shellConfiguration; + + public Startup(IShellConfiguration shellConfiguration) + { + _shellConfiguration = shellConfiguration; + } + + public void ConfigureServices(IServiceCollection services) + { + services.AddSmtpEmailProvider() + .AddScoped, SmtpSettingsDisplayDriver>() + .AddTransient, SmtpOptionsConfiguration>(); + + services.Configure(options => + { + // To ensure backward compatibility, we will try to associate SMTP settings from multiple sections. + // The 'OrchardCore_Email' section will be phased out in an upcoming release. + _shellConfiguration.GetSection("OrchardCore_Email").Bind(options); + _shellConfiguration.GetSection("OrchardCore_Email_Smtp").Bind(options); + + options.IsEnabled = options.ConfigurationExists(); + }); + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/ViewModels/SmtpSettingsViewModel.cs b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/ViewModels/SmtpSettingsViewModel.cs new file mode 100644 index 00000000000..151a425911a --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/ViewModels/SmtpSettingsViewModel.cs @@ -0,0 +1,38 @@ +using System; +using System.ComponentModel.DataAnnotations; + +namespace OrchardCore.Email.Smtp.ViewModels; + +public class SmtpSettingsViewModel +{ + public bool IsEnabled { get; set; } + + public string DefaultSender { get; set; } + + public string Host { get; set; } + + [Range(0, 65535)] + public int Port { get; set; } = 25; + + public bool AutoSelectEncryption { get; set; } + + public bool RequireCredentials { get; set; } + + public bool UseDefaultCredentials { get; set; } + + public SmtpEncryptionMethod EncryptionMethod { get; set; } + + public string UserName { get; set; } + + public string Password { get; set; } + + public string ProxyHost { get; set; } + + public int ProxyPort { get; set; } + + public bool IgnoreInvalidSslCertificate { get; set; } + + public SmtpDeliveryMethod DeliveryMethod { get; set; } + + public string PickupDirectoryLocation { get; set; } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Views/SmtpSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Views/SmtpSettings.Edit.cshtml new file mode 100644 index 00000000000..190919f03c5 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Views/SmtpSettings.Edit.cshtml @@ -0,0 +1,196 @@ +@using OrchardCore.Email.Smtp.ViewModels +@using OrchardCore.Email + +@model SmtpSettingsViewModel + +
+
+ + +
+
+ +
+
+ + + + @T["The default email address to use as a sender, unless the email sender is set."] +
+ +
+ + + + @T["The delivery method used when sending email. Use Network in production. The other options can be useful when developing and testing."] +
+ +
+
+ +
+
+

@T["Network delivery options"]

+ +
+
+
+
+ + + + @T["The SMTP server domain, e.g. smtp.mailprovider.com."] +
+
+
+
+
+
+ + + + @T["The SMTP server port, usually 25."] +
+
+
+
+ +
+
+
+
+ + + + @T["The proxy server is optional."] +
+
+
+
+
+
+ + + + @T["The proxy port is optional."] +
+
+
+
+ +
+ + + + @T["The encryption method used when connecting to mail server."] +
+ +
+ + + + @T["Check to let the system select the encryption method based on port."] +
+ +
+ + + +
+ +
+
+ + + + @T["When this option is selected, the application pool or host-process identity is used to authenticate with the mail server."] +
+ +
+
+ + + + @T["The username for authentication."] +
+ +
+ + + + @T["The password for authentication."] +
+
+
+
+
+
+ +
+
+
+

@T["Specified pickup directory delivery options"]

+ +
+ + + + @T[@"E.g. C:\Path\To\This\Site\PickedUpEmail to place emails in a PickedUpEmail directory on the C drive."] +
+
+
+
+
+ +
+
+ + + @T["Ignores SSL certificate check if it's invalid."] +
+
+
+ + diff --git a/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Views/_ViewImports.cshtml b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Views/_ViewImports.cshtml new file mode 100644 index 00000000000..252fd654bb8 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email.Smtp/Views/_ViewImports.cshtml @@ -0,0 +1,5 @@ +@inherits OrchardCore.DisplayManagement.Razor.RazorPage + +@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers +@addTagHelper *, OrchardCore.DisplayManagement +@addTagHelper *, OrchardCore.ResourceManagement diff --git a/src/OrchardCore.Modules/OrchardCore.Email/AdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.Email/AdminMenu.cs index f4db7cac39a..bedb394ef0b 100644 --- a/src/OrchardCore.Modules/OrchardCore.Email/AdminMenu.cs +++ b/src/OrchardCore.Modules/OrchardCore.Email/AdminMenu.cs @@ -1,7 +1,9 @@ using System.Threading.Tasks; using Microsoft.AspNetCore.Routing; using Microsoft.Extensions.Localization; -using OrchardCore.Email.Drivers; +using OrchardCore.Email.Controllers; +using OrchardCore.Email.Core; +using OrchardCore.Mvc.Core.Utilities; using OrchardCore.Navigation; namespace OrchardCore.Email @@ -11,7 +13,7 @@ public class AdminMenu : INavigationProvider private static readonly RouteValueDictionary _routeValues = new() { { "area", "OrchardCore.Settings" }, - { "groupId", SmtpSettingsDisplayDriver.GroupId }, + { "groupId", EmailSettings.GroupId }, }; protected readonly IStringLocalizer S; @@ -32,11 +34,19 @@ public Task BuildNavigationAsync(string name, NavigationBuilder builder) .Add(S["Configuration"], configuration => configuration .Add(S["Settings"], settings => settings .Add(S["Email"], S["Email"].PrefixPosition(), entry => entry - .AddClass("email").Id("email") + .AddClass("email") + .Id("email") .Action("Index", "Admin", _routeValues) .Permission(Permissions.ManageEmailSettings) .LocalNav() ) + .Add(S["Email Test"], S["Email Test"].PrefixPosition(), entry => entry + .AddClass("emailtest") + .Id("emailtest") + .Action(nameof(AdminController.Test), typeof(AdminController).ControllerName(), "OrchardCore.Email") + .Permission(Permissions.ManageEmailSettings) + .LocalNav() + ) ) ); diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Controllers/AdminController.cs b/src/OrchardCore.Modules/OrchardCore.Email/Controllers/AdminController.cs index edc0dae370f..51e4120a113 100644 --- a/src/OrchardCore.Modules/OrchardCore.Email/Controllers/AdminController.cs +++ b/src/OrchardCore.Modules/OrchardCore.Email/Controllers/AdminController.cs @@ -1,103 +1,161 @@ +using System; +using System.Collections.Generic; +using System.Linq; using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Microsoft.AspNetCore.Mvc.Localization; +using Microsoft.AspNetCore.Mvc.Rendering; +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Options; using OrchardCore.Admin; using OrchardCore.DisplayManagement.Notify; -using OrchardCore.Email.Drivers; +using OrchardCore.Email.Core; +using OrchardCore.Email.Core.Services; using OrchardCore.Email.ViewModels; -namespace OrchardCore.Email.Controllers +namespace OrchardCore.Email.Controllers; + +public class AdminController : Controller { - [Admin("Email/{action}/{id?}", "Email{action}")] - public class AdminController : Controller + private readonly IAuthorizationService _authorizationService; + private readonly INotifier _notifier; + private readonly EmailOptions _emailOptions; + private readonly EmailProviderOptions _providerOptions; + private readonly IEmailService _emailService; + private readonly IEmailProviderResolver _emailProviderResolver; + + protected readonly IHtmlLocalizer H; + protected readonly IStringLocalizer S; + + public AdminController( + IAuthorizationService authorizationService, + INotifier notifier, + IOptions providerOptions, + IOptions emailOptions, + IEmailService emailService, + IEmailProviderResolver emailProviderResolver, + IHtmlLocalizer htmlLocalizer, + IStringLocalizer stringLocalizer) { - private readonly IAuthorizationService _authorizationService; - private readonly INotifier _notifier; - private readonly ISmtpService _smtpService; - protected readonly IHtmlLocalizer H; - - public AdminController( - IHtmlLocalizer h, - IAuthorizationService authorizationService, - INotifier notifier, - ISmtpService smtpService) + _authorizationService = authorizationService; + _notifier = notifier; + _emailOptions = emailOptions.Value; + _providerOptions = providerOptions.Value; + _emailService = emailService; + _emailProviderResolver = emailProviderResolver; + H = htmlLocalizer; + S = stringLocalizer; + } + + [Admin("Email/Test", "EmailTest")] + public async Task Test() + { + if (!await _authorizationService.AuthorizeAsync(User, Permissions.ManageEmailSettings)) { - H = h; - _authorizationService = authorizationService; - _notifier = notifier; - _smtpService = smtpService; + return Forbid(); } - [HttpGet] - public async Task Index() + var model = new EmailTestViewModel() { - if (!await _authorizationService.AuthorizeAsync(User, Permissions.ManageEmailSettings)) - { - return Forbid(); - } + Provider = _emailOptions.DefaultProviderName, + }; + + PopulateModel(model); + + return View(model); + } - return View(); + [HttpPost] + public async Task Test(EmailTestViewModel model) + { + if (!await _authorizationService.AuthorizeAsync(User, Permissions.ManageEmailSettings)) + { + return Forbid(); } - [HttpPost, ActionName(nameof(Index))] - public async Task IndexPost(SmtpSettingsViewModel model) + if (ModelState.IsValid) { - if (!await _authorizationService.AuthorizeAsync(User, Permissions.ManageEmailSettings)) - { - return Forbid(); - } + var message = GetMessage(model); - if (ModelState.IsValid) + try { - var message = CreateMessageFromViewModel(model); + var result = await _emailService.SendAsync(message, model.Provider); + + if (result.Succeeded) + { + await _notifier.SuccessAsync(H["Message sent successfully."]); - var result = await _smtpService.SendAsync(message); + return RedirectToAction(nameof(Test)); + } - if (!result.Succeeded) + foreach (var error in result.Errors) { - foreach (var error in result.Errors) + foreach (var errorMessage in error.Value) { - ModelState.AddModelError("*", error.ToString()); + ModelState.AddModelError(error.Key, errorMessage); } } - else - { - await _notifier.SuccessAsync(H["Message sent successfully."]); - - return Redirect(Url.Action("Index", "Admin", new { area = "OrchardCore.Settings", groupId = SmtpSettingsDisplayDriver.GroupId })); - } } + catch (InvalidEmailProviderException) + { + ModelState.AddModelError(string.Empty, S["The selected provider is invalid or no longer enabled."]); + } + catch (Exception) + { + ModelState.AddModelError(string.Empty, S["Unable to send the message using the selected provider."]); + } + } + + PopulateModel(model); + + return View(model); + } - return View(model); + private static MailMessage GetMessage(EmailTestViewModel testSettings) + { + var message = new MailMessage + { + To = testSettings.To, + Bcc = testSettings.Bcc, + Cc = testSettings.Cc, + ReplyTo = testSettings.ReplyTo + }; + + if (!string.IsNullOrWhiteSpace(testSettings.From)) + { + message.Sender = testSettings.From; } - private static MailMessage CreateMessageFromViewModel(SmtpSettingsViewModel testSettings) + if (!string.IsNullOrWhiteSpace(testSettings.Subject)) { - var message = new MailMessage - { - To = testSettings.To, - Bcc = testSettings.Bcc, - Cc = testSettings.Cc, - ReplyTo = testSettings.ReplyTo - }; + message.Subject = testSettings.Subject; + } - if (!string.IsNullOrWhiteSpace(testSettings.Sender)) - { - message.Sender = testSettings.Sender; - } + if (!string.IsNullOrWhiteSpace(testSettings.Body)) + { + message.Body = testSettings.Body; + } - if (!string.IsNullOrWhiteSpace(testSettings.Subject)) - { - message.Subject = testSettings.Subject; - } + return message; + } + + private async void PopulateModel(EmailTestViewModel model) + { + var options = new List(); - if (!string.IsNullOrWhiteSpace(testSettings.Body)) + foreach (var entry in _providerOptions.Providers) + { + if (!entry.Value.IsEnabled) { - message.Body = testSettings.Body; + continue; } - return message; + var provider = await _emailProviderResolver.GetAsync(entry.Key); + + options.Add(new SelectListItem(provider.DisplayName, entry.Key)); } + + model.Providers = options.OrderBy(x => x.Text).ToArray(); } } diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Drivers/EmailSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.Email/Drivers/EmailSettingsDisplayDriver.cs new file mode 100644 index 00000000000..b471f4b469a --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email/Drivers/EmailSettingsDisplayDriver.cs @@ -0,0 +1,119 @@ +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Http; +using Microsoft.AspNetCore.Mvc.Rendering; +using Microsoft.Extensions.Localization; +using Microsoft.Extensions.Options; +using OrchardCore.DisplayManagement.Entities; +using OrchardCore.DisplayManagement.Handlers; +using OrchardCore.DisplayManagement.Views; +using OrchardCore.Email.Core; +using OrchardCore.Email.Core.Services; +using OrchardCore.Email.ViewModels; +using OrchardCore.Environment.Shell; +using OrchardCore.Modules; +using OrchardCore.Settings; + +namespace OrchardCore.Email.Drivers; + +public class EmailSettingsDisplayDriver : SectionDisplayDriver +{ + private readonly IHttpContextAccessor _httpContextAccessor; + private readonly IAuthorizationService _authorizationService; + private readonly IShellHost _shellHost; + private readonly EmailOptions _emailOptions; + private readonly IEmailProviderResolver _emailProviderResolver; + private readonly ShellSettings _shellSettings; + private readonly EmailProviderOptions _emailProviders; + + protected readonly IStringLocalizer S; + + public EmailSettingsDisplayDriver( + IHttpContextAccessor httpContextAccessor, + IAuthorizationService authorizationService, + IShellHost shellHost, + IOptions emailProviders, + IOptions emailOptions, + IEmailProviderResolver emailProviderResolver, + ShellSettings shellSettings, + IStringLocalizer stringLocalizer) + { + _httpContextAccessor = httpContextAccessor; + _authorizationService = authorizationService; + _shellHost = shellHost; + _emailOptions = emailOptions.Value; + _emailProviderResolver = emailProviderResolver; + _emailProviders = emailProviders.Value; + _shellSettings = shellSettings; + S = stringLocalizer; + } + public override async Task EditAsync(EmailSettings settings, BuildEditorContext context) + { + if (!context.GroupId.EqualsOrdinalIgnoreCase(EmailSettings.GroupId)) + { + return null; + } + + if (!await _authorizationService.AuthorizeAsync(_httpContextAccessor.HttpContext?.User, Permissions.ManageEmailSettings)) + { + return null; + } + + context.Shape.Metadata.Wrappers.Add("Settings_Wrapper__Reload"); + + return Initialize("EmailSettings_Edit", async model => + { + model.DefaultProvider = settings.DefaultProviderName ?? _emailOptions.DefaultProviderName; + model.Providers = await GetProviderOptionsAsync(); + }).Location("Content:1#Providers") + .OnGroup(EmailSettings.GroupId); + } + + public override async Task UpdateAsync(EmailSettings settings, BuildEditorContext context) + { + if (!context.GroupId.EqualsOrdinalIgnoreCase(EmailSettings.GroupId)) + { + return null; + } + + if (!await _authorizationService.AuthorizeAsync(_httpContextAccessor.HttpContext?.User, Permissions.ManageEmailSettings)) + { + return null; + } + + var model = new EmailSettingsViewModel(); + + if (await context.Updater.TryUpdateModelAsync(model, Prefix)) + { + if (settings.DefaultProviderName != model.DefaultProvider) + { + settings.DefaultProviderName = model.DefaultProvider; + + await _shellHost.ReleaseShellContextAsync(_shellSettings); + } + } + + return await EditAsync(settings, context); + } + + private async Task GetProviderOptionsAsync() + { + var options = new List(); + + foreach (var entry in _emailProviders.Providers) + { + if (!entry.Value.IsEnabled) + { + continue; + } + + var provider = await _emailProviderResolver.GetAsync(entry.Key); + + options.Add(new SelectListItem(provider.DisplayName, entry.Key)); + } + + return options.OrderBy(x => x.Text).ToArray(); + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Drivers/SmtpSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.Email/Drivers/SmtpSettingsDisplayDriver.cs deleted file mode 100644 index 789dad473af..00000000000 --- a/src/OrchardCore.Modules/OrchardCore.Email/Drivers/SmtpSettingsDisplayDriver.cs +++ /dev/null @@ -1,110 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Authorization; -using Microsoft.AspNetCore.DataProtection; -using Microsoft.AspNetCore.Http; -using OrchardCore.DisplayManagement.Entities; -using OrchardCore.DisplayManagement.Handlers; -using OrchardCore.DisplayManagement.Views; -using OrchardCore.Email.Services; -using OrchardCore.Environment.Shell; -using OrchardCore.Settings; - -namespace OrchardCore.Email.Drivers -{ - public class SmtpSettingsDisplayDriver : SectionDisplayDriver - { - public const string GroupId = "email"; - private readonly IDataProtectionProvider _dataProtectionProvider; - private readonly IShellHost _shellHost; - private readonly ShellSettings _shellSettings; - private readonly IHttpContextAccessor _httpContextAccessor; - private readonly IAuthorizationService _authorizationService; - - public SmtpSettingsDisplayDriver( - IDataProtectionProvider dataProtectionProvider, - IShellHost shellHost, - ShellSettings shellSettings, - IHttpContextAccessor httpContextAccessor, - IAuthorizationService authorizationService) - { - _dataProtectionProvider = dataProtectionProvider; - _shellHost = shellHost; - _shellSettings = shellSettings; - _httpContextAccessor = httpContextAccessor; - _authorizationService = authorizationService; - } - - public override async Task EditAsync(SmtpSettings settings, BuildEditorContext context) - { - var user = _httpContextAccessor.HttpContext?.User; - - if (!await _authorizationService.AuthorizeAsync(user, Permissions.ManageEmailSettings)) - { - return null; - } - - var shapes = new List - { - Initialize("SmtpSettings_Edit", model => - { - model.DefaultSender = settings.DefaultSender; - model.DeliveryMethod = settings.DeliveryMethod; - model.PickupDirectoryLocation = settings.PickupDirectoryLocation; - model.Host = settings.Host; - model.Port = settings.Port; - model.ProxyHost = settings.ProxyHost; - model.ProxyPort = settings.ProxyPort; - model.EncryptionMethod = settings.EncryptionMethod; - model.AutoSelectEncryption = settings.AutoSelectEncryption; - model.RequireCredentials = settings.RequireCredentials; - model.UseDefaultCredentials = settings.UseDefaultCredentials; - model.UserName = settings.UserName; - model.Password = settings.Password; - model.IgnoreInvalidSslCertificate = settings.IgnoreInvalidSslCertificate; - }).Location("Content:5").OnGroup(GroupId), - }; - - if (settings?.DefaultSender != null) - { - shapes.Add(Dynamic("SmtpSettings_TestButton").Location("Actions").OnGroup(GroupId)); - } - - return Combine(shapes); - } - - public override async Task UpdateAsync(SmtpSettings section, BuildEditorContext context) - { - var user = _httpContextAccessor.HttpContext?.User; - - if (!await _authorizationService.AuthorizeAsync(user, Permissions.ManageEmailSettings)) - { - return null; - } - - if (context.GroupId.Equals(GroupId, StringComparison.OrdinalIgnoreCase)) - { - var previousPassword = section.Password; - await context.Updater.TryUpdateModelAsync(section, Prefix); - - // Restore password if the input is empty, meaning that it has not been reset. - if (string.IsNullOrWhiteSpace(section.Password)) - { - section.Password = previousPassword; - } - else - { - // encrypt the password - var protector = _dataProtectionProvider.CreateProtector(nameof(SmtpSettingsConfiguration)); - section.Password = protector.Protect(section.Password); - } - - // Release the tenant to apply the settings. - await _shellHost.ReleaseShellContextAsync(_shellSettings); - } - - return await EditAsync(section, context); - } - } -} diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Extensions/OrchardCoreBuilderExtensions.cs b/src/OrchardCore.Modules/OrchardCore.Email/Extensions/OrchardCoreBuilderExtensions.cs index 203210e73a5..de377fc803e 100644 --- a/src/OrchardCore.Modules/OrchardCore.Email/Extensions/OrchardCoreBuilderExtensions.cs +++ b/src/OrchardCore.Modules/OrchardCore.Email/Extensions/OrchardCoreBuilderExtensions.cs @@ -1,3 +1,4 @@ +using System; using Microsoft.Extensions.Configuration; using OrchardCore.Email; using OrchardCore.Environment.Shell.Configuration; @@ -6,13 +7,19 @@ namespace Microsoft.Extensions.DependencyInjection { public static class OrchardCoreBuilderExtensions { + [Obsolete("This extension is now obsolete and will be removed in the next release. You can safely stop using it, but please keep providing valid settings in the configuration provider for continued functionality.")] public static OrchardCoreBuilder ConfigureEmailSettings(this OrchardCoreBuilder builder) { builder.ConfigureServices((tenantServices, serviceProvider) => { var configurationSection = serviceProvider.GetRequiredService().GetSection("OrchardCore_Email"); - tenantServices.PostConfigure(settings => configurationSection.Bind(settings)); + tenantServices.Configure(options => + { + configurationSection.Bind(options); + + options.IsEnabled = options.ConfigurationExists(); + }); }); return builder; diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Manifest.cs b/src/OrchardCore.Modules/OrchardCore.Email/Manifest.cs index d3ea8d15f3f..546cc8977dc 100644 --- a/src/OrchardCore.Modules/OrchardCore.Email/Manifest.cs +++ b/src/OrchardCore.Modules/OrchardCore.Email/Manifest.cs @@ -5,7 +5,6 @@ Author = ManifestConstants.OrchardCoreTeam, Website = ManifestConstants.OrchardCoreWebsite, Version = ManifestConstants.OrchardCoreVersion, - Description = "Provides email settings configuration and a default email service based on SMTP.", - Dependencies = ["OrchardCore.Resources"], + Description = "Provides the necessary infrastructure for configuring email settings and offers a default SMTP provider.", Category = "Messaging" )] diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Migrations/EmailMigrations.cs b/src/OrchardCore.Modules/OrchardCore.Email/Migrations/EmailMigrations.cs new file mode 100644 index 00000000000..cb16d3ecf0e --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email/Migrations/EmailMigrations.cs @@ -0,0 +1,56 @@ +using System.Linq; +using Microsoft.Extensions.DependencyInjection; +using Microsoft.Extensions.Options; +using OrchardCore.Data.Migration; +using OrchardCore.Environment.Shell; +using OrchardCore.Environment.Shell.Scope; +using OrchardCore.Settings; + +namespace OrchardCore.Email.Migrations; + +public class EmailMigrations : DataMigration +{ + private const string SmtpFeatureId = "OrchardCore.Email.Smtp"; + + public int Create() + { + // In version 1.9, the OrchardCore.Email.Smtp was split from OrchardCore.Email. To ensure we keep the change + // backward compatible, we added this migration step to auto-enable the new SMTP feature for sites that use the + // Email service and have SmtpSettings. + ShellScope.AddDeferredTask(async scope => + { + var siteService = scope.ServiceProvider.GetRequiredService(); + + var featuresManager = scope.ServiceProvider.GetRequiredService(); + + var enabledFeatures = await featuresManager.GetEnabledFeaturesAsync(); + + if (enabledFeatures.Any(feature => feature.Id == SmtpFeatureId)) + { + return; + } + + var site = await siteService.GetSiteSettingsAsync(); + + var smtpSettings = site.As(); + + if (!string.IsNullOrEmpty(smtpSettings.DefaultSender) + || scope.ServiceProvider.GetService>()?.Value.ConfigurationExists() == true) + { + // Enable the SMTP feature. + var allFeatures = await featuresManager.GetAvailableFeaturesAsync(); + + var smtpFeature = allFeatures.FirstOrDefault(feature => feature.Id == SmtpFeatureId); + + if (smtpFeature is null) + { + return; + } + + await featuresManager.EnableFeaturesAsync([smtpFeature]); + } + }); + + return 1; + } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email/OrchardCore.Email.csproj b/src/OrchardCore.Modules/OrchardCore.Email/OrchardCore.Email.csproj index eda177bd7df..024c0ffc204 100644 --- a/src/OrchardCore.Modules/OrchardCore.Email/OrchardCore.Email.csproj +++ b/src/OrchardCore.Modules/OrchardCore.Email/OrchardCore.Email.csproj @@ -4,9 +4,11 @@ true OrchardCore Email - $(OCFrameworkDescription) + + $(OCFrameworkDescription) - Provides email settings configuration and a default email service based on SMTP. + Provides email settings configuration. + $(PackageTags) OrchardCoreFramework @@ -16,6 +18,7 @@ + diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Services/SmtpSettingsConfiguration.cs b/src/OrchardCore.Modules/OrchardCore.Email/Services/SmtpSettingsConfiguration.cs deleted file mode 100644 index 4d2c9b3ce8d..00000000000 --- a/src/OrchardCore.Modules/OrchardCore.Email/Services/SmtpSettingsConfiguration.cs +++ /dev/null @@ -1,60 +0,0 @@ -using Microsoft.AspNetCore.DataProtection; -using Microsoft.Extensions.Logging; -using Microsoft.Extensions.Options; -using OrchardCore.Settings; - -namespace OrchardCore.Email.Services -{ - public class SmtpSettingsConfiguration : IConfigureOptions - { - private readonly ISiteService _site; - private readonly IDataProtectionProvider _dataProtectionProvider; - private readonly ILogger _logger; - - public SmtpSettingsConfiguration( - ISiteService site, - IDataProtectionProvider dataProtectionProvider, - ILogger logger) - { - _site = site; - _dataProtectionProvider = dataProtectionProvider; - _logger = logger; - } - - public void Configure(SmtpSettings options) - { - var settings = _site.GetSiteSettingsAsync() - .GetAwaiter().GetResult() - .As(); - - options.DefaultSender = settings.DefaultSender; - options.DeliveryMethod = settings.DeliveryMethod; - options.PickupDirectoryLocation = settings.PickupDirectoryLocation; - options.Host = settings.Host; - options.Port = settings.Port; - options.ProxyHost = settings.ProxyHost; - options.ProxyPort = settings.ProxyPort; - options.EncryptionMethod = settings.EncryptionMethod; - options.AutoSelectEncryption = settings.AutoSelectEncryption; - options.RequireCredentials = settings.RequireCredentials; - options.UseDefaultCredentials = settings.UseDefaultCredentials; - options.UserName = settings.UserName; - options.Password = settings.Password; - options.IgnoreInvalidSslCertificate = settings.IgnoreInvalidSslCertificate; - - // Decrypt the password - if (!string.IsNullOrWhiteSpace(settings.Password)) - { - try - { - var protector = _dataProtectionProvider.CreateProtector(nameof(SmtpSettingsConfiguration)); - options.Password = protector.Unprotect(settings.Password); - } - catch - { - _logger.LogError("The Smtp password could not be decrypted. It may have been encrypted using a different key."); - } - } - } - } -} diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Startup.cs b/src/OrchardCore.Modules/OrchardCore.Email/Startup.cs index 80f6302b7a6..2c5f0b97b50 100644 --- a/src/OrchardCore.Modules/OrchardCore.Email/Startup.cs +++ b/src/OrchardCore.Modules/OrchardCore.Email/Startup.cs @@ -1,8 +1,9 @@ using Microsoft.Extensions.DependencyInjection; -using Microsoft.Extensions.Options; +using OrchardCore.Data.Migration; using OrchardCore.DisplayManagement.Handlers; +using OrchardCore.Email.Core; using OrchardCore.Email.Drivers; -using OrchardCore.Email.Services; +using OrchardCore.Email.Migrations; using OrchardCore.Modules; using OrchardCore.Navigation; using OrchardCore.Security.Permissions; @@ -14,12 +15,12 @@ public class Startup : StartupBase { public override void ConfigureServices(IServiceCollection services) { - services.AddScoped(); - services.AddScoped, SmtpSettingsDisplayDriver>(); - services.AddScoped(); + services.AddEmailServices() + .AddScoped, EmailSettingsDisplayDriver>() + .AddScoped() + .AddScoped(); - services.AddTransient, SmtpSettingsConfiguration>(); - services.AddScoped(); + services.AddDataMigration(); } } } diff --git a/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/EmailSettingsBaseViewModel.cs b/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/EmailSettingsBaseViewModel.cs new file mode 100644 index 00000000000..a6d688d989d --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/EmailSettingsBaseViewModel.cs @@ -0,0 +1,6 @@ +namespace OrchardCore.Email.ViewModels; + +public class EmailSettingsBaseViewModel +{ + public string DefaultProvider { get; set; } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/EmailSettingsViewModel.cs b/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/EmailSettingsViewModel.cs new file mode 100644 index 00000000000..da7d22ab976 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/EmailSettingsViewModel.cs @@ -0,0 +1,11 @@ +using System.Collections.Generic; +using Microsoft.AspNetCore.Mvc.ModelBinding; +using Microsoft.AspNetCore.Mvc.Rendering; + +namespace OrchardCore.Email.ViewModels; + +public class EmailSettingsViewModel : EmailSettingsBaseViewModel +{ + [BindNever] + public IList Providers { get; set; } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/EmailTestViewModel.cs b/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/EmailTestViewModel.cs new file mode 100644 index 00000000000..2d243cf6624 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/EmailTestViewModel.cs @@ -0,0 +1,33 @@ +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Microsoft.AspNetCore.Mvc.ModelBinding; +using Microsoft.AspNetCore.Mvc.Rendering; + +namespace OrchardCore.Email.ViewModels; + +public class EmailTestViewModel +{ + [Required] + public string Provider { get; set; } + + [Required(AllowEmptyStrings = false)] + public string To { get; set; } + + [EmailAddress(ErrorMessage = "Invalid Email.")] + public string From { get; set; } + + public string Bcc { get; set; } + + public string Cc { get; set; } + + public string ReplyTo { get; set; } + + [Required] + public string Subject { get; set; } + + [Required] + public string Body { get; set; } + + [BindNever] + public IList Providers { get; set; } +} diff --git a/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/SmtpSettingsViewModel.cs b/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/SmtpSettingsViewModel.cs deleted file mode 100644 index 2b1494681eb..00000000000 --- a/src/OrchardCore.Modules/OrchardCore.Email/ViewModels/SmtpSettingsViewModel.cs +++ /dev/null @@ -1,23 +0,0 @@ -using System.ComponentModel.DataAnnotations; - -namespace OrchardCore.Email.ViewModels -{ - public class SmtpSettingsViewModel - { - [Required(AllowEmptyStrings = false)] - public string To { get; set; } - - [EmailAddress(ErrorMessage = "Invalid Email.")] - public string Sender { get; set; } - - public string Bcc { get; set; } - - public string Cc { get; set; } - - public string ReplyTo { get; set; } - - public string Subject { get; set; } - - public string Body { get; set; } - } -} diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Views/Admin/Index.cshtml b/src/OrchardCore.Modules/OrchardCore.Email/Views/Admin/Test.cshtml similarity index 69% rename from src/OrchardCore.Modules/OrchardCore.Email/Views/Admin/Index.cshtml rename to src/OrchardCore.Modules/OrchardCore.Email/Views/Admin/Test.cshtml index be67593c984..82524ca6750 100644 --- a/src/OrchardCore.Modules/OrchardCore.Email/Views/Admin/Index.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.Email/Views/Admin/Test.cshtml @@ -1,10 +1,26 @@ -@model OrchardCore.Email.ViewModels.SmtpSettingsViewModel +@model OrchardCore.Email.ViewModels.EmailTestViewModel

@RenderTitleSegments(T["Settings"])

-
+@if (Model.Providers == null || Model.Providers.Count == 0) +{ + + + return; +} + + @Html.ValidationSummary() +
+ + +
+
@@ -12,21 +28,16 @@
+
-
- - - +
+ + + @T["The sender is optional, it is useful when the email author is different than the email submitter."]
-
-
- - - -
-
+
@@ -34,6 +45,15 @@
+ +
+
+ + + +
+
+
@@ -41,6 +61,7 @@
+
@@ -48,6 +69,7 @@
+
@@ -55,7 +77,8 @@
+
- +
diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Views/EmailSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Email/Views/EmailSettings.Edit.cshtml new file mode 100644 index 00000000000..59c405778e2 --- /dev/null +++ b/src/OrchardCore.Modules/OrchardCore.Email/Views/EmailSettings.Edit.cshtml @@ -0,0 +1,22 @@ +@using Microsoft.Extensions.Options +@using OrchardCore.Email.Core.Services +@using OrchardCore.Email.ViewModels + +@model EmailSettingsViewModel + +@inject IOptions EmailProviderOptions + +@if (Model.Providers.Count == 0) +{ + + + return; +} + +
+ + + +
diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Views/NavigationItemText-email.Id.cshtml b/src/OrchardCore.Modules/OrchardCore.Email/Views/NavigationItemText-email.Id.cshtml index 6260de3faa4..513bf0fef34 100644 --- a/src/OrchardCore.Modules/OrchardCore.Email/Views/NavigationItemText-email.Id.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.Email/Views/NavigationItemText-email.Id.cshtml @@ -1 +1,4 @@ -@T["Email"] + + + +@T["Email"] diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Views/SmtpSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Email/Views/SmtpSettings.Edit.cshtml deleted file mode 100644 index c929cbbf739..00000000000 --- a/src/OrchardCore.Modules/OrchardCore.Email/Views/SmtpSettings.Edit.cshtml +++ /dev/null @@ -1,187 +0,0 @@ -@using OrchardCore.Email -@model SmtpSettings - -

@T["The current tenant will be reloaded when the settings are saved."]

- -
- - - - @T["The default email address to use as a sender, unless the email sender is set."] -
- -
- - - - @T["The delivery method used when sending email. Use Network in production. The other options can be useful when developing and testing."] -
- -
-
- -
-
-

@T["Network delivery options"]

- -
-
-
-
- - - - @T["The SMTP server domain, e.g. smtp.mailprovider.com."] -
-
-
-
-
-
- - - - @T["The SMTP server port, usually 25."] -
-
-
-
- -
-
-
-
- - - - @T["The proxy server is optional."] -
-
-
-
-
-
- - - - @T["The proxy port is optional."] -
-
-
-
- -
- - - - @T["The encryption method used when connecting to mail server."] -
- -
- - - - @T["Check to let the system select the encryption method based on port."] -
- -
- - - -
- -
-
- - - - @T["When this option is selected, the application pool or host-process identity is used to authenticate with the mail server."] -
- -
-
- - - - @T["The username for authentication."] -
- -
- - - - @T["The password for authentication."] -
-
-
-
-
-
- -
-
-
-

@T["Specified pickup directory delivery options"]

- -
- - - - @T[@"E.g. C:\Path\To\This\Site\PickedUpEmail to place emails in a PickedUpEmail directory on the C drive."] -
-
-
-
-
- -
-
- - - @T["Ignores SSL certificate check if it's invalid."] -
-
- - diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Views/SmtpSettings.TestButton.cshtml b/src/OrchardCore.Modules/OrchardCore.Email/Views/SmtpSettings.TestButton.cshtml deleted file mode 100644 index 5f2ddd187cc..00000000000 --- a/src/OrchardCore.Modules/OrchardCore.Email/Views/SmtpSettings.TestButton.cshtml +++ /dev/null @@ -1 +0,0 @@ -@T["Test settings"] diff --git a/src/OrchardCore.Modules/OrchardCore.Email/Workflows/Activities/EmailTask.cs b/src/OrchardCore.Modules/OrchardCore.Email/Workflows/Activities/EmailTask.cs index cf7b9d1c8ff..0bcdd816b06 100644 --- a/src/OrchardCore.Modules/OrchardCore.Email/Workflows/Activities/EmailTask.cs +++ b/src/OrchardCore.Modules/OrchardCore.Email/Workflows/Activities/EmailTask.cs @@ -11,19 +11,19 @@ namespace OrchardCore.Email.Workflows.Activities { public class EmailTask : TaskActivity { - private readonly ISmtpService _smtpService; + private readonly IEmailService _emailService; private readonly IWorkflowExpressionEvaluator _expressionEvaluator; protected readonly IStringLocalizer S; private readonly HtmlEncoder _htmlEncoder; public EmailTask( - ISmtpService smtpService, + IEmailService emailService, IWorkflowExpressionEvaluator expressionEvaluator, IStringLocalizer localizer, HtmlEncoder htmlEncoder ) { - _smtpService = smtpService; + _emailService = emailService; _expressionEvaluator = expressionEvaluator; S = localizer; _htmlEncoder = htmlEncoder; @@ -88,7 +88,6 @@ public bool IsHtmlBody set => SetProperty(value); } - public override IEnumerable GetPossibleOutcomes(WorkflowExecutionContext workflowContext, ActivityContext activityContext) { return Outcomes(S["Done"], S["Failed"]); @@ -124,7 +123,7 @@ public override async Task ExecuteAsync(WorkflowExecuti message.Sender = sender.Trim(); } - var result = await _smtpService.SendAsync(message); + var result = await _emailService.SendAsync(message); workflowContext.LastResult = result; if (!result.Succeeded) diff --git a/src/OrchardCore.Modules/OrchardCore.Facebook/Views/FacebookLoginSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Facebook/Views/FacebookLoginSettings.Edit.cshtml index 18e326f0ba8..8c77082830f 100644 --- a/src/OrchardCore.Modules/OrchardCore.Facebook/Views/FacebookLoginSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.Facebook/Views/FacebookLoginSettings.Edit.cshtml @@ -1,8 +1,8 @@ @using OrchardCore.Facebook.Login.ViewModels @model FacebookLoginSettingsViewModel -

- @T["The current tenant will be reloaded when the settings are saved."] +

@@ -24,5 +24,5 @@
- @T["Meta Integration settings must be configured in order to use the Login Feature",@Url.RouteUrl(new { area = "OrchardCore.Settings", controller = "Admin", groupId = OrchardCore.Facebook.FacebookConstants.Features.Core })] + @T["Meta Integration settings must be configured in order to use the Login Feature", @Url.RouteUrl(new { area = "OrchardCore.Settings", controller = "Admin", groupId = OrchardCore.Facebook.FacebookConstants.Features.Core })]
\ No newline at end of file diff --git a/src/OrchardCore.Modules/OrchardCore.Facebook/Views/FacebookSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Facebook/Views/FacebookSettings.Edit.cshtml index 1c3ffe9d8cf..f2c86ce6ffb 100644 --- a/src/OrchardCore.Modules/OrchardCore.Facebook/Views/FacebookSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.Facebook/Views/FacebookSettings.Edit.cshtml @@ -1,8 +1,8 @@ @using OrchardCore.Facebook.ViewModels @model FacebookSettingsViewModel -

- @T["The current tenant will be reloaded when the settings are saved."] +

diff --git a/src/OrchardCore.Modules/OrchardCore.GitHub/Views/GithubAuthenticationSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.GitHub/Views/GithubAuthenticationSettings.Edit.cshtml index 56a6e0c0eff..b0bc8b25f03 100644 --- a/src/OrchardCore.Modules/OrchardCore.GitHub/Views/GithubAuthenticationSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.GitHub/Views/GithubAuthenticationSettings.Edit.cshtml @@ -1,8 +1,8 @@ @using OrchardCore.GitHub.ViewModels @model GitHubAuthenticationSettingsViewModel -

- @T["The current tenant will be reloaded when the settings are saved."] +

diff --git a/src/OrchardCore.Modules/OrchardCore.Google/Views/GoogleAuthenticationSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Google/Views/GoogleAuthenticationSettings.Edit.cshtml index 7ba732a2ae0..0042574eb81 100644 --- a/src/OrchardCore.Modules/OrchardCore.Google/Views/GoogleAuthenticationSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.Google/Views/GoogleAuthenticationSettings.Edit.cshtml @@ -1,8 +1,8 @@ @using OrchardCore.Google.Authentication.ViewModels @model GoogleAuthenticationSettingsViewModel -

- @T["The current tenant will be reloaded when the settings are saved."] +

diff --git a/src/OrchardCore.Modules/OrchardCore.Https/Drivers/HttpsSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.Https/Drivers/HttpsSettingsDisplayDriver.cs index f9d84ae91bb..8de473bb2cf 100644 --- a/src/OrchardCore.Modules/OrchardCore.Https/Drivers/HttpsSettingsDisplayDriver.cs +++ b/src/OrchardCore.Modules/OrchardCore.Https/Drivers/HttpsSettingsDisplayDriver.cs @@ -1,3 +1,4 @@ +using System; using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Http; @@ -9,6 +10,7 @@ using OrchardCore.Environment.Shell; using OrchardCore.Https.Settings; using OrchardCore.Https.ViewModels; +using OrchardCore.Modules; using OrchardCore.Settings; namespace OrchardCore.Https.Drivers @@ -41,12 +43,19 @@ public HttpsSettingsDisplayDriver(IHttpContextAccessor httpContextAccessor, public override async Task EditAsync(HttpsSettings settings, BuildEditorContext context) { + if (!context.GroupId.EqualsOrdinalIgnoreCase(GroupId)) + { + return null; + } + var user = _httpContextAccessor.HttpContext?.User; if (!await _authorizationService.AuthorizeAsync(user, Permissions.ManageHttps)) { return null; } + context.Shape.Metadata.Wrappers.Add("Settings_Wrapper__Reload"); + return Initialize("HttpsSettings_Edit", async model => { var isHttpsRequest = _httpContextAccessor.HttpContext.Request.IsHttps; @@ -62,12 +71,13 @@ public override async Task EditAsync(HttpsSettings settings, Bui (isHttpsRequest && !settings.RequireHttps ? _httpContextAccessor.HttpContext.Request.Host.Port : null); - }).Location("Content:2").OnGroup(GroupId); + }).Location("Content:2") + .OnGroup(GroupId); } public override async Task UpdateAsync(HttpsSettings settings, BuildEditorContext context) { - if (context.GroupId == GroupId) + if (context.GroupId.Equals(GroupId, StringComparison.OrdinalIgnoreCase)) { var user = _httpContextAccessor.HttpContext?.User; if (!await _authorizationService.AuthorizeAsync(user, Permissions.ManageHttps)) diff --git a/src/OrchardCore.Modules/OrchardCore.Https/Views/HttpsSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Https/Views/HttpsSettings.Edit.cshtml index 2eba311b83a..453652b2511 100644 --- a/src/OrchardCore.Modules/OrchardCore.Https/Views/HttpsSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.Https/Views/HttpsSettings.Edit.cshtml @@ -1,7 +1,5 @@ @model HttpsSettingsViewModel -

@T["The current tenant will be reloaded when the settings are saved."]

-
diff --git a/src/OrchardCore.Modules/OrchardCore.Layers/Deployment/AllLayersDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.Layers/Deployment/AllLayersDeploymentSource.cs index a1fb33a8497..07547cda658 100644 --- a/src/OrchardCore.Modules/OrchardCore.Layers/Deployment/AllLayersDeploymentSource.cs +++ b/src/OrchardCore.Modules/OrchardCore.Layers/Deployment/AllLayersDeploymentSource.cs @@ -3,6 +3,7 @@ using System.Threading.Tasks; using Microsoft.Extensions.Options; using OrchardCore.Deployment; +using OrchardCore.Json; using OrchardCore.Layers.Models; using OrchardCore.Layers.Services; using OrchardCore.Settings; @@ -18,11 +19,11 @@ public class AllLayersDeploymentSource : IDeploymentSource public AllLayersDeploymentSource( ILayerService layerService, ISiteService siteService, - IOptions serializationOptions) + IOptions serializationOptions) { _layerService = layerService; _siteService = siteService; - _jsonSerializerOptions = serializationOptions.Value; + _jsonSerializerOptions = serializationOptions.Value.SerializerOptions; } public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result) diff --git a/src/OrchardCore.Modules/OrchardCore.Layers/Recipes/LayerStep.cs b/src/OrchardCore.Modules/OrchardCore.Layers/Recipes/LayerStep.cs index 43ec709329e..0e2b4732f46 100644 --- a/src/OrchardCore.Modules/OrchardCore.Layers/Recipes/LayerStep.cs +++ b/src/OrchardCore.Modules/OrchardCore.Layers/Recipes/LayerStep.cs @@ -5,6 +5,7 @@ using System.Text.Json.Nodes; using System.Threading.Tasks; using Microsoft.Extensions.Options; +using OrchardCore.Json; using OrchardCore.Layers.Models; using OrchardCore.Layers.Services; using OrchardCore.Recipes.Models; @@ -30,13 +31,13 @@ public LayerStep( IRuleMigrator ruleMigrator, IConditionIdGenerator conditionIdGenerator, IEnumerable factories, - IOptions serializationOptions) + IOptions serializationOptions) { _layerService = layerService; _ruleMigrator = ruleMigrator; _conditionIdGenerator = conditionIdGenerator; _factories = factories; - _serializationOptions = serializationOptions.Value; + _serializationOptions = serializationOptions.Value.SerializerOptions; } public async Task ExecuteAsync(RecipeExecutionContext context) diff --git a/src/OrchardCore.Modules/OrchardCore.Localization/Drivers/LocalizationSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.Localization/Drivers/LocalizationSettingsDisplayDriver.cs index 1242dc28e7b..78b7357dc18 100644 --- a/src/OrchardCore.Modules/OrchardCore.Localization/Drivers/LocalizationSettingsDisplayDriver.cs +++ b/src/OrchardCore.Modules/OrchardCore.Localization/Drivers/LocalizationSettingsDisplayDriver.cs @@ -14,6 +14,7 @@ using OrchardCore.Environment.Shell; using OrchardCore.Localization.Models; using OrchardCore.Localization.ViewModels; +using OrchardCore.Modules; using OrchardCore.Settings; namespace OrchardCore.Localization.Drivers @@ -42,8 +43,8 @@ public LocalizationSettingsDisplayDriver( IHttpContextAccessor httpContextAccessor, IAuthorizationService authorizationService, IOptions cultureOptions, - IHtmlLocalizer h, - IStringLocalizer s + IHtmlLocalizer htmlLocalizer, + IStringLocalizer stringLocalizer ) { _notifier = notifier; @@ -52,13 +53,18 @@ IStringLocalizer s _httpContextAccessor = httpContextAccessor; _authorizationService = authorizationService; _cultureOptions = cultureOptions.Value; - H = h; - S = s; + H = htmlLocalizer; + S = stringLocalizer; } /// public override async Task EditAsync(LocalizationSettings settings, BuildEditorContext context) { + if (!context.GroupId.EqualsOrdinalIgnoreCase(GroupId)) + { + return null; + } + var user = _httpContextAccessor.HttpContext?.User; if (!await _authorizationService.AuthorizeAsync(user, Permissions.ManageCultures)) @@ -66,6 +72,8 @@ public override async Task EditAsync(LocalizationSettings settin return null; } + context.Shape.Metadata.Wrappers.Add("Settings_Wrapper__Reload"); + return Initialize("LocalizationSettings_Edit", model => { model.Cultures = ILocalizationService.GetAllCulturesAndAliases() diff --git a/src/OrchardCore.Modules/OrchardCore.Localization/Views/LocalizationSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Localization/Views/LocalizationSettings.Edit.cshtml index 08a5b350738..a9d516b13e8 100644 --- a/src/OrchardCore.Modules/OrchardCore.Localization/Views/LocalizationSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.Localization/Views/LocalizationSettings.Edit.cshtml @@ -3,8 +3,6 @@ @using System.Text.Json.Nodes @using System.Globalization -

@T["The current tenant will be reloaded when the settings are saved."]

- @{ // ['fr-FR', 'en-US'] var supportedCultures = JConvert.SerializeObject(Model.Cultures.Where(x => x.Supported).Select(c => c.CultureInfo.Name).ToArray()); diff --git a/src/OrchardCore.Modules/OrchardCore.Media/Assets/js/app/MediaApp/app.js b/src/OrchardCore.Modules/OrchardCore.Media/Assets/js/app/MediaApp/app.js index a4eddfb8922..d6a4768c81c 100644 --- a/src/OrchardCore.Modules/OrchardCore.Media/Assets/js/app/MediaApp/app.js +++ b/src/OrchardCore.Modules/OrchardCore.Media/Assets/js/app/MediaApp/app.js @@ -70,13 +70,14 @@ function initializeMediaApplication(displayMediaApplication, mediaApplicationUrl } }); - bus.$on('mediaRenamed', function (newName, newPath, oldPath) { + bus.$on('mediaRenamed', function (newName, newPath, oldPath, newUrl) { var media = self.mediaItems.filter(function (item) { return item.mediaPath === oldPath; })[0]; media.mediaPath = newPath; media.name = newName; + media.url = newUrl; }); bus.$on('createFolderRequested', function (media) { @@ -501,7 +502,7 @@ function initializeMediaApplication(displayMediaApplication, mediaApplicationUrl success: function (data) { var modal = bootstrap.Modal.getOrCreateInstance($('#renameMediaModal')); modal.hide(); - bus.$emit('mediaRenamed', newName, newPath, oldPath); + bus.$emit('mediaRenamed', newName, newPath, oldPath, data.newUrl); }, error: function (error) { $('#renameMediaModal-errors').empty(); diff --git a/src/OrchardCore.Modules/OrchardCore.Media/Controllers/AdminController.cs b/src/OrchardCore.Modules/OrchardCore.Media/Controllers/AdminController.cs index 9fbc57b66c0..4085af7b85d 100644 --- a/src/OrchardCore.Modules/OrchardCore.Media/Controllers/AdminController.cs +++ b/src/OrchardCore.Modules/OrchardCore.Media/Controllers/AdminController.cs @@ -6,7 +6,9 @@ using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Mvc; +using Microsoft.AspNetCore.Mvc.ViewFeatures; using Microsoft.AspNetCore.StaticFiles; +using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Localization; using Microsoft.Extensions.Logging; using Microsoft.Extensions.Options; @@ -32,6 +34,8 @@ public class AdminController : Controller private readonly MediaOptions _mediaOptions; private readonly IUserAssetFolderNameProvider _userAssetFolderNameProvider; private readonly IChunkFileUploadService _chunkFileUploadService; + private readonly IFileVersionProvider _fileVersionProvider; + private readonly IServiceProvider _serviceProvider; public AdminController( IMediaFileStore mediaFileStore, @@ -42,8 +46,9 @@ public AdminController( ILogger logger, IStringLocalizer stringLocalizer, IUserAssetFolderNameProvider userAssetFolderNameProvider, - IChunkFileUploadService chunkFileUploadService - ) + IChunkFileUploadService chunkFileUploadService, + IFileVersionProvider fileVersionProvider, + IServiceProvider serviceProvider) { _mediaFileStore = mediaFileStore; _mediaNameNormalizerService = mediaNameNormalizerService; @@ -54,6 +59,8 @@ IChunkFileUploadService chunkFileUploadService S = stringLocalizer; _userAssetFolderNameProvider = userAssetFolderNameProvider; _chunkFileUploadService = chunkFileUploadService; + _fileVersionProvider = fileVersionProvider; + _serviceProvider = serviceProvider; } [Admin("Media", "Media.Index")] @@ -118,7 +125,10 @@ public async Task>> GetMediaItems(string path, var allowedExtensions = GetRequestedExtensions(extensions, false); var allowed = _mediaFileStore.GetDirectoryContentAsync(path) - .WhereAwait(async e => !e.IsDirectory && (allowedExtensions.Count == 0 || allowedExtensions.Contains(Path.GetExtension(e.Path))) && await _authorizationService.AuthorizeAsync(User, Permissions.ManageMediaFolder, (object)e.Path)) + .WhereAwait(async e => + !e.IsDirectory + && (allowedExtensions.Count == 0 || allowedExtensions.Contains(Path.GetExtension(e.Path))) + && await _authorizationService.AuthorizeAsync(User, Permissions.ManageMediaFolder, (object)e.Path)) .Select(e => CreateFileResult(e)); return Ok(await allowed.ToListAsync()); @@ -205,6 +215,9 @@ public async Task Upload(string path, string extensions) var mediaFile = await _mediaFileStore.GetFileInfoAsync(mediaFilePath); + stream.Position = 0; + await PreCacheRemoteMedia(mediaFile, stream); + result.Add(CreateFileResult(mediaFile)); } catch (Exception ex) @@ -312,7 +325,10 @@ public async Task MoveMedia(string oldPath, string newPath) await _mediaFileStore.MoveFileAsync(oldPath, newPath); - return Ok(); + var newFileInfo = await _mediaFileStore.GetFileInfoAsync(newPath); + await PreCacheRemoteMedia(newFileInfo); + + return Ok(new { newUrl = GetCacheBustingMediaPublicUrl(newPath) }); } [HttpPost] @@ -445,7 +461,7 @@ public object CreateFileResult(IFileStoreEntry mediaFile) size = mediaFile.Length, lastModify = mediaFile.LastModifiedUtc.Subtract(new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc)).TotalMilliseconds, folder = mediaFile.DirectoryPath, - url = _mediaFileStore.MapPathToPublicUrl(mediaFile.Path), + url = GetCacheBustingMediaPublicUrl(mediaFile.Path), mediaPath = mediaFile.Path, mime = contentType ?? "application/octet-stream", mediaText = string.Empty, @@ -493,5 +509,37 @@ private HashSet GetRequestedExtensions(string exts, bool fallback) return []; } + + private string GetCacheBustingMediaPublicUrl(string path) => + _fileVersionProvider.AddFileVersionToPath(HttpContext.Request.PathBase, _mediaFileStore.MapPathToPublicUrl(path)); + + // If a remote storage is used, then we need to preemptively cache the newly uploaded or renamed file. Without + // this, the Media Library page will try to load the thumbnail without a cache busting parameter, since + // ShellFileVersionProvider won't find it in the local cache. + // This is not required for files moved across folders, because the folder will be reopened anyway. + private async Task PreCacheRemoteMedia(IFileStoreEntry mediaFile, Stream stream = null) + { + var mediaFileStoreCache = _serviceProvider.GetService(); + if (mediaFileStoreCache == null) + { + return; + } + + Stream localStream = null; + + if (stream == null) + { + stream = localStream = await _mediaFileStore.GetFileStreamAsync(mediaFile); + } + + try + { + await mediaFileStoreCache.SetCacheAsync(stream, mediaFile, HttpContext.RequestAborted); + } + finally + { + localStream?.Dispose(); + } + } } } diff --git a/src/OrchardCore.Modules/OrchardCore.Media/wwwroot/Scripts/media.js b/src/OrchardCore.Modules/OrchardCore.Media/wwwroot/Scripts/media.js index 00930ca3589..a4882efb8cb 100644 --- a/src/OrchardCore.Modules/OrchardCore.Media/wwwroot/Scripts/media.js +++ b/src/OrchardCore.Modules/OrchardCore.Media/wwwroot/Scripts/media.js @@ -1629,12 +1629,13 @@ function initializeMediaApplication(displayMediaApplication, mediaApplicationUrl self.errors.push(errorInfo); } }); - bus.$on('mediaRenamed', function (newName, newPath, oldPath) { + bus.$on('mediaRenamed', function (newName, newPath, oldPath, newUrl) { var media = self.mediaItems.filter(function (item) { return item.mediaPath === oldPath; })[0]; media.mediaPath = newPath; media.name = newName; + media.url = newUrl; }); bus.$on('createFolderRequested', function (media) { self.createFolder(); @@ -2026,7 +2027,7 @@ function initializeMediaApplication(displayMediaApplication, mediaApplicationUrl success: function success(data) { var modal = bootstrap.Modal.getOrCreateInstance($('#renameMediaModal')); modal.hide(); - bus.$emit('mediaRenamed', newName, newPath, oldPath); + bus.$emit('mediaRenamed', newName, newPath, oldPath, data.newUrl); }, error: function error(_error6) { $('#renameMediaModal-errors').empty(); @@ -3421,4 +3422,4 @@ Vue.component('uploadList', { } } }); -//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImpxdWVyeS5maWxldXBsb2FkLmpzIiwianF1ZXJ5LmlmcmFtZS10cmFuc3BvcnQuanMiLCJoZWxwZXJzLmpzIiwiTWVkaWFBcHAvYXBwLmpzIiwiTWVkaWFBcHAvZmlsZXVwbG9hZC5qcyIsIk1lZGlhQXBwL2ZvbGRlckNvbXBvbmVudC5qcyIsIk1lZGlhQXBwL2ZvbnQtYXdlc29tZS10aHVtYm5haWxzLmpzIiwiTWVkaWFBcHAvbWVkaWFJdGVtc0dyaWRDb21wb25lbnQuanMiLCJNZWRpYUFwcC9tZWRpYUl0ZW1zVGFibGVDb21wb25lbnQuanMiLCJNZWRpYUFwcC9wYWdlckNvbXBvbmVudC5qcyIsIk1lZGlhQXBwL3NvcnRJbmRpY2F0b3JDb21wb25lbnQuanMiLCJNZWRpYUZpZWxkL2F0dGFjaGVkTWVkaWFGaWVsZC5qcyIsIk1lZGlhRmllbGQvbWVkaWFmaWVsZC5qcyIsIk1lZGlhRmllbGQvbWVkaWFmaWVsZHNBcHBzQXJyYXkuanMiLCJNZWRpYUZpZWxkL21lZGlhRmllbGRUaHVtYnNDb250YWluZXIuanMiLCJTaGFyZWQvdXBsb2FkQ29tcG9uZW50LmpzIiwiU2hhcmVkL3VwbG9hZExpc3RDb21wb25lbnQuanMiXSwibmFtZXMiOlsiZmFjdG9yeSIsImRlZmluZSIsImFtZCIsImV4cG9ydHMiLCJfdHlwZW9mIiwicmVxdWlyZSIsIndpbmRvdyIsImpRdWVyeSIsIiQiLCJzdXBwb3J0IiwiZmlsZUlucHV0IiwiUmVnRXhwIiwidGVzdCIsIm5hdmlnYXRvciIsInVzZXJBZ2VudCIsInByb3AiLCJ4aHJGaWxlVXBsb2FkIiwiUHJvZ3Jlc3NFdm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zZSkge1xuICAgICAgICAgIGlmIChPYmplY3QucHJvdG90eXBlLmhhc093blByb3BlcnR5LmNhbGwob2JqLl9yZXNwb25zZSwgcHJvcCkpIHtcbiAgICAgICAgICAgIGRlbGV0ZSBvYmouX3Jlc3BvbnNlW3Byb3BdO1xuICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgICAgfSBlbHNlIHtcbiAgICAgICAgb2JqLl9yZXNwb25zZSA9IHt9O1xuICAgICAgfVxuICAgIH0sXG5cbiAgICBfb25Qcm9ncmVzczogZnVuY3Rpb24gKGUsIGRhdGEpIHtcbiAgICAgIGlmIChlLmxlbmd0aENvbXB1dGFibGUpIHtcbiAgICAgICAgdmFyIG5vdyA9IERhdGUubm93ID8gRGF0ZS5ub3coKSA6IG5ldyBEYXRlKCkuZ2V0VGltZSgpLFxuICAgICAgICAgIGxvYWRlZDtcbiAgICAgICAgaWYgKFxuICAgICAgICAgIGRhdGEuX3RpbWUgJiZcbiAgICAgICAgICBkYXRhLnByb2dyZXNzSW50ZXJ2YWwgJiZcbiAgICAgICAgICBub3cgLSBkYXRhLl90aW1lIDwgZGF0YS5wcm9ncmVzc0ludGVydmFsICYmXG4gICAgICAgICAgZS5sb2FkZWQgIT09IGUudG90YWxcbiAgICAgICAgKSB7XG4gICAgICAgICAgcmV0dXJuO1xuICAgICAgICB9XG4gICAgICAgIGRhdGEuX3RpbWUgPSBub3c7XG4gICAgICAgIGxvYWRlZCA9XG4gICAgICAgICAgTWF0aC5mbG9vcihcbiAgICAgICAgICAgIChlLmxvYWRlZCAvIGUudG90YWwpICogKGRhdGEuY2h1bmtTaXplIHx8IGRhdGEuX3Byb2dyZXNzLnRvdGFsKVxuICAgICAgICAgICkgKyAoZGF0YS51cGxvYWRlZEJ5dGVzIHx8IDApO1xuICAgICAgICAvLyBBZGQgdGhlIGRpZmZlcmVuY2UgZnJvbSB0aGUgcHJldmlvdXNseSBsb2FkZWQgc3RhdGVcbiAgICAgICAgLy8gdG8gdGhlIGdsb2J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AgICAgIG5hbWU6IHBhcmFtTmFtZSxcbiAgICAgICAgICAgICAgdmFsdWU6IG9wdGlvbnMuYmxvYlxuICAgICAgICAgICAgfSk7XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICQuZWFjaChvcHRpb25zLmZpbGVzLCBmdW5jdGlvbiAoaW5kZXgsIGZpbGUpIHtcbiAgICAgICAgICAgICAgZm9ybURhdGEucHVzaCh7XG4gICAgICAgICAgICAgICAgbmFtZTpcbiAgICAgICAgICAgICAgICAgICgkLnR5cGUob3B0aW9ucy5wYXJhbU5hbWUpID09PSAnYXJyYXknICYmXG4gICAgICAgICAgICAgICAgICAgIG9wdGlvbnMucGFyYW1OYW1lW2luZGV4XSkgfHxcbiAgICAgICAgICAgICAgICAgIHBhcmFtTmFtZSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogZmlsZVxuICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICBpZiAodGhhdC5faXNJbnN0YW5jZU9mKCdGb3JtRGF0YScsIG9wdGlvbnMuZm9ybURhdGEpKSB7XG4gICAgICAgICAgICBmb3JtRGF0YSA9IG9wdGlvbnMuZm9ybURhdGE7XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGZvcm1EYXRhID0gbmV3IEZvcm1EYXRhKCk7XG4gICAgICAgICAgICAkLmVhY2godGhpcy5fZ2V0Rm9ybURhdGEob3B0aW9ucyksIGZ1bmN0aW9uIChpbmRleCwgZmllbGQpIHtcbiAgICAgICAgICAgICAgZm9ybURhdGEuYXBwZW5kKGZpZWxkLm5hbWUsIGZpZWxkLnZhbHVlKTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgIH1cbiAgICAgICAgICBpZiAob3B0aW9ucy5ibG9iKSB7XG4gICAgICAgICAgICBmb3JtRGF0YS5hcHBlbmQoXG4gICAgICAgICAgICAgIHBhcmFtTmFtZSxcbiAgICAgICAgICAgICAgb3B0aW9ucy5ibG9iLFxuICAgICAgICAgICAgICBmaWxlLnVwbG9hZE5hbWUgfHwgZmlsZS5uYW1lXG4gICAgICAgICAgICApO1xuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAkLmVhY2gob3B0aW9ucy5maWxlcywgZnVuY3Rpb24gKGluZGV4LCBmaWxlKSB7XG4gICAgICAgICAgICAgIC8vIFRoaXMgY2hlY2sgYWxsb3dzIHRoZSB0ZXN0cyB0byBydW4gd2l0aFxuICAgICAgICAgICAgICAvLyBkdW1teSBvYmplY3RzOlxuICAgICAgICAgICAgICBpZiAoXG4gICAgICAgICAgICAgICAgdGhhdC5faXNJbnN0YW5jZU9mKCdGaWxlJywgZmlsZSkgfHxcbiAgICAgICAgICAgICAgICB0aGF0Ll9pc0luc3RhbmNlT2YoJ0Jsb2InLCBmaWxlKVxuICAgICAgICAgICAgICApIHtcbiAgICAgICAgICAgICAgICB2YXIgZmlsZU5hbWUgPSBmaWxlLnVwbG9hZE5hbWUgfHwgZmlsZS5uYW1lO1xuICAgICAgICAgICAgICAgIGlmIChvcHRpb25zLnVuaXF1ZUZpbGVuYW1lcykge1xuICAgICAgICAgICAgICAgICAgZmlsZU5hbWUgPSB0aGF0Ll9nZXRVbmlxdWVGaWxlbmFtZShcbiAgICAgICAgICAgICAgICAgICAgZmlsZU5hbWUsXG4gICAgICAgICAgICAgICAgICAgIG9wdGlvbnMudW5pcXVlRmlsZW5hbWVzXG4gICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBmb3JtRGF0YS5hcHBlbmQoXG4gICAgICAgICAgICAgICAgICAoJC50eXBlKG9wdGlvbnMucGFyYW1OYW1lKSA9PT0gJ2FycmF5JyAmJlxuICAgICAgICAgICAgICAgICAgICBvcHRpb25zLnBhcmFtTmFtZVtpbmRleF0pIHx8XG4gICAgICAgICAgICAgICAgICAgIHBhcmFtTmFtZSxcbiA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gICAgIG9wdGlvbnMuZGF0YVxuICAgICAgKSB7XG4gICAgICAgIHJldHVybiBmYWxzZTtcbiAgICAgIH1cbiAgICAgIGlmICh0ZXN0T25seSkge1xuICAgICAgICByZXR1cm4gdHJ1ZTtcbiAgICAgIH1cbiAgICAgIGlmICh1YiA+PSBmcykge1xuICAgICAgICBmaWxlLmVycm9yID0gb3B0aW9ucy5pMThuKCd1cGxvYWRlZEJ5dGVzJyk7XG4gICAgICAgIHJldHVybiB0aGlzLl9nZXRYSFJQcm9taXNlKGZhbHNlLCBvcHRpb25zLmNvbnRleHQsIFtcbiAgICAgICAgICBudWxsLFxuICAgICAgICAgICdlcnJvcicsXG4gICAgICAgICAgZmlsZS5lcnJvclxuICAgICAgICBdKTtcbiAgICAgIH1cbiAgICAgIC8vIFRoZSBjaHVuayB1cGxvYWQgbWV0aG9kOlxuICAgICAgdXBsb2FkID0gZnVuY3Rpb24gKCkge1xuICAgICAgICAvLyBDbG9uZSB0aGUgb3B0aW9ucyBvYmplY3QgZm9yIGVhY2ggY2h1bmsgdXBsb2FkOlxuICAgICAgICB2YXIgbyA9ICQuZXh0ZW5kKHt9LCBvcHRpb25zKSxcbiAgICAgICAgICBjdXJyZW50TG9hZGVkID0gby5fcHJvZ3Jlc3MubG9hZGVkO1xuICAgICAgICBvLmJsb2IgPSBzbGljZS5jYWxsKFxuICAgICAgICAgIGZpbGUsXG4gICAgICAgICAgdWIsXG4gICAgICAgICAgdWIgKyAoJC50eXBlKG1jcykgPT09ICdmdW5jdGlvbicgPyBtY3MobykgOiBtY3MpLFxuICAgICAgICAgIGZpbGUudHlwZVxuICAgICAgICApO1xuICAgICAgICAvLyBTdG9yZSB0aGUgY3VycmVudCBjaHVuayBzaXplLCBhcyB0aGUgYmxvYiBpdHNlbGZcbiAgICAgICAgLy8gd2lsbCBiZSBkZXJlZmVyZW5jZWQgYWZ0ZXIgZGF0YSBwcm9jZXNzaW5nOlxuICAgICAgICBvLmNodW5rU2l6ZSA9IG8uYm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cyBldmVudFxuICAgICAgICAgICAgLy8gd2l0aCBsb2FkZWQgZXF1YWxpbmcgdG90YWwgaGFzIGJlZW4gdHJpZ2dlcmVkXG4gICAgICAgICAgICAvLyBmb3IgdGhpcyBjaHVuazpcbiAgICAgICAgICAgIGlmIChjdXJyZW50TG9hZGVkICsgby5jaHVua1NpemUgLSBvLl9wcm9ncmVzcy5sb2FkZWQpIHtcbiAgICAgICAgICAgICAgdGhhdC5fb25Qcm9ncmVzcyhcbiAgICAgICAgICAgICAgICAkLkV2ZW50KCdwcm9ncmVzcycsIHtcbiAgICAgICAgICAgICAgICAgIGxlbmd0aENvbXB1dGFibGU6IHRydWUsXG4gICAgICAgICAgICAgICAgICBsb2FkZWQ6IHViIC0gby51cGxvYWRlZEJ5dGVzLFxuICAgICAgICAgICAgICAgICAgdG90YWw6IHViIC0gby51cGxvYWRlZEJ5dGVzXG4gICAgICAgICAgICAgICAgfSksXG4gICAgICAgICAgICAgICAgb1xuICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgb3B0aW9ucy51cGxvYWRlZEJ5dGVzID0gby51cGxvYWRlZEJ5dGVzID0gdWI7XG4gICAgICAgICAgICBvLnJlc3VsdCA9IHJlc3VsdDtcbiAgICAgICAgICAgIG8udGV4dFN0YXR1cyA9IHRleHRTdGF0dXM7XG4gICAgICAgICAgICBvLmpxWEhSID0ganFYSFI7XG4gICAgICAgICAgICB0aGF0Ll90cmlnZ2VyKCdjaHVua2RvbmUnLCBudWxsLCBvKTtcbiAgICAgICAgICAgIHRoYXQuX3RyaWdnZXIoJ2NodW5rYWx3YXlzJywgbnVsbCwgbyk7XG4gICAgICAgICAgICBpZiAodWIgPCBmcykge1xuICAgICAgICAgICAgICAvLyBGaWxlIHVwbG9hZCBub3QgeWV0IGNvbXBsZXRlLFxuICAgICAgICAgICAgICAvLyBjb250aW51ZSB3aXRoIHRoZSBuZXh0IGNodW5rOlxuICAgICAgICAgICAgICB1cGxvYWQoKTtcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgIGRmZC5yZXNvbHZlV2l0aChvLmNvbnRleHQsIFtyZXN1bHQsIHRleHRTdGF0dXMsIGpxWEhSXSk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSlcbiAgICAgICAgICAuZmFpbChmdW5jdGlvbiAoanFYSFIsIHRleHRTdGF0dXMsIGVycm9yVGhyb3duKSB7XG4gICAgICAgICAgICBvLmpxWEhSID0ganFYSFI7XG4gICAgICAgICAgICBvLnRleHRTdGF0dXMgPSB0ZXh0U3RhdHVzO1xuICAgICAgICAgICAgby5lcnJvclRocm93biA9IGVycm9yVGhyb3duO1xuICAgICAgICAgICAgdGhhdC5fdHJpZ2dlcignY2h1bmtmYWlsJywgbnVsbCwgbyk7XG4gICAgICAgICAgICB0aGF0Ll90cmlnZ2VyKCdjaHVua2Fsd2F5cycsIG51bGwsIG8pO1xuICAgICAgICAgICAgZGZkLnJlamVjdFdpdGgoby5jb250ZXh0LCBbanFYSFIsIHRleHRTdGF0dXMsIGVycm9yVGhyb3duXSk7XG4gICAgICAgICAgfSlcbiAgICAgICAgICAuYWx3YXlzKGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICAgIHRoYXQuX2RlaW5pdFByb2dyZXNzTGlzdGVuZXIobyk7XG4gICAgICAgICAgfSk7XG4gICAgICB9O1xuICAgICAgdGhpcy5fZW5oYW5jZVByb21pc2UocHJvbWlzZSk7XG4gICAgICBwcm9taXNlLmFib3J0ID0gZnVuY3Rpb24gKCkge1xuICAgICAgICByZXR1cm4ganFYSFIuYWJvcnQoKTtcbiAgICAgIH07XG4gICAgICB1cGxvYWQoKTtcbiAgICAgIHJldHVybiBwcm9taXNlO1xuICAgIH0sXG5cbiAgICBfYmVmb3JlU2VuZDogZnVuY3Rpb24gKGUsIGRhdGEpIHtcbiAgICAgIGlmICh0aGlzLl9hY3RpdmUgPT09IDApIHtcbiAgICAgICAgLy8gdGhlIHN0YXJ0IGNhbGx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5kJywgeyBkZWxlZ2F0ZWRFdmVudDogZSB9KSxcbiAgICAgICAgICAgICAgICAgIG9wdGlvbnNcbiAgICAgICAgICAgICAgICApID09PSBmYWxzZSkgJiZcbiAgICAgICAgICAgICAgICB0aGF0Ll9nZXRYSFJQcm9taXNlKGZhbHNlLCBvcHRpb25zLmNvbnRleHQsIGFib3J0ZWQpKSB8fFxuICAgICAgICAgICAgICB0aGF0Ll9jaHVua2VkVXBsb2FkKG9wdGlvbnMpIHx8XG4gICAgICAgICAgICAgICQuYWpheChvcHRpb25zKVxuICAgICAgICAgICAgKVxuICAgICAgICAgICAgICAuZG9uZShmdW5jdGlvbiAocmVzdWx0LCB0ZXh0U3RhdHVzLCBqcVhIUikge1xuICAgICAgICAgICAgICAgIHRoYXQuX29uRG9uZShyZXN1bHQsIHRleHRTdGF0dXMsIGpxWEhSLCBvcHRpb25zKTtcbiAgICAgICAgICAgICAgfSlcbiAgICAgICAgICAgICAgLmZhaWwoZnVuY3Rpb24gKGpxWEhSLCB0ZXh0U3RhdHVzLCBlcnJvclRocm93bikge1xuICAgICAgICAgICAgICAgIHRoYXQuX29uRmFpbChqcVhIUiwgdGV4dFN0YXR1cywgZXJyb3JUaHJvd24sIG9wdGlvbnMpO1xuICAgICAgICAgICAgICB9KVxuICAgICAgICAgICAgICAuYWx3YXlzKGZ1bmN0aW9uIChqcVhIUm9yUmVzdWx0LCB0ZXh0U3RhdHVzLCBqcVhIUm9yRXJyb3IpIHtcbiAgICAgICAgICAgICAgICB0aGF0Ll9kZWluaXRQcm9ncmVzc0xpc3RlbmVyKG9wdGlvbnMpO1xuICAgICAgICAgICAgICAgIHRoYXQuX29uQWx3YXlzKFxuICAgICAgICAgICAgICAgICAganFYSFJvclJlc3VsdCxcbiAgICAgICAgICAgICAgICAgIHRleHRTdGF0dXMsXG4gICAgICAgICAgICAgICAgICBqcVhIUm9yRXJyb3IsXG4gICAgICAgICAgICAgICAgICBvcHRpb25zXG4gICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgICAgICB0aGF0Ll9zZW5kaW5nIC09IDE7XG4gICAgICAgICAgICAgICAgdGhhdC5fYWN0aXZlIC09IDE7XG4gICAgICAgICAgICAgICAgaWYgKFxuICAgICAgICAgICAgICAgICAgb3B0aW9ucy5saW1pdENvbmN1cnJlbnRVcGxvYWRzICYmXG4gICAgICAgICAgICAgICAgICBvcHRpb25zLmxpbWl0Q29uY3VycmVudFVwbG9hZHMgPiB0aGF0Ll9zZW5kaW5nXG4gICAgICAgICAgICAgICAgKSB7XG4gICAgICAgICAgICAgICAgICAvLyBTdGFydCB0aGUgbmV4dCBxdWV1ZWQgdXBsb2FkLFxuICAgICAgICAgICAgICAgICAgLy8gdGhhdCBoYXMgbm90IGJlZW4gYWJvcnRlZDpcbiAgICAgICAgICAgICAgICAgIHZhciBuZXh0U2xvdCA9IHRoYXQuX3Nsb3RzLnNoaWZ0KCk7XG4gICAgICAgICAgICAgICAgICB3aGlsZSAobmV4dFNsb3QpIHtcbiAgICAgICAgICAgICAgICAgICAgaWYgKHRoYXQuX2dldERlZmVycmVkU3RhdGUobmV4dFNsb3QpID09PSAncGVuZGluZycpIHtcbiAgICAgICAgICAgICAgICAgICAgICBuZXh0U2xvdC5yZXNvbHZlKCk7XG4gICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgbmV4dFNsb3QgPSB0aGF0Ll9zbG90cy5zaGlmdCgpO1xuICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBpZiAodGhhdC5fYWN0aXZlID09PSAwKSB7XG4gICAgICAgICAgICAgICAgICAvLyBUaGUgc3RvcCBjYWxsYmFjayBpcyB0cmlnZ2VyZWQgd2hlbiBhbGwgdXBsb2FkcyBoYXZlXG4gICAgICAgICAgICAgICAgICAvLyBiZWVuIGNvbXBsZXRlZCwgZXF1aXZhbGVudCB0byB0aGUgZ2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BwYXJhbU5hbWU7XG4gICAgICAgICAgfVxuICAgICAgICAgIHBhcmFtTmFtZVNldC5wdXNoKHBhcmFtTmFtZVNsaWNlKTtcbiAgICAgICAgfVxuICAgICAgfSBlbHNlIGlmICghb3B0aW9ucy5zaW5nbGVGaWxlVXBsb2FkcyAmJiBsaW1pdFNpemUpIHtcbiAgICAgICAgZmlsZVNldCA9IFtdO1xuICAgICAgICBwYXJhbU5hbWVTZXQgPSBbXTtcbiAgICAgICAgZm9yIChpID0gMDsgaSA8IGZpbGVzTGVuZ3RoOyBpID0gaSArIDEpIHtcbiAgICAgICAgICBiYXRjaFNpemUgKz0gZmlsZXNbaV0uc2l6ZSArIG92ZXJoZWFkO1xuICAgICAgICAgIGlmIChcbiAgICAgICAgICAgIGkgKyAxID09PSBmaWxlc0xlbmd0aCB8fFxuICAgICAgICAgICAgYmF0Y2hTaXplICsgZmlsZXNbaSArIDFdLnNpemUgKyBvdmVyaGVhZCA+IGxpbWl0U2l6ZSB8fFxuICAgICAgICAgICAgKGxpbWl0ICYmIGkgKyAxIC0gaiA+PSBsaW1pdClcbiAgICAgICAgICApIHtcbiAgICAgICAgICAgIGZpbGVTZXQucHVzaChmaWxlcy5zbGljZShqLCBpICsgMSkpO1xuICAgICAgICAgICAgcGFyYW1OYW1lU2xpY2UgPSBwYXJhbU5hbWUuc2xpY2UoaiwgaSArIDEpO1xuICAgICAgICAgICAgaWYgKCFwYXJhbU5hbWVTbGljZS5sZW5ndGgpIHtcbiAgICAgICAgICAgICAgcGFyYW1OYW1lU2xpY2UgPSBwYXJhbU5hbWU7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBwYXJhbU5hbWVTZXQucHVzaChwYXJhbU5hbWVTbGljZSk7XG4gICAgICAgICAgICBqID0gaSArIDE7XG4gICAgICAgICAgICBiYXRjaFNpemUgPSAwO1xuICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgICAgfSBlbHNlIHtcbiAgICAgICAgcGFyYW1OYW1lU2V0ID0g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ZShbZV0pO1xuICAgICAgICB9LFxuICAgICAgICBzdWNjZXNzSGFuZGxlciA9IGZ1bmN0aW9uIChlbnRyaWVzKSB7XG4gICAgICAgICAgdGhhdFxuICAgICAgICAgICAgLl9oYW5kbGVGaWxlVHJlZUVudHJpZXMoZW50cmllcywgcGF0aCArIGVudHJ5Lm5hbWUgKyAnLycpXG4gICAgICAgICAgICAuZG9uZShmdW5jdGlvbiAoZmlsZXMpIHtcbiAgICAgICAgICAgICAgZGZkLnJlc29sdmUoZmlsZXMpO1xuICAgICAgICAgICAgfSlcbiAgICAgICAgICAgIC5mYWlsKGVycm9ySGFuZGxlcik7XG4gICAgICAgIH0sXG4gICAgICAgIHJlYWRFbnRyaWVzID0gZnVuY3Rpb24gKCkge1xuICAgICAgICAgIGRpclJlYWRlci5yZWFkRW50cmllcyhmdW5jdGlvbiAocmVzdWx0cykge1xuICAgICAgICAgICAgaWYgKCFyZXN1bHRzLmxlbmd0aCkge1xuICAgICAgICAgICAgICBzdWNjZXNzSGFuZGxlcihlbnRyaWVzKTtcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgIGVudHJpZXMgPSBlbnRyaWVzLmNvbmNhdChyZXN1bHRzKTtcbiAgICAgICAgICAgICAgcmVhZEVudHJpZXMoKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9LCBlcnJvckhhbmRsZXIpO1xuICAgICAgICB9O1xuICAgICAgLy8gZXNsaW50LWRpc2FibGUtbmV4dC1saW5lIG5vLXBhcmFtLXJlYXNzaWduXG4gICAgICBwYXRoID0gcGF0aCB8fCAnJztcbiAgICAgIGlmIChlbnRyeS5pc0ZpbGUpIHtcbiAgICAgICAgaWYgKGVudHJ5Ll9maWxlKSB7XG4gICAgICAgICAgLy8gV29ya2Fyb3VuZCBmb3IgQ2hyb21lIGJ1ZyAjMTQ5NzM1XG4gICAgICAgICAgZW50cnkuX2ZpbGUucmVsYXRpdmVQYXRoID0gcGF0aDtcbiAgICAgICAgICBkZmQucmVzb2x2ZShlbnRyeS5fZmlsZSk7XG4gICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgZW50cnkuZmlsZShmdW5jdGlvbiAoZmlsZSkge1xuICAgICAgICAgICAgZmlsZS5yZWxhdGl2ZVBhdGggPSBwYXRoO1xuICAgICAgICAgICAgZGZkLnJlc29sdmUoZmlsZSk7XG4gICAgICAgICAgfSwgZXJyb3JIYW5kbGVyKTtcbiAgICAgICAgfVxuICAgICAgfSBlbHNlIGlmIChlbnRyeS5pc0RpcmVjdG9yeSkge1xuICAgICAgICBkaXJSZWFkZXIgPSBlbnRyeS5jcmVhdGVSZWFkZXIoKTtcbiAgICAgICAgcmVhZEVudHJpZXMoKTtcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIC8vIFJldHVybiBhbiBlbXB0eSBsaXN0IGZvciBmaWxlIHN5c3RlbSBpdGVtc1xuICAgICAgICAvLyBvdGhlciB0aGFuIGZpbGVzIG9yIGRpcmVjdG9yaWVzOlxuICAgICAgICBkZmQucmVzb2x2ZShbXSk7XG4gICAgICB9XG4gICAgICByZXR1cm4gZGZkLnByb21pc2UoKTtcbiAgICB9LFxuXG4gICAgX2hhbmRsZUZpbGVUcmVlRW50cmllczogZnVuY3Rpb24gKGVudHJpZXMsIHBhdGgpIHtcbiAgICAgIHZhciB0aGF0ID0gdGhpcztcbiAgICAgIHJldHVybiAkLndoZW5cbiAgICAgICAgLmFwcGx5KFxuICAgICAgICAgICQsXG4gICAgICAgICAgJC5tYXAoZW50cmllcywgZnVuY3Rpb24gKGVudHJ5KSB7XG4gICAgICAgICAgICByZXR1cm4gdGhhdC5faGFuZGxlRmlsZVRyZWVFbnRyeShlbnRyeSwgcGF0aCk7XG4gICAgICAgICAgfSlcbiAgICAgICAgKVxuICAgICAgICBbdGhpcy5fcHJvbWlzZVBpcGVdKGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICByZXR1cm4gQXJyYXkucHJvdG90eXBlLmNvbmNhdC5hcHBseShbXSwgYXJndW1lbnRzKTtcbiAgICAgICAgfSk7XG4gICAgfSxcblxuICAgIF9nZXREcm9wcGVkRmlsZXM6IGZ1bmN0aW9uIChkYXRhVHJhbnNmZXIpIHtcbiAgICAgIC8vIGVzbGludC1kaXNhYmxlLW5leHQtbGluZSBuby1wYXJhbS1yZWFzc2lnblxuICAgICAgZGF0YVRyYW5zZmVyID0gZGF0YVRyYW5zZmVyIHx8IHt9O1xuICAgICAgdmFyIGl0ZW1zID0gZGF0YVRyYW5zZmVyLml0ZW1zO1xuICAgICAgaWYgKFxuICAgICAgICBpdGVtcyAmJlxuICAgICAgICBpdGVtcy5sZW5ndGggJiZcbiAgICAgICAgKGl0ZW1zWzBdLndlYmtpdEdldEFzRW50cnkgfHwgaXRlbXNbMF0uZ2V0QXNFbnRyeSlcbiAgICAgICkge1xuICAgICAgICByZXR1cm4gdGhpcy5faGFuZGxlRmlsZVRyZWVFbnRyaWVzKFxuICAgICAgICAgICQubWFwKGl0ZW1zLCBmdW5jdGlvbiAoaXRlbSkge1xuICAgICAgICAgICAgdmFyIGVudHJ5O1xuICAgICAgICAgICAgaWYgKGl0ZW0ud2Via2l0R2V0QXNFbnRyeSkge1xuICAgICAgICAgICAgICBlbnRyeSA9IGl0ZW0ud2Via2l0R2V0QXNFbnRyeSgpO1xuICAgICAgICAgICAgICBpZiAoZW50cnkpIHtcbiAgICAgICAgICAgICAgICAvLyBXb3JrYXJvdW5kIGZvciBDaHJvbWUgYnVnICMxNDk3MzU6XG4gICAgICAgICAgICAgICAgZW50cnkuX2ZpbGUgPSBpdGVtLmdldEFzRmlsZSgpO1xuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIHJldHVybiBlbnRyeTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHJldHVybiBpdGVtLmdldEFzRW50cnkoKTtcbiAgICAgICAgICB9KVxuICAgICAgICApO1xuICAgICAgfVxuICAgICAgcmV0dXJuICQuRGVmZXJyZWQoKS5yZXNvbHZlKCQ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JvcnRlZCkge1xuICAgICAgICAgICAgICByZXR1cm47XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBpZiAoIWZpbGVzLmxlbmd0aCkge1xuICAgICAgICAgICAgICBkZmQucmVqZWN0KCk7XG4gICAgICAgICAgICAgIHJldHVybjtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGRhdGEuZmlsZXMgPSBmaWxlcztcbiAgICAgICAgICAgIGpxWEhSID0gdGhhdC5fb25TZW5kKG51bGwsIGRhdGEpO1xuICAgICAgICAgICAganFYSFIudGhlbihcbiAgICAgICAgICAgICAgZnVuY3Rpb24gKHJlc3VsdCwgdGV4dFN0YXR1cywganFYSFIpIHtcbiAgICAgICAgICAgICAgICBkZmQucmVzb2x2ZShyZXN1bHQsIHRleHRTdGF0dXMsIGpxWEhSKTtcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgZnVuY3Rpb24gKGpxWEhSLCB0ZXh0U3RhdHVzLCBlcnJvclRocm93bikge1xuICAgICAgICAgICAgICAgIGRmZC5yZWplY3QoanFYSFIsIHRleHRTdGF0dXMsIGVycm9yVGhyb3duKTtcbiAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgKTtcbiAgICAgICAgICB9KTtcbiAgICAgICAgICByZXR1cm4gdGhpcy5fZW5oYW5jZVByb21pc2UocHJvbWlzZSk7XG4gICAgICAgIH1cbiAgICAgICAgZGF0YS5maWxlcyA9ICQubWFrZUFycmF5KGRhdGEuZmlsZXMpO1xuICAgICAgICBpZiAoZGF0YS5maWxlcy5sZW5ndGgpIHtcbiAgICAgICAgICByZXR1cm4gdGhpcy5fb25TZW5kKG51bGwsIGRhdGEpO1xuICAgICAgICB9XG4gICAgICB9XG4gICAgICByZXR1cm4gdGhpcy5fZ2V0WEhSUHJvbWlzZShmYWxzZSwgZGF0YSAmJiBkYXRhLmNvbnRleHQpO1xuICAgIH1cbiAgfSk7XG59KTtcbiIsIi8qXG4gKiBqUXVlcnkgSWZyYW1lIFRyYW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cHRpb25zLnR5cGUgPSAnUE9TVCc7XG4gICAgICAgICAgfSBlbHNlIGlmIChvcHRpb25zLnR5cGUgPT09ICdQQVRDSCcpIHtcbiAgICAgICAgICAgIG9wdGlvbnMudXJsID0gb3B0aW9ucy51cmwgKyBhZGRQYXJhbUNoYXIgKyAnX21ldGhvZD1QQVRDSCc7XG4gICAgICAgICAgICBvcHRpb25zLnR5cGUgPSAnUE9TVCc7XG4gICAgICAgICAgfVxuICAgICAgICAgIC8vIElFIHZlcnNpb25zIGJlbG93IElFOCBjYW5ub3Qgc2V0IHRoZSBuYW1lIHByb3BlcnR5IG9mXG4gICAgICAgICAgLy8gZWxlbWVudHMgdGhhdCBoYXZlIGFscmVhZHkgYmVlbiBhZGRlZCB0byB0aGUgRE9NLFxuICAgICAgICAgIC8vIHNvIHdlIHNldCB0aGUgbmFtZSBhbG9uZyB3aXRoIHRoZSBpZnJhbWUgSFRNTCBtYXJrdXA6XG4gICAgICAgICAgY291bnRlciArPSAxO1xuICAgICAgICAgIGlmcmFtZSA9ICQoXG4gICAgICAgICAgICAnPGlmcmFtZSBzcmM9XCInICtcbiAgICAgICAgICAgICAgaW5pdGlhbElmcmFtZVNyYyArXG4gICAgICAgICAgICAgICdcIiBuYW1lPVwiaWZyYW1lLXRyYW5zcG9ydC0nICtcbiAgICAgICAgICAgICAgY291bnRlciArXG4gICAgICAgICAgICAgICdcIj48L2lmcmFtZT4nXG4gICAgICAgICAgKS5vbignbG9hZCcsIGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICAgIHZhciBmaWxlSW5wdXRDbG9uZXMsXG4gICAgICAgICAgICAgIHBhcmFtTmFtZXMgPSAkLmlzQXJyYXkob3B0aW9ucy5wYXJhbU5hbWUpXG4gICAgICAgICAgICAgICAgPyBvcHRpb25zLnBhcmFtTmFtZVxuICAgICAgICAgICAgICAgIDogW29wdGlvbnMucGFyYW1OYW1lXTtcbiAgICAgICAgICAgIGlmcmFtZS5vZmYoJ2xvYWQnKS5vbignbG9hZCcsIGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICAgICAgdmFyIHJlc3BvbnNlO1xuICAgICAgICAgICAgICAvLyBXcmFwIGluIGEgdHJ5L2NhdGNoIGJsb2NrIHRvIGNhdGNoIGV4Y2VwdGlvbnMgdGhyb3duXG4gICAgICAgICAgICAgIC8vIHdoZW4gdHJ5aW5nIHRvIGFjY2VzcyBjcm9zcy1kb21haW4gaWZyYW1lIGNvbnRlbnRzOlxuICAgICAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgICAgIHJlc3BvbnNlID0gaWZyYW1lLmNvbnRlbnRzKCk7XG4gICAgICAgICAgICAgICAgLy8gR29vZ2xlIENocm9tZSBhbmQgRmlyZWZveCBkbyBub3QgdGhyb3cgYW5cbiAgICAgICAgICAgICAgICAvLyBleGNlcHRpb24gd2hlbiBjYWxsaW5nIGlmcmFtZS5jb250ZW50cygpIG9uXG4gICAgICAgICAgICAgICAgLy8gY3Jvc3MtZG9tYWluIHJlcXVlc3RzLCBzbyB3ZSB1bmlmeSB0aGUgcmVzcG9uc2U6XG4gICAgICAgICAgICAgICAgaWYgKCFyZXNwb25zZS5sZW5ndGggfHwgIXJlc3BvbnNlWzBdLmZpcnN0Q2hpbGQpIHtcbiAgICAgICAgICAgICAgICAgIHRocm93IG5ldyBFcnJvcigpO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgfSBjYXRjaCAoZSkge1xuICAgICAgICAgICAgICAgIHJlc3BvbnNlID0gdW5kZWZpbmVkO1xuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIC8vIFRoZSBjb21wbGV0ZSBjYWxsYmFjayByZXR1cm5zIHRoZVxuICAgICAgICAgICAgICAvLyBpZnJhbWUgY29udGVudCBkb2N1bWVudCBhcyByZXNwb25zZSBvYmplY3Q6XG4gICAgICAgICAgICAgIGNvbXBsZXRlQ2FsbGJhY2soMjAwLCAnc3VjY2VzcycsIHsgaWZyYW1lOiByZXNwb25zZSB9KTtcbiAgICAgICAgICAgICAgLy8gRml4IGZvciBJRSBlbmRsZXNzIHByb2dyZXNzIGJhciBhY3Rpdml0eSBidWdcbiAgICAgICAgICAgICAgLy8gKGhhcHBlbnMgb24gZm9ybSBzdWJtaXRzIHRvIGlmcmFtZSB0YXJnZXRzKTpcbiAgICAgICAgICAgICAgJCgnPGlmcmFtZSBzcmM9XCInICsgaW5pdGlhbElmcmFtZVNyYyArICdcIj48L2lmcmFtZT4nKS5hcHBlbmRUbyhcbiAgICAgICAgICAgICAgICBmb3JtXG4gICAgICAgICAgICAgICk7XG4gICAgICAgICAgICAgIHdpbmRvdy5zZXRUaW1lb3V0KGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICAgICAgICAvLyBSZW1vdmluZyB0aGUgZm9ybSBpbiBhIHNldFRpbWVvdXQgY2FsbFxuICAgICAgICAgICAgICAgIC8vIGFsbG93cyBDaHJvbWUncyBkZXZlbG9wZXIgdG9vbHMgdG8gZGlzcGxheVxuICAgICAgICAgICAgICAgIC8vIHRoZSByZXNwb25zZSByZXN1bHRcbiAgICAgICAgICAgICAgICBmb3JtLnJlbW92ZSgpO1xuICAgICAgICAgICAgICB9LCAwKTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgZm9ybVxuICAgICAgICAgICAgICAucHJvcCgndGFyZ2V0JywgaWZyYW1lLnByb3AoJ25hbWUnKSlcbiAgICAgICAgICAgICAgLnByb3AoJ2FjdGlvbicsIG9wdGlvbnMudXJsKVxuICAgICAgICAgICAgICAucHJvcCgnbWV0aG9kJywgb3B0aW9ucy50eXBlKTtcbiAgICAgICAgICAgIGlmIChvcHRpb25zLmZvcm1EYXRhKSB7XG4gICAgICAgICAgICAgICQuZWFjaChvcHRpb25zLmZvcm1EYXRhLCBmdW5jdGlvbiAoaW5kZXgsIGZpZWxkKSB7XG4gICAgICAgICAgICAgICAgJCgnPGlucHV0IHR5cGU9XCJoaWRkZW5cIi8+JylcbiAgICAgICAgICAgICAgICAgIC5wcm9wKCduYW1lJywgZmllbGQubmFtZSlcbiAgICAgICAgICAgICAgICAgIC52YWwoZmllbGQudmFsdWUpXG4gICAgICAgICAgICAgICAgICAuYXBwZW5kVG8oZm9ybSk7XG4gICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgaWYgKFxuICAgICAgICAgICAgICBvcHRpb25zLmZpbGVJbnB1dCAmJlxuICAgICAgICAgICAgICBvcHRpb25zLmZpbGVJbnB1dC5sZW5ndGggJiZcbiAgICAgICAgICAgICAgb3B0aW9ucy50eXBlID09PSAnUE9TVCdcbiAgICAgICAgICAgICkge1xuICAgICAgICAgICAgICBmaWxlSW5wdXRDbG9uZXMgPSBvcHRpb25zLmZpbGVJbnB1dC5jbG9uZSgpO1xuICAgICAgICAgICAgICAvLyBJbnNlcnQgYSBjbG9uZSBmb3IgZWFjaCBmaWxlIGlucHV0IGZpZWxkOlxuICAgICAgICAgICAgICBvcHRpb25zLmZpbGVJbnB1dC5hZnRlcihmdW5jdGlvbiAoaW5kZXgpIHtcbiAgICAgICAgICAgICAgICByZXR1cm4gZmlsZUlucHV0Q2xvbmVzW2luZGV4XTtcbiAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgIGlmIChvcHRpb25zLnBhcmFtTmFtZSkge1xuICAgICAgICAgICAgICAgIG9wdGlvbnMuZmlsZUlucHV0LmVhY2goZnVuY3Rpb24gKGluZGV4KSB7XG4gICAgICAgICAgICAgICAgICAkKHRoaXMpLnByb3AoJ25hbWUnLCBwYXJhbU5hbWVzW2luZGV4XSB8fCBvcHRpb25zLnBhcmFtTmFtZSk7XG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgLy8gQXBwZW5kaW5nIHRoZSBmaWxlIGlucHV0IGZpZWxkcyB0byB0aGUgaGlkZGVuIGZvcm1cbiAgICAgICAgICAgICAgLy8gcmVtb3ZlcyB0aGVtIGZyb20gdGhlaXIgb3JpZ2luYWwgb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AgICAgICAgICAvLyBieSByZXBsYWNpbmcgdGhlIGNsb25lcyB3aXRoIHRoZSBvcmlnaW5hbHM6XG4gICAgICAgICAgICAgIGlmIChmaWxlSW5wdXRDbG9uZXMgJiYgZmlsZUlucHV0Q2xvbmVzLmxlbmd0aCkge1xuICAgICAgICAgICAgICAgIG9wdGlvbnMuZmlsZUlucHV0LmVhY2goZnVuY3Rpb24gKGluZGV4LCBpbnB1dCkge1xuICAgICAgICAgICAgICAgICAgdmFyIGNsb25lID0gJChmaWxlSW5wdXRDbG9uZXNbaW5kZXhdKTtcbiAgICAgICAgICAgICAgICAgIC8vIFJlc3RvcmUgdGhlIG9yaWdpbmFsIG5hbWUgYW5kIGZvcm0gcHJvcGVydGllczpcbiAgICAgICAgICAgICAgICAgICQoaW5wdXQpXG4gICAgICAgICAgICAgICAgICAgIC5wcm9wKCduYW1lJywgY2xvbmUucHJvcCgnbmFtZScpKVxuICAgICAgICAgICAgICAgICAgICAuYXR0cignZm9ybScsIGNsb25lLmF0dHIoJ2Zvcm0nKSk7XG4gICAgICAgICAgICAgICAgICBjbG9uZS5yZXBsYWNlV2l0aChpbnB1dCk7XG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH0sIDApO1xuICAgICAgICAgIH0pO1xuICAgICAgICAgIGZvcm0uYXBwZW5kKGlmcmFtZSkuYXBwZW5kVG8oZG9jdW1lbnQuYm9keSk7XG4gICAgICAgIH0sXG4gICAgICAgIGFib3J0OiBmdW5jdGlvbiAoKSB7XG4gICAgICAgICAgaWYgKGlmcmFtZSkge1xuICAgICAgICAgICAgLy8gamF2YXNjcmlwdDpmYWxzZSBhcyBpZnJhbWUgc3JjIGFib3J0cyB0aGUgcmVxdWVzdFxuICAgICAgICAgICAgLy8gYW5kIHByZXZlbnRzIHdhcm5pbmcgcG9wdXBzIG9uIEhUVFBTIGluIElFNi5cbiAgICAgICAgICAgIGlmcmFtZS5vZmYoJ2xvYWQnKS5w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k7XHJcblxyXG4gICAgICAgICAgICAkKGRvY3VtZW50KS50cmlnZ2VyKCdtZWRpYWFwcGxpY2F0aW9uOnJlYWR5Jyk7XHJcblxyXG4gICAgICAgICAgICB2YXIgcm9vdCA9IHtcclxuICAgICAgICAgICAgICAgIG5hbWU6ICQoJyN0LW1lZGlhTGlicmFyeScpLnRleHQoKSxcclxuICAgICAgICAgICAgICAgIHBhdGg6ICcnLFxyXG4gICAgICAgICAgICAgICAgZm9sZGVyOiAnJyxcclxuICAgICAgICAgICAgICAgIGlzRGlyZWN0b3J5OiB0cnVlXHJcbiAgICAgICAgICAgIH07XHJcblxyXG4gICAgICAgICAgICBtZWRpYUFwcCA9IG5ldyBWdWUoe1xyXG4gICAgICAgICAgICAgICAgZWw6ICcjbWVkaWFBcHAnLFxyXG4gICAgICAgICAgICAgICAgZGF0YToge1xyXG4gICAgICAgICAgICAgICAgICAgIHNlbGVjdGVkRm9sZGVyOiB7fSxcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUl0ZW1zOiBbXSxcclxuICAgICAgICAgICAgICAgICAgICBzZWxlY3RlZE1lZGlhczogW10sXHJcbiAgICAgICAgICAgICAgICAgICAgZXJyb3JzOiBbXSxcclxuICAgICAgICAgICAgICAgICAgICBkcmFnRHJvcFRodW1ibmFpbDogbmV3IEltYWdlKCksXHJcbiAgICAgICAgICAgICAgICAgICAgc21hbGxUaHVtYnM6IGZhbHNlLFxyXG4gICAgICAgICAgICAgICAgICAgIGdyaWRWaWV3OiBmYWxzZSxcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUZpbHRlcjogJycsXHJcbiAgICAgICAgICAgICAgICAgICAgc29ydEJ5OiAnJyxcclxuICAgICAgICAgICAgICAgICAgICBzb3J0QXNjOiB0cnVlLFxyXG4gICAgICAgICAgICAgICAgICAgIGl0ZW1zSW5QYWdlOiBbXVxyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIGNyZWF0ZWQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIHNlbGYuZHJhZ0Ryb3BUaHVtYm5haWwuc3JjID0gKHBhdGhCYXNlIHx8ICcnKSArICcvT3JjaGFyZENvcmUuTWVkaWEvSW1hZ2VzL2RyYWctdGh1bWJuYWlsLnBuZyc7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIGJ1cy4kb24oJ2ZvbGRlclNlbGVjdGVkJywgZnVuY3Rpb24gKGZvbGRlcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdGVkRm9sZGVyID0gZm9sZGVyO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdmb2xkZXJEZWxldGVkJywgZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdFJvb3QoKTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRvbignZm9sZGVyQWRkZWQnLCBmdW5jdGlvbiAoZm9sZGVyKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0ZWRGb2xkZXIgPSBmb2xkZXI7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGZvbGRlci5zZWxlY3RlZCA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIGJ1cy4kb24oJ21lZGlhTGlzdE1vdmVkJywgZnVuY3Rpb24gKGVycm9ySW5mbykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLmxvYWRGb2xkZXIoc2VsZi5zZWxlY3RlZEZvbGRlcik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChlcnJvckluZm8pIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuZXJyb3JzLnB1c2goZXJyb3JJbmZvKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdtZWRpYVJlbmFtZWQnLCBmdW5jdGlvbiAobmV3TmFtZSwgbmV3UGF0aCwgb2xkUGF0aCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgbWVkaWEgPSBzZWxmLm1lZGlhSXRlbXMuZmlsdGVyKGZ1bmN0aW9uIChpdGVtKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gaXRlbS5tZWRpYVBhdGggPT09IG9sZFBhdGg7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pWzBdO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgbWVkaWEubWVkaWFQYXRoID0gbmV3UGF0aDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgbWVkaWEubmFtZSA9IG5ld05hbWU7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIGJ1cy4kb24oJ2NyZWF0ZUZvbGRlclJlcXVlc3RlZCcsIGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLmNyZWF0ZUZvbGRlcigpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdkZWxldGVGb2xkZXJSZXF1ZXN0ZWQnLCBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5kZWxldGVGb2xkZXIoKTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgLy8gY29tbW9uIGhhbmRsZXJzIGZvciBhY3Rpb25zIGluIGJvdGggZ3JpZCBhbmQgdGFibGUgdmlldy5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdzb3J0Q2hhbmdlUmVxdWVzdGVkJywgZnVuY3Rpb24gKG5ld1NvcnQpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5jaGFuZ2VTb3J0KG5ld1NvcnQpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdtZWRpYVRvZ2dsZVJlcXVlc3RlZCcsIGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnRvZ2dsZVNlbGVjdGlvbk9mTWVkaWEobWVkaWEpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdyZW5hbWVNZWRpYVJlcXVlc3RlZCcsIGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnJlbmFtZU1lZGlhKG1lZGlhKTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRvbignZGVsZXRlTWVkaWFSZXF1ZXN0ZWQnLCBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5kZWxldGVNZWRpYUl0ZW0obWVkaWEpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdtZWRpYURyYWdTdGFydFJlcXVlc3RlZCcsIGZ1bmN0aW9uIChtZWRpYSwgZSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLmhhbmRsZURyYWdTdGFydChtZWRpYSwgZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG5cclxuICAgICAgICAgICAgICAgICAgICAvLyBoYW5kbGVyIGZvciBwYWdlciBldmVudHNcclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdwYWdlckV2ZW50JywgZnVuY3Rpb24gKGl0ZW1zSW5QYWdlKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuaXRlbXNJblBhZ2UgPSBpdGVtc0luUGFnZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RlZE1lZGlhcyA9IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBpZiAoIWxvY2FsU3RvcmFnZS5nZXRJdGVtKCdtZWRpYUFwcGxpY2F0aW9uUHJlZnMnKSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdGVkRm9sZGVyID0gcm9vdDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZi5jdXJyZW50UHJlZnMgPSBKU09OLnBhcnNlKGxvY2FsU3RvcmFnZS5nZXRJdGVtKCdtZWRpYUFwcGxpY2F0aW9uUHJlZnMnKSk7XHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgY29tcHV0ZWQ6IHtcclxuICAgICAgICAgICAgICAgICAgICBpc0hvbWU6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHRoaXMuc2VsZWN0ZWRGb2xkZXIgPT0gcm9vdDtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHBhcmVudHM6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHAgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcGFyZW50Rm9sZGVyID0gdGhpcy5zZWxlY3RlZEZvbGRlcjtcclxuICAgICAgICAgICAgICAgICAgICAgICAgd2hpbGUgKHBhcmVudEZvbGRlciAmJiBwYXJlbnRGb2xkZXIucGF0aCAhPSAnJykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcC51bnNoaWZ0KHBhcmVudEZvbGRlcik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYXJlbnRGb2xkZXIgPSBwYXJlbnRGb2xkZXIucGFyZW50O1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgcm9vdDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcm9vdDtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGZpbHRlcmVkTWVkaWFJdGVtczogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdGVkTWVkaWFzID0gW107XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgZmlsdGVyZWQgPSBzZWxmLm1lZGlhSXRlbXMuZmlsdGVyKGZ1bmN0aW9uIChpdGVtKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gaXRlbS5uYW1lLnRvTG93ZXJDYXNlKCkuaW5kZXhPZihzZWxmLm1lZGlhRmlsdGVyLnRvTG93ZXJDYXNlKCkpID4gLSAxO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHN3aXRjaCAoc2VsZi5zb3J0QnkpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNhc2UgJ3NpemUnOlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGZpbHRlcmVkLnNvcnQoZnVuY3Rpb24gKGEsIGIpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHNlbGYuc29ydEFzYyA/IGEuc2l6ZSAtIGIuc2l6ZSA6IGIuc2l6ZSAtIGEuc2l6ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNhc2UgJ21pbWUnOlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGZpbHRlcmVkLnNvcnQoZnVuY3Rpb24gKGEsIGIpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHNlbGYuc29ydEFzYyA/IGEubWltZS50b0xvd2VyQ2FzZSgpLmxvY2FsZUNvbXBhcmUoYi5taW1lLnRvTG93ZXJDYXNlKCkpIDogYi5taW1lLnRvTG93ZXJDYXNlKCkubG9jYWxlQ29tcGFyZShhLm1pbWUudG9Mb3dlckNhc2UoKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBjYXNlICdsYXN0TW9kaWZ5JzpcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmaWx0ZXJlZC5zb3J0KGZ1bmN0aW9uIChhLCBiKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBzZWxmLnNvcnRBc2MgPyBhLmxhc3RNb2RpZnkgLSBiLmxhc3RNb2RpZnkgOiBiLmxhc3RNb2RpZnkgLSBhLmxhc3RNb2RpZnk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBkZWZhdWx0OlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGZpbHRlcmVkLnNvcnQoZnVuY3Rpb24gKGEsIGIpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHNlbGYuc29ydEFzYyA/IGEubmFtZS50b0xvd2VyQ2FzZSgpLmxvY2FsZUNvbXBhcmUoYi5uYW1lLnRvTG93ZXJDYXNlKCkpIDogYi5uYW1lLnRvTG93ZXJDYXNlKCkubG9jYWxlQ29tcGFyZShhLm5hbWUudG9Mb3dlckNhc2UoKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBmaWx0ZXJlZDtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGhpZGRlbkNvdW50OiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciByZXN1bHQgPSAwO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXN1bHQgPSB0aGlzLm1lZGlhSXRlbXMubGVuZ3RoIC0gdGhpcy5maWx0ZXJlZE1lZGlhSXRlbXMubGVuZ3RoO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVzdWx0O1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgdGh1bWJTaXplOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLnNtYWxsVGh1bWJzID8gMTAwIDogMjQwO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgY3VycmVudFByZWZzOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGdldDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzbWFsbFRodW1iczogdGhpcy5zbWFsbFRodW1icyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxlY3RlZEZvbGRlcjogdGhpcy5zZWxlY3RlZEZvbGRlcixcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBncmlkVmlldzogdGhpcy5ncmlkVmlld1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2V0OiBmdW5jdGlvbiAobmV3UHJlZnMpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICghbmV3UHJlZnMpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zbWFsbFRodW1icyA9IG5ld1ByZWZzLnNtYWxsVGh1bWJzO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZEZvbGRlciA9IG5ld1ByZWZzLnNlbGVjdGVkRm9sZGVyO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5ncmlkVmlldyA9IG5ld1ByZWZzLmdyaWRWaWV3O1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIHdhdGNoOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgY3VycmVudFByZWZzOiBmdW5jdGlvbiAobmV3UHJlZnMpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgbG9jYWxTdG9yYWdlLnNldEl0ZW0oJ21lZGlhQXBwbGljYXRpb25QcmVmcycsIEpTT04uc3RyaW5naWZ5KG5ld1ByZWZzKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBzZWxlY3RlZEZvbGRlcjogZnVuY3Rpb24gKG5ld0ZvbGRlcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLm1lZGlhRmlsdGVyID0gJyc7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRGb2xkZXIgPSBuZXdGb2xkZXI7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMubG9hZEZvbGRlcihuZXdGb2xkZXIpO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgbW91bnRlZDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgIHRoaXMuJHJlZnMucm9vdEZvbGRlci50b2dnbGUoKTtcclxuICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBtZXRob2RzOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgdXBsb2FkVXJsOiBmdW5jdGlvbiAoKSB7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoIXRoaXMuc2VsZWN0ZWRGb2xkZXIpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBudWxsO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgdXJsVmFsdWUgPSAkKCcjdXBsb2FkRmlsZXMnKS52YWwoKTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB1cmxWYWx1ZSArICh1cmxWYWx1ZS5pbmRleE9mKCc/JykgPT0gLTEgPyAnPycgOiAnJicpICsgXCJwYXRoPVwiICsgZW5jb2RlVVJJQ29tcG9uZW50KHRoaXMuc2VsZWN0ZWRGb2xkZXIucGF0aCk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBzZWxlY3RSb290OiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRGb2xkZXIgPSB0aGlzLnJvb3Q7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBsb2FkRm9sZGVyOiBmdW5jdGlvbiAoZm9sZGVyKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuZXJyb3JzID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYXMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgbWVkaWFVcmwgPSAkKCcjZ2V0TWVkaWFJdGVtc1VybCcpLnZhbCgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmxvZyhmb2xkZXIucGF0aCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICQuYWpheCh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IG1lZGlhVXJsICsgKG1lZGlhVXJsLmluZGV4T2YoJz8nKSA9PSAtMSA/ICc/JyA6ICcmJykgKyBcInBhdGg9XCIgKyBlbmNvZGVVUklDb21wb25lbnQoZm9sZGVyLnBhdGgpLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnR0VUJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHN1Y2Nlc3M6IGZ1bmN0aW9uIChkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS5mb3JFYWNoKGZ1bmN0aW9uIChpdGVtKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGl0ZW0ub3BlbiA9IGZhbHNlO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYubWVkaWFJdGVtcyA9IGRhdGE7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RlZE1lZGlhcyA9IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuc29ydEJ5ID0gJyc7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5zb3J0QXNjID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBlcnJvcjogZnVuY3Rpb24gKGVycm9yKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2coJ2Vycm9yIGxvYWRpbmcgZm9sZGVyOicgKyBmb2xkZXIucGF0aCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RSb290KCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZWN0QWxsOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYXMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCB0aGlzLmZpbHRlcmVkTWVkaWFJdGVtcy5sZW5ndGg7IGkrKykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhcy5wdXNoKHRoaXMuZmlsdGVyZWRNZWRpYUl0ZW1zW2ldKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgdW5TZWxlY3RBbGw6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhcyA9IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgaW52ZXJ0U2VsZWN0aW9uOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciB0ZW1wID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGZvciAodmFyIGkgPSAwOyBpIDwgdGhpcy5maWx0ZXJlZE1lZGlhSXRlbXMubGVuZ3RoOyBpKyspIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICh0aGlzLmlzTWVkaWFTZWxlY3RlZCh0aGlzLmZpbHRlcmVkTWVkaWFJdGVtc1tpXSkgPT0gZmFsc2UpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0ZW1wLnB1c2godGhpcy5maWx0ZXJlZE1lZGlhSXRlbXNbaV0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYXMgPSB0ZW1wO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgdG9nZ2xlU2VsZWN0aW9uT2ZNZWRpYTogZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICh0aGlzLmlzTWVkaWFTZWxlY3RlZChtZWRpYSkgPT0gdHJ1ZSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhcy5zcGxpY2UodGhpcy5zZWxlY3RlZE1lZGlhcy5pbmRleE9mKG1lZGlhKSwgMSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWFzLnB1c2gobWVkaWEpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBpc01lZGlhU2VsZWN0ZWQ6IGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVzdWx0ID0gdGhpcy5zZWxlY3RlZE1lZGlhcy5zb21lKGZ1bmN0aW9uIChlbGVtZW50LCBpbmRleCwgYXJyYXkpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBlbGVtZW50LnVybC50b0xvd2VyQ2FzZSgpID09PSBtZWRpYS51cmwudG9Mb3dlckNhc2UoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiByZXN1bHQ7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBkZWxldGVGb2xkZXI6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGZvbGRlciA9IHRoaXMuc2VsZWN0ZWRGb2xkZXI7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuICAgICAgICAgICAgICAgICAgICAgICAgLy8gVGhlIHJvb3QgZm9sZGVyIGNhbid0IGJlIGRlbGV0ZWRcclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGZvbGRlciA9PSB0aGlzLnJvb3QubW9kZWwpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgY29uZmlybURpYWxvZyh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAuLi4kKFwiI2RlbGV0ZUZvbGRlclwiKS5kYXRhKCksIGNhbGxiYWNrOiBmdW5jdGlvbiAocmVzcCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChyZXNwKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICQuYWpheCh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6ICQoJyNkZWxldGVGb2xkZXJVcmwnKS52YWwoKSArIFwiP3BhdGg9XCIgKyBlbmNvZGVVUklDb21wb25lbnQoZm9sZGVyLnBhdGgpLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnUE9TVCcsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW46ICQoXCJpbnB1dFtuYW1lPSdfX1JlcXVlc3RWZXJpZmljYXRpb25Ub2tlbiddXCIpLnZhbCgpXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc3VjY2VzczogZnVuY3Rpb24gKGRhdGEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBidXMuJGVtaXQoJ2RlbGV0ZUZvbGRlcicsIGZvbGRlcik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZXJyb3I6IGZ1bmN0aW9uIChlcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUuZXJyb3IoZXJyb3IucmVzcG9uc2VUZXh0KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGNyZWF0ZUZvbGRlcjogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAkKCcjY3JlYXRlRm9sZGVyTW9kYWwtZXJyb3JzJykuZW1wdHkoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1vZGFsID0gYm9vdHN0cmFwLk1vZGFsLmdldE9yQ3JlYXRlSW5zdGFuY2UoJCgnI2NyZWF0ZUZvbGRlck1vZGFsJykpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBtb2RhbC5zaG93KCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICQoJyNjcmVhdGVGb2xkZXJNb2RhbCAubW9kYWwtYm9keSBpbnB1dCcpLnZhbCgnJykuZm9jdXMoKTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHJlbmFtZU1lZGlhOiBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgJCgnI3JlbmFtZU1lZGlhTW9kYWwtZXJyb3JzJykuZW1wdHkoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1vZGFsID0gYm9vdHN0cmFwLk1vZGFsLmdldE9yQ3JlYXRlSW5zdGFuY2UoJCgnI3JlbmFtZU1lZGlhTW9kYWwnKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG1vZGFsLnNob3coKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgJCgnI29sZC1pdGVtLW5hbWUnKS52YWwobWVkaWEubmFtZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICQoJyNyZW5hbWVNZWRpYU1vZGFsIC5tb2RhbC1ib2R5IGlucHV0JykudmFsKG1lZGlhLm5hbWUpLmZvY3VzKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBzZWxlY3RBbmREZWxldGVNZWRpYTogZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuZGVsZXRlTWVkaWEoKTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGRlbGV0ZU1lZGlhTGlzdDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgbWVkaWFMaXN0ID0gdGhpcy5zZWxlY3RlZE1lZGlhcztcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKG1lZGlhTGlzdC5sZW5ndGggPCAxKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbmZpcm1EaWFsb2coe1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLi4uJChcIiNkZWxldGVNZWRpYVwiKS5kYXRhKCksIGNhbGxiYWNrOiBmdW5jdGlvbiAocmVzcCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChyZXNwKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwYXRocyA9IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmb3IgKHZhciBpID0gMDsgaSA8IG1lZGlhTGlzdC5sZW5ndGg7IGkrKykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcGF0aHMucHVzaChtZWRpYUxpc3RbaV0ubWVkaWFQYXRoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgJC5hamF4KHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJCgnI2RlbGV0ZU1lZGlhTGlzdFVybCcpLnZhbCgpLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnUE9TVCcsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW46ICQoXCJpbnB1dFtuYW1lPSdfX1JlcXVlc3RWZXJpZmljYXRpb25Ub2tlbiddXCIpLnZhbCgpLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBhdGhzOiBwYXRoc1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHN1Y2Nlc3M6IGZ1bmN0aW9uIChkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBzZWxmLnNlbGVjdGVkTWVkaWFzLmxlbmd0aDsgaSsrKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBpbmRleCA9IHNlbGYubWVkaWFJdGVtcyAmJiBzZWxmLm1lZGlhSXRlbXMuaW5kZXhPZihzZWxmLnNlbGVjdGVkTWVkaWFzW2ldKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGluZGV4ID4gLTEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYubWVkaWFJdGVtcy5zcGxpY2UoaW5kZXgsIDEpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYnVzLiRlbWl0KCdtZWRpYURlbGV0ZWQnLCBzZWxmLnNlbGVjdGVkTWVkaWFzW2ldKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdGVkTWVkaWFzID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZXJyb3I6IGZ1bmN0aW9uIChlcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUuZXJyb3IoZXJyb3IucmVzcG9uc2VUZXh0KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGRlbGV0ZU1lZGlhSXRlbTogZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKCFtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBjb25maXJtRGlhbG9nKHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC4uLiQoXCIjZGVsZXRlTWVkaWFcIikuZGF0YSgpLCBjYWxsYmFjazogZnVuY3Rpb24gKHJlc3ApIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzcCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAkLmFqYXgoe1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiAkKCcjZGVsZXRlTWVkaWFVcmwnKS52YWwoKSArIFwiP3BhdGg9XCIgKyBlbmNvZGVVUklDb21wb25lbnQobWVkaWEubWVkaWFQYXRoKSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJ1BPU1QnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIF9fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuOiAkKFwiaW5wdXRbbmFtZT0nX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW4nXVwiKS52YWwoKVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHN1Y2Nlc3M6IGZ1bmN0aW9uIChkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGluZGV4ID0gc2VsZi5tZWRpYUl0ZW1zICYmIHNlbGYubWVkaWFJdGVtcy5pbmRleE9mKG1lZGlhKVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpbmRleCA+IC0xKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYubWVkaWFJdGVtcy5zcGxpY2UoaW5kZXgsIDEpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBidXMuJGVtaXQoJ21lZGlhRGVsZXRlZCcsIG1lZGlhKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy9zZWxmLnNlbGVjdGVkTWVkaWEgPSBudWxsO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGVycm9yOiBmdW5jdGlvbiAoZXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmVycm9yKGVycm9yLnJlc3BvbnNlVGV4dCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBoYW5kbGVEcmFnU3RhcnQ6IGZ1bmN0aW9uIChtZWRpYSwgZSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAvLyBmaXJzdCBwYXJ0IG9mIG1vdmUgbWVkaWEgdG8gZm9sZGVyOlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAvLyBwcmVwYXJlIHRoZSBkYXRhIHRoYXQgd2lsbCBiZSBoYW5kbGVkIGJ5IHRoZSBmb2xkZXIgY29tcG9uZW50IG9uIGRyb3AgZXZlbnRcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1lZGlhTmFtZXMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhcy5mb3JFYWNoKGZ1bmN0aW9uIChpdGVtKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZWRpYU5hbWVzLnB1c2goaXRlbS5uYW1lKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICAvLyBpbiBjYXNlIHRoZSB1c2VyIGRyYWdzIGFuIHVuc2VsZWN0ZWQgaXRlbSwgd2Ugc2VsZWN0IGl0IGZpcnN0XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICh0aGlzLmlzTWVkaWFTZWxlY3RlZChtZWRpYSkgPT0gZmFsc2UpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1lZGlhTmFtZXMucHVzaChtZWRpYS5uYW1lKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYXMucHVzaChtZWRpYSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGUuZGF0YVRyYW5zZmVyLnNldERhdGEoJ21lZGlhTmFtZXMnLCBKU09OLnN0cmluZ2lmeShtZWRpYU5hbWVzKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGUuZGF0YVRyYW5zZmVyLnNldERhdGEoJ3NvdXJjZUZvbGRlcicsIHRoaXMuc2VsZWN0ZWRGb2xkZXIucGF0aCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGUuZGF0YVRyYW5zZmVyLnNldERyYWdJbWFnZSh0aGlzLmRyYWdEcm9wVGh1bWJuYWlsLCAxMCwgMTApO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBlLmRhdGFUcmFuc2Zlci5lZmZlY3RBbGxvd2VkID0gJ21vdmUnO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgaGFuZGxlU2Nyb2xsV2hpbGVEcmFnOiBmdW5jdGlvbiAoZSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoZS5jbGllbnRZIDwgMTUwKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aW5kb3cuc2Nyb2xsQnkoMCwgLTEwKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGUuY2xpZW50WSA+IHdpbmRvdy5pbm5lckhlaWdodCAtIDEwMCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgd2luZG93LnNjcm9sbEJ5KDAsIDEwKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgY2hhbmdlU29ydDogZnVuY3Rpb24gKG5ld1NvcnQpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHRoaXMuc29ydEJ5ID09IG5ld1NvcnQpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc29ydEFzYyA9ICF0aGlzLnNvcnRBc2M7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnNvcnRBc2MgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zb3J0QnkgPSBuZXdTb3J0O1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICQoJyNjcmVhdGUtZm9sZGVyLW5hbWUnKS5rZXlwcmVzcyhmdW5jdGlvbiAoZSkge1xyXG4gICAgICAgICAgICAgICAgdmFyIGtleSA9IGUud2hpY2g7XHJcbiAgICAgICAgICAgICAgICBpZiAoa2V5ID09IDEzKSB7ICAvLyB0aGUgZW50ZXIga2V5IGNvZGVcclxuICAgICAgICAgICAgICAgICAgICAkKCcjbW9kYWxGb290ZXJPaycpLmNsaWNrKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGZhbHNlO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICQoJyNtb2RhbEZvb3Rlck9rJykub24oJ2NsaWNrJywgZnVuY3Rpb24gKGUpIHtcclxuICAgICAgICAgICAgICAgIHZhciBuYW1lID0gJCgnI2NyZWF0ZS1mb2xkZXItbmFtZScpLnZhbCgpO1xyXG5cclxuICAgICAgICAgICAgICAgIGlmIChuYW1lID09PSBcIlwiKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgICQuYWpheCh7XHJcbiAgICAgICAgICAgICAgICAgICAgdXJsOiAkKCcjY3JlYXRlRm9sZGVyVXJsJykudmFsKCkgKyBcIj9wYXRoPVwiICsgZW5jb2RlVVJJQ29tcG9uZW50KG1lZGlhQXBwLnNlbGVjdGVkRm9sZGVyLnBhdGgpICsgXCImbmFtZT1cIiArIGVuY29kZVVSSUNvbXBvbmVudChuYW1lKSxcclxuICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICdQT1NUJyxcclxuICAgICAgICAgICAgICAgICAgICBkYXRhOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIF9fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuOiAkKFwiaW5wdXRbbmFtZT0nX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW4nXVwiKS52YWwoKVxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgc3VjY2VzczogZnVuY3Rpb24gKGRhdGEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgYnVzLiRlbWl0KCdhZGRGb2xkZXInLCBtZWRpYUFwcC5zZWxlY3RlZEZvbGRlciwgZGF0YSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBtb2RhbCA9IGJvb3RzdHJhcC5Nb2RhbC5nZXRPckNyZWF0ZUluc3RhbmNlKCQoJyNjcmVhdGVGb2xkZXJNb2RhbCcpKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgbW9kYWwuaGlkZSgpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgZXJyb3I6IGZ1bmN0aW9uIChlcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAkKCcjY3JlYXRlRm9sZGVyTW9kYWwtZXJyb3JzJykuZW1wdHkoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGVycm9yTWVzc2FnZSA9IEpTT04ucGFyc2UoZXJyb3IucmVzcG9uc2VUZXh0KS52YWx1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgJCgnPGRpdiBjbGFzcz1cImFsZXJ0IGFsZXJ0LWRhbmdlclwiIHJvbGU9XCJhbGVydFwiPjwvZGl2PicpLnRleHQoZXJyb3JNZXNzYWdlKS5hcHBlbmRUbygkKCcjY3JlYXRlRm9sZGVyTW9kYWwtZXJyb3JzJykpO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICQoJyNyZW5hbWVNZWRpYU1vZGFsRm9vdGVyT2snKS5vbignY2xpY2snLCBmdW5jdGlvbiAoZSkge1xyXG4gICAgICAgICAgICAgICAgdmFyIG5ld05hbWUgPSAkKCcjbmV3LWl0ZW0tbmFtZScpLnZhbCgpO1xyXG4gICAgICAgICAgICAgICAgdmFyIG9sZE5hbWUgPSAkKCcjb2xkLWl0ZW0tbmFtZScpLnZhbCgpO1xyXG5cclxuICAgICAgICAgICAgICAgIGlmIChuZXdOYW1lID09PSBcIlwiKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgIHZhciBjdXJyZW50Rm9sZGVyID0gbWVkaWFBcHAuc2VsZWN0ZWRGb2xkZXIucGF0aCArIFwiL1wiO1xyXG4gICAgICAgICAgICAgICAgaWYgKGN1cnJlbnRGb2xkZXIgPT09IFwiL1wiKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgY3VycmVudEZvbGRlciA9IFwiXCI7XHJcbiAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgdmFyIG5ld1BhdGggPSBjdXJyZW50Rm9sZGVyICsgbmV3TmFtZTtcclxuICAgICAgICAgICAgICAgIHZhciBvbGRQYXRoID0gY3VycmVudEZvbGRlciArIG9sZE5hbWU7XHJcblxyXG4gICAgICAgICAgICAgICAgaWYgKG5ld1BhdGgudG9Mb3dlckNhc2UoKSA9PT0gb2xkUGF0aC50b0xvd2VyQ2FzZSgpKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIG1vZGFsID0gYm9vdHN0cmFwLk1vZGFsLmdldE9yQ3JlYXRlSW5zdGFuY2UoJCgnI3JlbmFtZU1lZGlhTW9kYWwnKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgbW9kYWwuaGlkZSgpO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAkLmFqYXgoe1xyXG4gICAgICAgICAgICAgICAgICAgIHVybDogJCgnI3JlbmFtZU1lZGlhVXJsJykudmFsKCkgKyBcIj9vbGRQYXRoPVwiICsgZW5jb2RlVVJJQ29tcG9uZW50KG9sZFBhdGgpICsgXCImbmV3UGF0aD1cIiArIGVuY29kZVVSSUNvbXBvbmVudChuZXdQYXRoKSxcclxuICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICdQT1NUJyxcclxuICAgICAgICAgICAgICAgICAgICBkYXRhOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIF9fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuOiAkKFwiaW5wdXRbbmFtZT0nX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW4nXVwiKS52YWwoKVxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgc3VjY2VzczogZnVuY3Rpb24gKGRhdGEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1vZGFsID0gYm9vdHN0cmFwLk1vZGFsLmdldE9yQ3JlYXRlSW5zdGFuY2UoJCgnI3JlbmFtZU1lZGlhTW9kYWwnKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG1vZGFsLmhpZGUoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgYnVzLiRlbWl0KCdtZWRpYVJlbmFtZWQnLCBuZXdOYW1lLCBuZXdQYXRoLCBvbGRQYXRoKTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGVycm9yOiBmdW5jdGlvbiAoZXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgJCgnI3JlbmFtZU1lZGlhTW9kYWwtZXJyb3JzJykuZW1wdHkoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGVycm9yTWVzc2FnZSA9IEpTT04ucGFyc2UoZXJyb3IucmVzcG9uc2VUZXh0KS52YWx1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgJCgnPGRpdiBjbGFzcz1cImFsZXJ0IGFsZXJ0LWRhbmdlclwiIHJvbGU9XCJhbGVydFwiPjwvZGl2PicpLnRleHQoZXJyb3JNZXNzYWdlKS5hcHBlbmRUbygkKCcjcmVuYW1lTWVkaWFNb2RhbC1lcnJvcnMnKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgaWYgKGRpc3BsYXlNZWRpYUFwcGxpY2F0aW9uKSB7XHJcbiAgICAgICAgICAgICAgICBkb2N1bWVudC5nZXRFbGVtZW50QnlJZCgnbWVkaWFBcHAnKS5zdHlsZS5kaXNwbGF5ID0gXCJcIjtcclxuICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgJChkb2N1bWVudCkudHJpZ2dlcignbWVkaWFBcHA6cmVhZHknKTtcclxuXHJcbiAgICAgICAgfSxcclxuICAgICAgICBlcnJvcjogZnVuY3Rpb24gKGVycm9yKSB7XHJcbiAgICAgICAgICAgIGNvbnNvbGUuZXJyb3IoZXJyb3IucmVzcG9uc2VUZXh0KTtcclxuICAgICAgICB9XHJcbiAgICB9KTtcclxufVxyXG4iLCIkKGRvY3VtZW50KS5vbignbWVkaWFBcHA6cmVhZHknLCBmdW5jdGlvbiAoKSB7XHJcbiAgICB2YXIgY2h1bmtlZEZpbGVVcGxvYWRJZCA9IHJhbmRvbVVVSUQ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iAoaW5kZXgsIGZpbGUpIHtcclxuICAgICAgICAgICAgICAgICAgICBpZiAoIWZpbGUuZXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgbWVkaWFBcHAubWVkaWFJdGVtcy5wdXNoKGZpbGUpXHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9KVxyXG4gICAgICAgIC5vbignZmlsZXVwbG9hZGNodW5rYmVmb3Jlc2VuZCcsIChlLCBvcHRpb25zKSA9PiB7XHJcbiAgICAgICAgICAgIGxldCBmaWxlID0gb3B0aW9ucy5maWxlc1swXTtcclxuICAgICAgICAgICAgLy8gSGVyZSB3ZSByZXBsYWNlIHRoZSBibG9iIHdpdGggYSBGaWxlIG9iamVjdCB0byBlbnN1cmUgdGhlIGZpbGUgbmFtZSBhbmQgb3RoZXJzIGFyZSBwcmVzZXJ2ZWQgZm9yIHRoZSBiYWNrZW5kLlxyXG4gICAgICAgICAgICBvcHRpb25zLmJsb2IgPSBuZXcgRmlsZShcclxuICAgICAgICAgICAgICAgIFtvcHRpb25zLmJsb2JdLFxyXG4gICAgICAgICAgICAgICAgZmlsZS5uYW1lLFxyXG4gICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgIHR5cGU6IGZpbGUudHlwZSxcclxuICAgICAgICAgICAgICAgICAgICBsYXN0TW9kaWZpZWQ6IGZpbGUubGFzdE1vZGlmaWVkLFxyXG4gICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgfSk7XHJcbn0pO1xyXG5cclxuXHJcbiQoZG9jdW1lbnQpLmJpbmQoJ2RyYWdvdmVyJywgZnVuY3Rpb24gKGUpIHtcclxuICAgIHZhciBkdCA9IGUub3JpZ2luYWxFdmVudC5kYXRhVHJhbnNmZXI7XHJcbiAgICBpZiAoZHQudHlwZXMgJiYgKGR0LnR5cGVzLmluZGV4T2YgPyBkdC50eXBlcy5pb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dGVGb2xkZXJcIiB2LWlmPVwiaXNTZWxlY3RlZCB8fCBpc1Jvb3RcIj48aSBjbGFzcz1cImZhLXNvbGlkIGZhLXBsdXNcIiBhcmlhLWhpZGRlbj1cInRydWVcIj48L2k+PC9hPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPGEgdi1jbG9hayBocmVmPVwiamF2YXNjcmlwdDo7XCIgY2xhc3M9XCJidG4gYnRuLXNtXCIgdi1vbjpjbGljaz1cImRlbGV0ZUZvbGRlclwiIHYtaWY9XCJpc1NlbGVjdGVkICYmICFpc1Jvb3RcIj48aSBjbGFzcz1cImZhLXNvbGlkIGZhLXRyYXNoXCIgYXJpYS1oaWRkZW49XCJ0cnVlXCI+PC9pPjwvYT5cclxuICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cclxuICAgICAgICAgICAgICAgIDwvYT5cclxuICAgICAgICAgICAgPC9kaXY+XHJcbiAgICAgICAgICAgIDxvbCB2LXNob3c9XCJvcGVuXCI+XHJcbiAgICAgICAgICAgICAgICA8Zm9sZGVyIHYtZm9yPVwiZm9sZGVyIGluIGNoaWxkcmVuXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgOmtleT1cImZvbGRlci5wYXRoXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgOm1vZGVsPVwiZm9sZGVyXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgOnNlbGVjdGVkLWluLW1lZGlhLWFwcD1cInNlbGVjdGVkSW5NZWRpYUFwcFwiXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIDpsZXZlbD1cImxldmVsICsgMVwiPlxyXG4gICAgICAgICAgICAgICAgPC9mb2xkZXI+XHJcbiAgICAgICAgICAgIDwvb2w+XHJcbiAgICAgICAgPC9saT5cclxuICAgICAgICBgLFxyXG4gICAgcHJvcHM6IHtcclxuICAgICAgICBtb2RlbDogT2JqZWN0LFxyXG4gICAgICAgIHNlbGVjdGVkSW5NZWRpYUFwcDogT2JqZWN0LFxyXG4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nRvZ2dsZSgpO1xyXG4gICAgICAgIH1cclxuXHJcbiAgICAgICAgdGhpcy5wYWRkaW5nID0gdGhpcy5sZXZlbCA8IDMgPyAgMTYgOiAxNiArICh0aGlzLmxldmVsICogOCk7XHJcbiAgICB9LFxyXG4gICAgY3JlYXRlZDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuICAgICAgICBidXMuJG9uKCdkZWxldGVGb2xkZXInLCBmdW5jdGlvbiAoZm9sZGVyKSB7XHJcbiAgICAgICAgICAgIGlmIChzZWxmLmNoaWxkcmVuKSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgaW5kZXggPSBzZWxmLmNoaWxkcmVuICYmIHNlbGYuY2hpbGRyZW4uaW5kZXhPZihmb2xkZXIpXHJcbiAgICAgICAgICAgICAgICBpZiAoaW5kZXggPiAtMSkge1xyXG4gICAgICAgICAgICAgICAgICAgIHNlbGYuY2hpbGRyZW4uc3BsaWNlKGluZGV4LCAxKVxyXG4gICAgICAgICAgICAgICAgICAgIGJ1cy4kZW1pdCgnZm9sZGVyRGVsZXRlZCcpO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSk7XHJcblxyXG4gICAgICAgIGJ1cy4kb24oJ2FkZEZvbGRlcicsIGZ1bmN0aW9uICh0YXJnZXQsIGZvbGRlcikge1xyXG4gICAgICAgICAgICBpZiAoc2VsZi5tb2RlbCA9PSB0YXJnZXQpIHtcclxuICAgICAgICAgICAgICAgIGlmIChzZWxmLmNoaWxkcmVuICE9PSBudWxsKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZi5jaGlsZHJlbi5wdXNoKGZvbGRlcik7XHJcbiAgICAgICAgICAgICAgICB9ICAgICAgICAgICAgICAgIFxyXG4gICAgICAgICAgICAgICAgZm9sZGVyLnBhcmVudCA9IHNlbGYubW9kZWw7XHJcbiAgICAgICAgICAgICAgICBidXMuJGVtaXQoJ2ZvbGRlckFkZGVkJywgZm9sZGVyKTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH0pO1xyXG4gICAgfSxcclxuICAgIG1ldGhvZHM6IHtcclxuICAgICAgICBpc0FuY2VzdG9yT2ZTZWxlY3RlZEZvbGRlcjogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICBwYXJlbnRGb2xkZXIgPSBtZWRpYUFwcC5zZWxlY3RlZEZvbGRlcjtcclxuICAgICAgICAgICAgd2hpbGUgKHBhcmVudEZvbGRlcikge1xyXG4gICAgICAgICAgICAgICAgaWYgKHBhcmVudEZvbGRlci5wYXRoID09IHRoaXMubW9kZWwucGF0aCkge1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiB0cnVlO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBwYXJlbnRGb2xkZXIgPSBwYXJlbnRGb2xkZXIucGFyZW50O1xyXG4gICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICByZXR1cm4gZmFsc2U7XHJcbiAgICAgICAgfSxcclxuICAgICAgICB0b2dnbGU6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgdGhpcy5vcGVuID0gIXRoaXMub3BlbjtcclxuICAgICAgICAgICAgaWYgKHRoaXMub3BlbiAmJiAhdGhpcy5jaGlsZHJlbikge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5sb2FkQ2hpbGRyZW4oKTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH0sXHJcbiAgICAgICAgc2VsZWN0OiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgIGJ1cy4kZW1pdCgnZm9sZGVyU2VsZWN0ZWQnLCB0aGlzLm1vZGVsKTtcclxuICAgICAgICAgICAgdGhpcy5sb2FkQ2hpbGRyZW4oKTtcclxuICAgICAgICB9LFxyXG4gICAgICAgIGNyZWF0ZUZvbGRlcjogZnVuY3Rpb24gKCkgeyAgICAgICAgICAgXHJcbiAgICAgICAgICAgIGJ1cy4kZW1pdCgnY3JlYXRlRm9sZGVyUmVxdWVzdGVkJyk7XHJcbiAgICAgICAgfSxcclxuICAgICAgICBkZWxldGVGb2xkZXI6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgYnVzLiRlbWl0KCdkZWxldGVGb2xkZXJSZXF1ZXN0ZWQnKTtcclxuICAgICAgICB9LFxyXG4gICAgICAgIGxvYWRDaGlsZHJlbjogZnVuY3Rpb24gKCkgeyAgICAgICAgICAgIFxyXG4gICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcbiAgICAgICAgICAgIGlmICh0aGlzLm9wZW4gPT0gZmFsc2UpIHtcclxuICAgICAgICAgICAgICAgIHRoaXMub3BlbiA9IHRydWU7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgJC5hamF4KHtcclxuICAgICAgICAgICAgICAgIHVybDogJCgnI2dldEZvbGRlcnNVcmwnKS52YWwoKSArIFwiP3BhdGg9XCIgKyBlbmNvZGVVUklDb21wb25lbnQoc2VsZi5tb2RlbC5wYXRoKSxcclxuICAgICAgICAgICAgICAgIG1ldGhvZDogJ0dFVCcsXHJcbiAgICAgICAgICAgICAgICBzdWNjZXNzOiBmdW5jdGlvbiAoZGF0YSkge1xyXG4gICAgICAgICAgICAgICAgICAgIHNlbGYuY2hpbGRyZW4gPSBkYXRhO1xyXG4gICAgICAgICAgICAgICAgICAgIHNlbGYuY2hpbGRyZW4uZm9yRWFjaChmdW5jdGlvbiAoYykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBjLnBhcmVudCA9IHNlbGYubW9kZWw7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgZXJyb3I6IGZ1bmN0aW9uIChlcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgIGVtdHB5ID0gZmFsc2U7XHJcbiAgICAgICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcihlcnJvci5yZXNwb25zZVRleHQpO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9KTtcclxuICAgICAgICB9LFxyXG4gICAgICAgIGhhbmRsZURyYWdPdmVyOiBmdW5jdGlvbiAoZSkge1xyXG4gICAgICAgICAgICB0aGlzLmlzSG92ZXJlZCA9IHRydWU7XHJcbiAgICAgICAgfSxcclxuICAgICAgICBoYW5kbGVEcmFnTGVhdmU6IGZ1bmN0aW9uIChlKSB7XHJcbiAgICAgICAgICAgIHRoaXMuaXNIb3ZlcmVkID0gZmFsc2U7ICAgICAgICAgICAgXHJcbiAgICAgICAgfSxcclxuICAgICAgICBtb3ZlTWVkaWFUb0ZvbGRlcjogZnVuY3Rpb24gKGZvbGRlciwgZSkge1xyXG5cclxuICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG4gICAgICAgICAgICBzZWxmLmlzSG92ZXJlZCA9IGZhbHNlO1xyXG5cclxuICAgICAgICAgICAgdmFyIG1lZGlhTmFtZXMgPSBKU09OLnBhcnNlKGUuZGF0YVRyYW5zZmVyLmdldERhdGEoJ21lZGlhTmFtZXMnKSk7IFxyXG5cclxuICAgICAgICAgICAgaWYgKG1lZGlhTmFtZXMubGVuZ3RoIDwgMSkge1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICB2YXIgc291cmNlRm9sZGVyID0gZS5kYXRhVHJhbnNmZXIuZ2V0RGF0YSgnc291cmNlRm9sZGVyJyk7XHJcbiAgICAgICAgICAgIHZhciB0YXJnZXRGb2xkZXIgPSBmb2xkZXIucGF0aDtcclxuXHJcbiAgICAgICAgICAgIGlmIChzb3VyY2VGb2xkZXIgPT09ICcnKSB7XHJcbiAgICAgICAgICAgICAgICBzb3VyY2VGb2xkZXIgPSAncm9vdCc7XHJcbiAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgIGlmICh0YXJnZXRGb2xkZXIgPT09ICcnKSB7XHJcbiAgICAgICAgICAgICAgICB0YXJnZXRGb2xkZXIgPSAncm9vdCc7XHJcbiAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgIGlmIChzb3VyY2VGb2xkZXIgPT09IHRhcmdldEZvbGRlcikge1xyXG4gICAgICAgICAgICAgICAgYWxlcnQoJCgnI3NhbWVGb2xkZXJNZXNzYWdlJykudmFsKCkpO1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICBjb25maXJtRGlhbG9nKHsuLi4kKFwiI21vdmVNZWRpYVwiKS5kYXRhKCksIGNhbGxiYWNrOiBmdW5jdGlvbiAocmVzcCkge1xyXG4gICAgICAgICAgICAgICAgaWYgKHJlc3ApIHtcclxuICAgICAgICAgICAgICAgICAgICAkLmFqYXgoe1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB1cmw6ICQoJyNtb3ZlTWVkaWFMaXN0VXJsJykudmFsKCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJ1BPU1QnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBkYXRhOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBfX1JlcXVlc3RWZXJpZmljYXRpb25Ub2tlbjogJChcImlucHV0W25hbWU9J19fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuJ11cIikudmFsKCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZWRpYU5hbWVzOiBtZWRpYU5hbWVzLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc291cmNlRm9sZGVyOiBzb3VyY2VGb2xkZXIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0YXJnZXRGb2xkZXI6IHRhcmdldEZvbGRlclxyXG4gICAgICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBzdWNjZXNzOiBmdW5jdGlvbiAoKS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GlhLm5hbWVcIiBcclxuICAgICAgICAgICAgICAgICAgICBjbGFzcz1cIm1lZGlhLWl0ZW0gbWVkaWEtY29udGFpbmVyLW1haW4tbGlzdC1pdGVtIGNhcmQgcC0wXCJcclxuICAgICAgICAgICAgICAgICAgICA6c3R5bGU9XCJ7d2lkdGg6IHRodW1iU2l6ZSArIDIgKyAncHgnfVwiXHJcbiAgICAgICAgICAgICAgICAgICAgOmNsYXNzPVwie3NlbGVjdGVkOiBpc01lZGlhU2VsZWN0ZWQobWVkaWEpfVwiXHJcbiAgICAgICAgICAgICAgICAgICAgdi1vbjpjbGljay5zdG9wPVwidG9nZ2xlU2VsZWN0aW9uT2ZNZWRpYShtZWRpYSlcIlxyXG4gICAgICAgICAgICAgICAgICAgIGRyYWdnYWJsZT1cInRydWVcIiB2LW9uOmRyYWdzdGFydD1cImRyYWdTdGFydChtZWRpYSwgJGV2ZW50KVwiPlxyXG4gICAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJ0aHVtYi1jb250YWluZXJcIiA6c3R5bGU9XCJ7aGVpZ2h0OiB0aHVtYlNpemUgKydweCd9XCI+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIDxpbWcgdi1pZj1cIm1lZGlhLm1pbWUuc3RhcnRzV2l0aCgnaW1hZ2UnKVwiXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgOnNyYz1cImJ1aWxkTWVkaWFVcmwobWVkaWEudXJsLCB0aHVtYlNpemUpXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA6ZGF0YS1taW1lPVwibWVkaWEubWltZVwiXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgOnN0eWxlPVwie21heEhlaWdodDogdGh1bWJTaXplICsncHgnLCBtYXhXaWR0aDogdGh1bWJTaXplICsncHgnfVwiIC8+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIDxpIHYtZWxzZSA6Y2xhc3M9XCJnZXRmb250QXdlc29tZU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hhbmdlU29ydCgnbGFzdE1vZGlmeScpXCI+IFxyXG4gICAgICAgICAgICAgICAgICAgICAgIHt7IFQubGFzdE1vZGlmeUhlYWRlciB9fSBcclxuICAgICAgICAgICAgICAgICAgICAgICAgIDxzb3J0LWluZGljYXRvciBjb2xuYW1lPVwibGFzdE1vZGlmeVwiIDpzZWxlY3RlZGNvbG5hbWU9XCJzb3J0QnlcIiA6YXNjPVwic29ydEFzY1wiPjwvc29ydC1pbmRpY2F0b3I+IFxyXG4gICAgICAgICAgICAgICAgICAgIDwvdGg+IFxyXG4gICAgICAgICAgICAgICAgICAgIDx0aCBzY29wZT1cImNvbFwiIHYtb246Y2xpY2s9XCJjaGFuZ2VTb3J0KCdzaXplJylcIj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgPHNwYW4gY2xhc3M9XCJvcHRpb25hbC1jb2xcIj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHt7IFQuc2l6ZUhlYWRlciB9fVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgPHNvcnQtaW5kaWNhdG9yIGNvbG5hbWU9XCJzaXplXCIgOnNlbGVjdGVkY29sbmFtZT1cInNvcnRCeVwiIDphc2M9XCJzb3J0QXNjXCI+PC9zb3J0LWluZGljYXRvcj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgPC9zcGFuPlxyXG4gICAgICAgICAgICAgICAgICAgIDwvdGg+XHJcbiAgICAgICAgICAgICAgICAgICAgPHRoIHNjb3BlPVwiY29sXCIgdi1vbjpjbGljaz1cImNoYW5nZVNvcnQoJ21pbWUnKVwiPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICA8c3BhbiBjbGFzcz1cIm9wdGlvbmFsLWNvbFwiPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICB7eyBULnR5cGVIZWFkZXIgfX1cclxuICAgICAgICAgICAgICAgICAgICAgICAgIDxzb3J0LWluZGljYXRvciBjb2xuYW1lPVwibWltZVwiIDpzZWxlY3RlZGNvbG5hbWU9XCJzb3J0QnlcIiA6YXNjPVwic29ydEFzY1wiPjwvc29ydC1pbmRpY2F0b3I+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIDwvc3Bhbj5cclxuICAgICAgICAgICAgICAgICAgICA8L3RoPlxyXG4gICAgICAgICAgICAgICAgPC90cj5cclxuICAgICAgICAgICAgPC90aGVhZD5cclxuICAgICAgICAgICAgPHRib2R5PlxyXG4gICAgICAgICAgICAgICAgICAgIDx0ciB2LWZvcj1cIm1lZGlhIGluIGZpbHRlcmVkTWVkaWFJdGVtc1wiXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgY2xhc3M9XCJtZWRpYS1pdGVtXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgICA6Y2xhc3M9XCJ7c2VsZWN0ZWQ6IGlzTWVkaWFTZWxlY3RlZChtZWRpYSl9XCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgICB2LW9uOmNsaWNrLnN0b3A9XCJ0b2dnbGVTZWxlY3Rpb25PZk1lZGlhKG1lZGlhKVwiXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgZHJhZ2dhYmxlPVwidHJ1ZVwiIHYtb246ZHJhZ3N0YXJ0PVwiZHJhZ1N0YXJ0KG1lZGlhLCAkZXZlbnQpXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgICA6a2V5PVwibWVkaWEubmFtZVwiPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgIDx0ZCBjbGFzcz1cInRodW1ibmFpbC1jb2x1bW5cIj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwiaW1nLXdyYXBwZXJcIj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPGltZyB2LWlmPVwibWVkaWEubWltZS5zdGFydHNXaXRoKCdpbWFnZScpXCIgZHJhZ2dhYmxlPVwiZmFsc2VcIiA6c3JjPVwiYnVpbGRNZWRpYVVybChtZWRpYS51cmwsIHRodW1iU2l6ZSlcIiAvPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8aSB2LWVsc2UgOmNsYXNzPVwiZ2V0Zm9udEF3ZXNvbWVDbGFzc05hbWVGb3JGaWxlTmFtZShtZWRpYS5uYW1lLCBcXCdmYS00eFxcJylcIiA6ZGF0YS1taW1lPVwibWVkaWEubWltZVwiPjwvaT5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDwvdGQ+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICA8dGQ+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1lZGlhLW5hbWUtY2VsbFwiPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxzcGFuIGNsYXNzPVwiYnJlYWstd29yZFwiPiB7eyBtZWRpYS5uYW1lIH19IDwvc3Bhbj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cImJ1dHRvbnMtY29udGFpbmVyXCI+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8YSBocmVmPVwiamF2YXNjcmlwdDo7XCIgY2xhc3M9XCJidG4gYnRuLWxpbmsgYnRuLXNtIG1lLTEgZWRpdC1idXR0b25cIiB2LW9uOmNsaWNrLnN0b3A9XCJyZW5hbWVNZWRpYShtZWRpYSlcIj4ge3sgVC5lZGl0QnV0dG9uIH19IDwvYSA+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8YSBocmVmPVwiamF2YXNjcmlwdDo7XCIgY2xhc3M9XCJidG4gYnRuLWxpbmsgYnRuLXNtIGRlbGV0ZS1idXR0b25cIiB2LW9uOmNsaWNrLnN0b3A9XCJkZWxldGVNZWRpYShtZWRpYSlcIj4ge3sgVC5kZWxldGVCdXR0b24gfX0gPC9hPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPGEgOmhyZWY9XCJtZWRpYS51cmxcIiB0YXJnZXQ9XCJfYmxhbmtcIiBjbGFzcz1cImJ0biBidG4tbGluayBidG4tc20gdmlldy1idXR0b25cIj4ge3sgVC52aWV3QnV0dG9uIH19IDwvYT5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPC9kaXY+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPC9kaXY+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICA8L3RkPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPHRkPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJ0ZXh0LWNvbFwiPiB7eyBwcmludERhdGVUaW1lKG1lZGlhLmxhc3RNb2RpZnkpIH19IDwvZGl2PlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPC90ZD5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDx0ZD5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwidGV4dC1jb2wgb3B0aW9uYWwtY29sXCI+IHt7IGlzTmFOKG1lZGlhLnNpemUpPyAwIDogTWF0aC5yb3VuZChtZWRpYS5zaXplIC8gMTAyNCkgfX0gS0I8L2Rpdj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDwvdGQ+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICA8dGQ+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cInRleHQtY29sIG9wdGlvbmFsLWNvbFwiPnt7IG1lZGlhLm1pbWUgfX08L2Rpdj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDwvdGQ+XHJcbiAgICAgICAgICAgICAgICAgICA8L3RyPlxyXG4gICAgICAgICAgIC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ICAgICAgICA8bGkgY2xhc3M9XCJwYWdlLWl0ZW0gbWVkaWEtbGFzdC1idXR0b25cIiA6Y2xhc3M9XCJ7ZGlzYWJsZWQgOiAhY2FuRG9MYXN0fVwiPlxyXG4gICAgICAgICAgICAgICAgICAgIDxhIGNsYXNzPVwicGFnZS1saW5rXCIgaHJlZj1cIiNcIiA6dGFiaW5kZXg9XCJjYW5Eb0xhc3QgPyAwIDogLTFcIiB2LW9uOmNsaWNrPVwiZ29MYXN0XCI+e3sgVC5wYWdlckxhc3RCdXR0b24gfX08L2E+XHJcbiAgICAgICAgICAgICAgICA8L2xpPlxyXG4gICAgICAgICAgICAgICAgPGxpIGNsYXNzPVwicGFnZS1pdGVtIG1zLTQgcGFnZS1zaXplLWluZm9cIj5cclxuICAgICAgICAgICAgICAgICAgICA8ZGl2IHN0eWxlPVwiZGlzcGxheTogZmxleDtcIj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgPHNwYW4gY2xhc3M9XCJwYWdlLWxpbmsgZGlzYWJsZWQgdGV4dC1tdXRlZCBwYWdlLXNpemUtbGFiZWxcIj57eyBULnBhZ2VyUGFnZVNpemVMYWJlbCB9fTwvc3Bhbj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgPHNlbGVjdCBpZD1cInBhZ2VTaXplU2VsZWN0XCIgY2xhc3M9XCJwYWdlLWxpbmtcIiB2LW1vZGVsPVwicGFnZVNpemVcIj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxvcHRpb24gdi1mb3I9XCJvcHRpb24gaW4gcGFnZVNpemVPcHRpb25zXCIgdi1iaW5kOnZhbHVlPVwib3B0aW9uXCI+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAge3tvcHRpb259fVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPC9vcHRpb24+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIDwvc2VsZWN0PlxyXG4gICAgICAgICAgICAgICAgICAgIDwvZGl2PlxyXG4gICAgICAgICAgICAgICAgPC9saT5cclxuICAgICAgICAgICAgPC91bD5cclxuICAgICAgICA8L25hdj5cclxuICAgICAgICA8bmF2IGNsYXNzPVwiZC1mbGV4IGp1c3RpZnktY29udGVudC1jZW50ZXJcIj5cclxuICAgICAgICAgICAgPHVsIGNsYXNzPVwicGFnaW5hdGlvbiBwYWdpbmF0aW9uLXNtIG0tMCBtdC0yXCI+XHJcbiAgICAgICAgICAgICAgICA8bGkgY2xhc3M9XCJwYWdlLWl0ZW0gbXMtNCBwYWdlLWluZm9cIj5cclxuICAgICAgICAgICAgICAgICAgICA8c3BhbiBjbGFzcz1cInBhZ2UtbGluayBkaXNhYmxlZCB0ZXh0LW11dGVkIFwiPnt7IFQucGFnZXJQYWdlTGFiZWwgfX0ge3tjdXJyZW50ICsgMX19L3t7dG90YWxQYWdlc319PC9zcGFuPlxyXG4gICAgICAgICAgICAgICAgPC9saT5cclxuICAgICAgICAgICAgICAgIDxsaSBjbGFzcz1cInBhZ2UtaXRlbSBtcy00IHRvdGFsLWluZm9cIj5cclxuICAgICAgICAgICAgICAgICAgICA8c3BhbiBjbGFzcz1cInBhZ2UtbGluayBkaXNhYmxlZCB0ZXh0LW11dGVkIFwiPiB7eyBULnBhZ2VyVG90YWxMYWJlbCB9fSB7e3RvdGFsfX08L3NwYW4+XHJcbiAgICAgICAgICAgICAgICA8L2xpPlxyXG4gICAgICAgICAgICA8L3VsPlxyXG4gICAgICAgIDwvbmF2PlxyXG4gICAgICAgIDwvZGl2PlxyXG4gICAgICAgIGAsXHJcbiAgICBwcm9wczoge1xyXG4gICAgICAgIHNvdXJjZUl0ZW1zOiBBcnJheVxyXG4gICAgfSxcclxuICAgIGRhdGE6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICByZXR1cm4ge1xyXG4gICAgICAgICAgICBwYWdlU2l6ZTogMTAsXHJcbiAgICAgICAgICAgIHBhZ2VTaXplT3B0aW9uczogWzEwLCAzMCwgNTAsIDEwMF0sXHJcbiAgICAgIC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XRvci5nZXQoMCksXHJcbiAgICAgICAgZGF0YToge1xyXG4gICAgICAgICAgICBtZWRpYUl0ZW1zOiBbXSxcclxuICAgICAgICAgICAgc2VsZWN0ZWRNZWRpYTogbnVsbCxcclxuICAgICAgICAgICAgc21hbGxUaHVtYnM6IGZhbHNlLFxyXG4gICAgICAgICAgICBpZFByZWZpeDogaWRwcmVmaXgsXHJcbiAgICAgICAgICAgIGluaXRpYWxpemVkOiBmYWxzZSxcclxuICAgICAgICAgICAgYWxsb3dNZWRpYVRleHQ6IGFsbG93TWVkaWFUZXh0LFxyXG4gICAgICAgICAgICBiYWNrdXBNZWRpYVRleHQ6ICcnLFxyXG4gICAgICAgICAgICBhbGxvd0FuY2hvcnM6IGFsbG93QW5jaG9ycyxcclxuICAgICAgICAgICAgYmFja3VwQW5jaG9yOiBudWxsLFxyXG4gICAgICAgICAgICBtZWRpYVRleHRtb2RhbDogbnVsbCxcclxuICAgICAgICAgICAgYW5jaG9yaW5nTW9kYWw6IG51bGxcclxuICAgICAgICB9LFxyXG4gICAgICAgIGNyZWF0ZWQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG5cclxuICAgICAgICAgICAgc2VsZi5jdXJyZW50UHJlZnMgPSBKU09OLnBhcnNlKGxvY2FsU3RvcmFnZS5nZXRJdGVtKCdtZWRpYUZpZWxkUHJlZnMnKSk7XHJcbiAgICAgICAgfSxcclxuICAgICAgICBjb21wdXRlZDoge1xyXG4gICAgICAgICAgICBwYXRoczoge1xyXG4gICAgICAgICAgICAgICAgZ2V0OiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIG1lZGlhUGF0aHMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICBpZiAoIXRoaXMuaW5pdGlhbGl6ZWQpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIEpTT04uc3RyaW5naWZ5KGluaXRpYWxQYXRocyk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIHRoaXMubWVkaWFJdGVtcy5mb3JFYWNoKGZ1bmN0aW9uICh4KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICh4Lm1lZGlhUGF0aCA9PT0gJ25vdC1mb3VuZCcpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICBtZWRpYVBhdGhzLnB1c2goeyBwYXRoOiB4Lm1lZGlhUGF0aCwgaXNSZW1vdmVkOiB4LmlzUmVtb3ZlZCwgaXNOZXc6IHguaXNOZXcsIG1lZGlhVGV4dDogeC5tZWRpYVRleHQsIGFuY2hvcjogeC5hbmNob3IsIGF0dGFjaGVkRmlsZU5hbWU6IHguYXR0YWNoZWRGaWxlTmFtZSB9KTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gSlNPTi5zdHJpbmdpZnkobWVkaWFQYXRocyk7XHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgc2V0OiBmdW5jdGlvbiAodmFsdWVzKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBtZWRpYVBhdGhzID0gdmFsdWVzIHx8IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBzaWduYWwgPSAkLkRlZmVycmVkKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIGl0ZW1zID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIGxlbmd0aCA9IDA7XHJcbiAgICAgICAgICAgICAgICAgICAgbWVkaWFQYXRocy5mb3JFYWNoKGZ1bmN0aW9uICh4LCBpKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGl0ZW1zLnB1c2goeyBuYW1lOiAnICcgKyB4LnBhdGgsIG1pbWU6ICcnLCBtZWRpYVBhdGg6ICcnLCBhbmNob3I6IHguYW5jaG9yLCBhdHRhY2hlZEZpbGVOYW1lOiB4LmF0dGFjaGVkRmlsZU5hbWUgfSk7IC8vIGRvbid0IHJlbW92ZSB0aGUgc3BhY2UuIFNvbWV0aGluZyBkaWZmZXJlbnQgaXMgbmVlZGVkIG9yIGl0IHdvbnQgcmVhY3Qgd2hlbiB0aGUgcmVhbCBuYW1lIGFycml2ZXMuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHByb21pc2UgPSAkLndoZW4oc2lnbmFsKS5kb25lKGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICQuYWpheCh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiBtZWRpYUl0ZW1VcmwgKyBcIj9wYXRoPVwiICsgZW5jb2RlVVJJQ29tcG9uZW50KHgucGF0aCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnR0VUJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzdWNjZXNzOiBmdW5jdGlvbiAoZGF0YSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhLnZ1ZWtleSA9IGRhdGEubmFtZSArIGkudG9TdHJpbmcoKTsgLy8gQmVjYXVzZSBhIHVuaXF1ZSBrZXkgaXMgcmVxdWlyZWQgYnkgVnVlIG9uIHYtZm9yIFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhLm1lZGlhVGV4dCA9IHgubWVkaWFUZXh0OyAvLyBUaGlzIHZhbHVlIGlzIG5vdCByZXR1cm5lZCBmcm9tIHRoZSBhamF4IGNhbGwuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGEuYW5jaG9yID0geC5hbmNob3I7IC8vIFRoaXMgdmFsdWUgaXMgbm90IHJldHVybmVkIGZyb20gdGhlIGFqYXggY2FsbC5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS5hdHRhY2hlZEZpbGVOYW1lID0geC5hdHRhY2hlZEZpbGVOYW1lOy8vIFRoaXMgdmFsdWUgaXMgbm90IHJldHVybmVkIGZyb20gdGhlIGFqYXggY2FsbC5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaXRlbXMuc3BsaWNlKGksIDEsIGRhdGEpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoaXRlbXMubGVuZ3RoID09PSArK2xlbmd0aCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaXRlbXMuZm9yRWFjaChmdW5jdGlvbiAoeCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYubWVkaWFJdGVtcy5wdXNoKHgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLmluaXRpYWxpemVkID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZXJyb3I6IGZ1bmN0aW9uIChlcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmxvZyhKU09OLnN0cmluZ2lmeShlcnJvcikpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtcy5zcGxpY2UoaSwgMSwgeyBuYW1lOiB4LnBhdGgsIG1pbWU6ICcnLCBtZWRpYVBhdGg6ICdub3QtZm91bmQnLCBtZWRpYVRleHQ6ICcnLCBhbmNob3I6IHsgeDogMC41LCB5OiAwLjUgfSwgYXR0YWNoZWRGaWxlTmFtZTogeC5hdHRhY2hlZEZpbGVOYW1lIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoaXRlbXMubGVuZ3RoID09PSArK2xlbmd0aCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaXRlbXMuZm9yRWFjaChmdW5jdGlvbiAoeCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYubWVkaWFJdGVtcy5wdXNoKHgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLmluaXRpYWxpemVkID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgc2lnbmFsLnJlc29sdmUoKTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgZmlsZVNpemU6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgIHJldHVybiBNYXRoLnJvdW5kKHRoaXMuc2VsZWN0ZWRNZWRpYS5zaXplIC8gMTAyNCk7XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGNhbkFkZE1lZGlhOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgbm9uUmVtb3ZlZE1lZGlhSXRlbXMgPSBbXTtcclxuICAgICAgICAgICAgICAgIGZvciAodmFyIGkgPSAwOyBpIDwgdGhpcy5tZWRpYUl0ZW1zLmxlbmd0aDsgaSsrKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKCF0aGlzLm1lZGlhSXRlbXNbaV0uaXNSZW1vdmVkKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG5vblJlbW92ZWRNZWRpYUl0ZW1zLnB1c2godGhpcy5tZWRpYUl0ZW1zW2ldKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgcmV0dXJuIG5vblJlbW92ZWRNZWRpYUl0ZW1zLmxlbmd0aCA9PT0gMCB8fCBub25SZW1vdmVkTWVkaWFJdGVtcy5sZW5ndGggPiAwICYmIGFsbG93TXVsdGlwbGU7XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIHRodW1iU2l6ZTogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuIHRoaXMuc21hbGxUaHVtYnMgPyAxMjAgOiAyNDA7XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGN1cnJlbnRQcmVmczoge1xyXG4gICAgICAgICAgICAgICAgZ2V0OiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc21hbGxUaHVtYnM6IHRoaXMuc21hbGxUaHVtYnNcclxuICAgICAgICAgICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIHNldDogZnVuY3Rpb24gKG5ld1ByZWZzKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKCFuZXdQcmVmcykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIHRoaXMuc21hbGxUaHVtYnMgPSBuZXdQcmVmcy5zbWFsbFRodW1icztcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH0sXHJcbiAgICAgICAgbW91bnRlZDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcblxyXG4gICAgICAgICAgICBzZWxmLnBhdGhzID0gaW5pdGlhbFBhdGhzO1xyXG5cclxuICAgICAgICAgICAgc2VsZi4kb24oJ3NlbGVjdEFuZERlbGV0ZU1lZGlhUmVxdWVzdGVkJywgZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdEFuZERlbGV0ZU1lZGlhKG1lZGlhKTtcclxuICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICBzZWxmLiRvbignc2VsZWN0TWVkaWFSZXF1ZXN0ZWQnLCBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0TWVkaWEobWVkaWEpO1xyXG4gICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgIHZhciBzZWxlY3RvciA9ICcjJyArIGlkT2ZVcGxvYWRCdXR0b247XHJcbiAgICAgICAgICAgIHZhciBlZGl0b3JJZCA9IG1lZGlhRmllbGRFZGl0b3IuYXR0cignaWQnKTtcclxuICAgICAgICAgICAgdmFyIGNodW5rZWRGaWxlVXBsb2FkSWQgPSByYW5kb21VVUlEKCk7XHJcblxyXG4gICAgICAgICAgICAkKHNlbGVjdG9yKVxyXG4gICAgICAgICAgICAgICAgLmZpbGV1cGxvYWQoe1xyXG4gICAgICAgICAgICAgICAgICAgIGxpbWl0Q29uY3VycmVudFVwbG9hZHM6IDIwLFxyXG4gICAgICAgICAgICAgICAgICAgIGRyb3Bab25lOiAkKCcjJyArIGVkaXRvcklkKSxcclxuICAgICAgICAgICAgICAgICAgICBkYXRhVHlwZTogJ2pzb24nLFxyXG4gICAgICAgICAgICAgICAgICAgIHVybDogdXBsb2FkQWN0aW9uLFxyXG4gICAgICAgICAgICAgICAgICAgIG1heENodW5rU2l6ZTogbWF4VXBsb2FkQ2h1bmtTaXplLFxyXG4gICAgICAgICAgICAgICAgICAgIGFkZDogZnVuY3Rpb24gKGUsIGRhdGEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGNvdW50ID0gZGF0YS5maWxlcy5sZW5ndGg7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBmb3IgKGkgPSAwOyBpIDwgY291bnQ7IGkrKykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS5maWxlc1tpXS51cGxvYWROYW1lID1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLmdldFVuaXF1ZUlkKCkgKyBkYXRhLmZpbGVzW2ldLm5hbWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhLmZpbGVzW2ldLmF0dGFjaGVkRmlsZU5hbWUgPSBkYXRhLmZpbGVzW2ldLm5hbWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS5zdWJtaXQoKTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGZvcm1EYXRhOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBhbnRpRm9yZ2VyeVRva2VuID0gJChcImlucHV0W25hbWU9X19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW5dXCIpLnZhbCgpO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHsgbmFtZTogJ3BhdGgnLCB2YWx1ZTogdGVtcFVwbG9hZEZvbGRlciB9LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgeyBuYW1lOiAnX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW4nLCB2YWx1ZTogYW50aUZvcmdlcnlUb2tlbiB9LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgeyBuYW1lOiAnX19jaHVua2VkRmlsZVVwbG9hZElkJywgdmFsdWU6IGNodW5rZWRGaWxlVXBsb2FkSWQgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgXTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGRvbmU6IGZ1bmN0aW9uIChlLCBkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBuZXdNZWRpYUl0ZW1zID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBlcnJvcm1zZyA9IFwiXCI7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoZGF0YS5yZXN1bHQuZmlsZXMubGVuZ3RoID4gMCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBkYXRhLnJlc3VsdC5maWxlcy5sZW5ndGg7IGkrKykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGEucmVzdWx0LmZpbGVzW2ldLmlzTmV3ID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvL2lmIGVycm9yIGlzIGRlZmluZWQgcHJvYmFibHkgdGhlIGZpbGUgdHlwZSBpcyBub3QgYWxsb3dlZFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChkYXRhLnJlc3VsdC5maWxlc1tpXS5lcnJvciA9PT0gdW5kZWZpbmVkIHx8IGRhdGEucmVzdWx0LmZpbGVzW2ldLmVycm9yID09PSBudWxsKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGEucmVzdWx0LmZpbGVzW2ldLmF0dGFjaGVkRmlsZU5hbWUgPSBkYXRhLmZpbGVzW2ldLmF0dGFjaGVkRmlsZU5hbWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5ld01lZGlhSXRlbXMucHVzaChkYXRhLnJlc3VsdC5maWxlc1tpXSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGVsc2VcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZXJyb3Jtc2cgKz0gZGF0YS5yZXN1bHQuZmlsZXNbaV0uZXJyb3IgKyBcIlxcblwiO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoZXJyb3Jtc2cgIT09IFwiXCIpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGFsZXJ0KGVycm9ybXNnKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmxvZyhuZXdNZWRpYUl0ZW1zKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKG5ld01lZGlhSXRlbXMubGVuZ3RoID4gMSAmJiBhbGxvd011bHRpcGxlID09PSBmYWxzZSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYWxlcnQoJCgnI29ubHlPbmVJdGVtTWVzc2FnZScpLnZhbCgpKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1lZGlhRmllbGRBcHAubWVkaWFJdGVtcy5wdXNoKG5ld01lZGlhSXRlbXNbMF0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbWVkaWFGaWVsZEFwcC5pbml0aWFsaXplZCA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZWRpYUZpZWxkQXBwLm1lZGlhSXRlbXMgPSBtZWRpYUZpZWxkQXBwLm1lZGlhSXRlbXMuY29uY2F0KG5ld01lZGlhSXRlbXMpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbWVkaWFGaWVsZEFwcC5pbml0aWFsaXplZCA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGVycm9yOiBmdW5jdGlvbiAoanFYSFIsIHRleHRTdGF0dXMsIGVycm9yVGhyb3duKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKCdFcnJvciBvbiB1cGxvYWQuJyk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKGpxWEhSKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2codGV4dFN0YXR1cyk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKGVycm9yVGhyb3duKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICB9KVxyXG4gICAgICAgICAgICAgICAgLm9uKCdmaWxldXBsb2FkY2h1bmtiZWZvcmVzZW5kJywgKGUsIG9wdGlvbnMpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICBsZXQgZmlsZSA9IG9wdGlvbnMuZmlsZXNbMF07XHJcbiAgICAgICAgICAgICAgICAgICAgLy8gSGVyZSB3ZSByZXBsYWNlIHRoZSBibG9iIHdpdGggYSBGaWxlIG9iamVjdCB0byBlbnN1cmUgdGhlIGZpbGUgbmFtZSBhbmQgb3RoZXJzIGFyZSBwcmVzZXJ2ZWQgZm9yIHRoZSBiYWNrZW5kLlxyXG4gICAgICAgICAgICAgICAgICAgIG9wdGlvbnMuYmxvYiA9IG5ldyBGaWxlKFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBbb3B0aW9ucy5ibG9iXSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgZmlsZS5uYW1lLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiBmaWxlLnR5cGUsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsYXN0TW9kaWZpZWQ6IGZpbGUubGFzdE1vZGlmaWVkLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgIH0sXHJcbiAgICAgICAgbWV0aG9kczoge1xyXG4gICAgICAgICAgICBzZWxlY3RNZWRpYTogZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWEgPSBtZWRpYTtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgZ2V0VW5pcXVlSWQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgIHJldHVybiAneHh4eHh4eHgteHh4eC00eHh4LXl4eHgteHh4eHh4eHh4eHh4Jy5yZXBsYWNlKC9beHldL2csIGZ1bmN0aW9uIChjKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIHIgPSBNYXRoLnJhbmRvbSgpICogMTYgfCAwLCB2ID0gYyA9PT0gJ3gnID8gciA6IChyICYgMHgzIHwgMHg4KTtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gdi50b1N0cmluZygxNik7XHJcbiAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgcmVtb3ZlU2VsZWN0ZWQ6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdmFyIHJlbW92ZWQgPSB7fTtcclxuICAgICAgICAgICAgICAgIGlmICh0aGlzLnNlbGVjdGVkTWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgaW5kZXggPSB0aGlzLm1lZGlhSXRlbXMgJiYgdGhpcy5tZWRpYUl0ZW1zLmluZGV4T2YodGhpcy5zZWxlY3RlZE1lZGlhKTtcclxuICAgICAgICAgICAgICAgICAgICBpZiAoaW5kZXggPiAtMSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZW1vdmVkID0gdGhpcy5tZWRpYUl0ZW1zW2luZGV4XTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmVtb3ZlZC5pc1JlbW92ZWQgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAvL3RoaXMubWVkaWFJdGVtcy5zcGxpY2UoW2luZGV4XSwgMSwgcmVtb3ZlZCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMubWVkaWFJdGVtcy5zcGxpY2UoaW5kZXgsIDEpO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgIC8vIFRoZSByZW1vdmUgYnV0dG9uIGNhbiBhbHNvIHJlbW92ZSBhIHVuaXF1ZSBtZWRpYSBpdGVtXHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKHRoaXMubWVkaWFJdGVtcy5sZW5ndGggPT09IDEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmVtb3ZlZCA9IHRoaXMubWVkaWFJdGVtc1tpbmRleF07XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJlbW92ZWQuaXNSZW1vdmVkID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgLy90aGlzLm1lZGlhSXRlbXMuc3BsaWNlKDAsIDEsIHJlbW92ZWQpOyAgICAgICAgICAgICAgICAgICAgICAgIFxyXG4gICAgICAgICAgICA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ZnJlc2ggdG8gcmVjYWxjIGhlaWdodHMuXHJcbiAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yID0ge1xyXG4gICAgICAgICAgICAgICAgICAgIHg6IHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IueCxcclxuICAgICAgICAgICAgICAgICAgICB5OiB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yLnlcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIHRoaXMuYmFja3VwQW5jaG9yID0gdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvcjtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgY2FuY2VsQW5jaG9yaW5nTW9kYWw6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5hbmNob3JpbmdNb2RhbC5oaWRlKCk7XHJcbiAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yID0gdGhpcy5iYWNrdXBBbmNob3I7XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIHJlc2V0QW5jaG9yOiBmdW5jdGlvbiAoZXZlbnQpIHtcclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IgPSB7IHg6IDAuNSwgeTogMC41IH07XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIG9uQW5jaG9yRHJvcDogZnVuY3Rpb24gKGV2ZW50KSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgaW1hZ2UgPSB0aGlzLiRyZWZzLmFuY2hvckltYWdlO1xyXG4gICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvciA9IHtcclxuICAgICAgICAgICAgICAgICAgICB4OiBldmVudC5vZmZzZXRYIC8gaW1hZ2UuY2xpZW50V2lkdGgsXHJcbiAgICAgICAgICAgICAgICAgICAgeTogZXZlbnQub2Zmc2V0WSAvIGltYWdlLmNsaWVudEhlaWdodFxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBhbmNob3JMZWZ0OiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICBpZiAodGhpcy4kcmVmcy5hbmNob3JJbWFnZSAmJiB0aGlzLiRyZWZzLm1vZGFsQm9keSAmJiB0aGlzLnNlbGVjdGVkTWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAvLyBXaGVuIGltYWdlIGlzIHNocnVuayBjb21wYXJlIGFnYWluc3QgdGhlIG1vZGFsIGJvZHkuXHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIG9mZnNldCA9ICh0aGlzLiRyZWZzLm1vZGFsQm9keS5jbGllbnRXaWR0aCAtIHRoaXMuJHJlZnMuYW5jaG9ySW1hZ2UuY2xpZW50V2lkdGgpIC8gMjtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgcG9zaXRpb24gPSAodGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvci54ICogdGhpcy4kcmVmcy5hbmNob3JJbWFnZS5jbGllbnRXaWR0aCkgKyBvZmZzZXQ7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKHBvc2l0aW9uIDwgMTcpIHsgLy8gQWRqdXN0IHNvIHRoZSB0YXJnZXQgZG9lc24ndCBzaG93IG91dHNpZGUgaW1hZ2UuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHBvc2l0aW9uID0gMTc7XHJcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcG9zaXRpb24gPSBwb3NpdGlvbiAtIDg7IC8vIEFkanVzdCB0byBoaXQgdGhlIG1vdXNlIHBvaW50ZXIuXHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBwb3NpdGlvbiArICdweCc7XHJcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiAnMCc7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGFuY2hvclRvcDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgaWYgKHRoaXMuJHJlZnMuYW5jaG9ySW1hZ2UgJiYgdGhpcy5zZWxlY3RlZE1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIHBvc2l0aW9uID0gdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvci55ICogdGhpcy4kcmVmcy5hbmNob3JJbWFnZS5jbGllbnRIZWlnaHQ7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKHBvc2l0aW9uIDwgMTUpIHsgLy8gQWRqdXN0bWVudCBzbyB0aGUgdGFyZ2V0IGRvZXNuJ3Qgc2hvdyBvdXRzaWRlIGltYWdlLlxyXG4gICAgICAgICAgICAgICAgICAgICAgICBwb3NpdGlvbiA9IDE1O1xyXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHBvc2l0aW9uID0gcG9zaXRpb24gKyA1OyAvLyBBZGp1c3QgdG8gaGl0IHRoZSBtb3VzZSBwb2ludGVyLlxyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gcG9zaXRpb24gKyAncHgnO1xyXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gJzAnO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBzZXRBbmNob3I6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdmFyIGltYWdlID0gdGhpcy4kcmVmcy5hbmNob3JJbWFnZTtcclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IgPSB7XHJcbiAgICAgICAgICAgICAgICAgICAgeDogZXZlbnQub2Zmc2V0WCAvIGltYWdlLmNsaWVudFdpZHRoLFxyXG4gICAgICAgICAgICAgICAgICAgIHk6IGV2ZW50Lm9mZnNldFkgLyBpbWFnZS5jbGllbnRIZWlnaHRcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgYWRkTWVkaWFGaWxlczogZnVuY3Rpb24gKGZpbGVzKSB7XHJcbiAgICAgICAgICAgICAgICBpZiAoKGZpbGVzLmxlbmd0aCA+IDEpICYmIChhbGxvd011bHRpcGxlID09PSBmYWxzZSkpIHtcclxuICAgICAgICAgICAgICAgICAgICBhbGVydCgkKCcjb25seU9uZUl0ZW1NZXNzYWdlJykudmFsKCkpO1xyXG4gICAgICAgICAgICAgICAgICAgIG1lZGlhRmllbGRBcHAubWVkaWFJdGVtcy5wdXNoKGZpbGVzWzBdKTtcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUZpZWxkQXBwLmluaXRpYWxpemVkID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgbWVkaWFGaWVsZEFwcC5tZWRpYUl0ZW1zID0gbWVkaWFGaWVsZEFwcC5tZWRpYUl0ZW1zLmNvbmNhdChmaWxlcyk7XHJcbiAgICAgICAgICAgICAgICAgICAgbWVkaWFGaWVsZEFwcC5pbml0aWFsaXplZCA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIHNlbGVjdEFuZERlbGV0ZU1lZGlhOiBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0ZWRNZWRpYSA9IG1lZGlhO1xyXG4gICAgICAgICAgICAgICAgLy8gc2V0VGltZW91dCBiZWNhdXNlIHNvbWV0aW1lcyBcclxuICAgICAgICAgICAgICAgIC8vIHJlbW92ZVNlbGVjdGVkIHdhcyBjYWxsZWQgZXZlbiBiZWZvcmUgdGhlIG1lZGlhIHdhcyBzZXQuXHJcbiAgICAgICAgICAgICAgICBzZXRUaW1lb3V0KGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICBzZWxmLnJlbW92ZVNlbGVjdGVkKCk7XHJcbiAgICAgICAgICAgICAgICB9LCAxMDApO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSxcclxuICAgICAgICB3YXRjaDoge1xyXG4gICAgICAgICAgICBtZWRpYUl0ZW1zOiB7XHJcbiAgICAgICAgICAgICAgICBkZWVwOiB0cnVlLFxyXG4gICAgICAgICAgICAgICAgaGFuZGxlcigpIHtcclxuICAgICAgICAgICAgICAgICAgICAvLyBUcmlnZ2VyIHByZXZpZXcgcmVuZGVyaW5nXHJcbiAgICAgICAgICAgICAgICAgICAgc2V0VGltZW91dChmdW5jdGlvbiAoKSB7ICQoZG9jdW1lbnQpLnRyaWdnZXIoJ2NvbnRlbnRwcmV2aWV3OnJlbmRlcicpOyB9LCAxMDApO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBjdXJyZW50UHJlZnM6IGZ1bmN0aW9uIChuZXdQcmVmcykge1xyXG4gICAgICAgICAgICAgICAgbG9jYWxTdG9yYWdlLnNldEl0ZW0oJ21lZGlhRmllbGRQcmVmcycsIEpTT04uc3RyaW5naWZ5KG5ld1ByZWZzKSk7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9XHJcbiAgICB9KSk7XHJcbn1cclxuIiwiZnVuY3Rpb24gaW5pdGlhbGl6ZU1lZGlhRmllbGQoZWwsIG1vZGFsQm9keUVsZW1lbnQsIG1lZGlhSXRlbVVybCwgYWxsb3dNdWx0aXBsZSwgYWxsb3dNZWRp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aHVtYnM6IGZhbHNlLFxyXG4gICAgICAgICAgICBpZFByZWZpeDogaWRwcmVmaXgsXHJcbiAgICAgICAgICAgIGluaXRpYWxpemVkOiBmYWxzZSxcclxuICAgICAgICAgICAgYWxsb3dNZWRpYVRleHQ6IGFsbG93TWVkaWFUZXh0LFxyXG4gICAgICAgICAgICBiYWNrdXBNZWRpYVRleHQ6ICcnLFxyXG4gICAgICAgICAgICBhbGxvd0FuY2hvcnM6IGFsbG93QW5jaG9ycyxcclxuICAgICAgICAgICAgYmFja3VwQW5jaG9yOiBudWxsLFxyXG4gICAgICAgICAgICBtZWRpYVRleHRNb2RhbDogbnVsbCxcclxuICAgICAgICAgICAgYW5jaG9yaW5nTW9kYWw6IG51bGxcclxuICAgICAgICB9LFxyXG4gICAgICAgIGNyZWF0ZWQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG5cclxuICAgICAgICAgICAgc2VsZi5jdXJyZW50UHJlZnMgPSBKU09OLnBhcnNlKGxvY2FsU3RvcmFnZS5nZXRJdGVtKCdtZWRpYUZpZWxkUHJlZnMnKSk7XHJcbiAgICAgICAgfSxcclxuICAgICAgICBjb21wdXRlZDoge1xyXG4gICAgICAgICAgICBwYXRoczoge1xyXG4gICAgICAgICAgICAgICAgZ2V0OiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIG1lZGlhUGF0aHMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICBpZiAoIXRoaXMuaW5pdGlhbGl6ZWQpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIEpTT04uc3RyaW5naWZ5KGluaXRpYWxQYXRocyk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIHRoaXMubWVkaWFJdGVtcy5mb3JFYWNoKGZ1bmN0aW9uICh4KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICh4Lm1lZGlhUGF0aCA9PT0gJ25vdC1mb3VuZCcpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICBtZWRpYVBhdGhzLnB1c2goeyBwYXRoOiB4Lm1lZGlhUGF0aCwgbWVkaWFUZXh0OiB4Lm1lZGlhVGV4dCwgYW5jaG9yOiB4LmFuY2hvciB9KTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gSlNPTi5zdHJpbmdpZnkobWVkaWFQYXRocyk7XHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgc2V0OiBmdW5jdGlvbiAodmFsdWVzKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBtZWRpYVBhdGhzID0gdmFsdWVzIHx8IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBzaWduYWwgPSAkLkRlZmVycmVkKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIGl0ZW1zID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIGxlbmd0aCA9IDA7XHJcbiAgICAgICAgICAgICAgICAgICAgbWVkaWFQYXRocy5mb3JFYWNoKGZ1bmN0aW9uICh4LCBpKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGl0ZW1zLnB1c2goeyBuYW1lOiAnICcgKyB4LnBhdGgsIG1pbWU6ICcnLCBtZWRpYVBhdGg6ICcnIH0pOyAvLyBkb24ndCByZW1vdmUgdGhlIHNwYWNlLiBTb21ldGhpbmcgZGlmZmVyZW50IGlzIG5lZWRlZCBvciBpdCB3b250IHJlYWN0IHdoZW4gdGhlIHJlYWwgbmFtZSBhcnJpdmVzLlxyXG4gICAgICAgICAgICAgICAgICAgICAgICBwcm9taXNlID0gJC53aGVuKHNpZ25hbCkuZG9uZShmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAkLmFqYXgoe1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogbWVkaWFJdGVtVXJsICsgXCI/cGF0aD1cIiArIGVuY29kZVVSSUNvbXBvbmVudCh4LnBhdGgpLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJ0dFVCcsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc3VjY2VzczogZnVuY3Rpb24gKGRhdGEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS52dWVrZXkgPSBkYXRhLm5hbWUgKyBpLnRvU3RyaW5nKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGEubWVkaWFUZXh0ID0geC5tZWRpYVRleHQ7IC8vIFRoaXMgdmFsdWUgaXMgbm90IHJldHVybmVkIGZyb20gdGhlIGFqYXggY2FsbC5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS5hbmNob3IgPSB4LmFuY2hvcjsgLy8gVGhpcyB2YWx1ZSBpcyBub3QgcmV0dXJuZWQgZnJvbSB0aGUgYWpheCBjYWxsLlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtcy5zcGxpY2UoaSwgMSwgZGF0YSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpdGVtcy5sZW5ndGggPT09ICsrbGVuZ3RoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtcy5mb3JFYWNoKGZ1bmN0aW9uICh5KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5tZWRpYUl0ZW1zLnB1c2goeSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuaW5pdGlhbGl6ZWQgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlcnJvcjogZnVuY3Rpb24gKGVycm9yKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKGVycm9yKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaXRlbXMuc3BsaWNlKGksIDEsIHsgbmFtZTogeC5wYXRoLCBtaW1lOiAnJywgbWVkaWFQYXRoOiAnbm90LWZvdW5kJywgbWVkaWFUZXh0OiAnJywgYW5jaG9yOiB7IHg6IDAsIHk6IDAgfSB9KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGl0ZW1zLmxlbmd0aCA9PT0gKytsZW5ndGgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGl0ZW1zLmZvckVhY2goZnVuY3Rpb24gKHgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLm1lZGlhSXRlbXMucHVzaCh4KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5pbml0aWFsaXplZCA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIFxyXG4gICAgICAgICAgICAgICAgICAgIHNpZ25hbC5yZXNvbHZlKCk7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGZpbGVTaXplOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICByZXR1cm4gTWF0aC5yb3VuZCh0aGlzLnNlbGVjdGVkTWVkaWEuc2l6ZSAvIDEwMjQpO1xyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBjYW5BZGRNZWRpYTogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuIHRoaXMubWVkaWFJdGVtcy5sZW5ndGggPT09IDAgfHwgdGhpcy5tZWRpYUl0ZW1zLmxlbmd0aCA+IDAgJiYgYWxsb3dNdWx0aXBsZTtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgdGh1bWJTaXplOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICByZXR1cm4gdGhpcy5zbWFsbFRodW1icyA/IDEyMCA6IDI0MDtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgY3VycmVudFByZWZzOiB7XHJcbiAgICAgICAgICAgICAgICBnZXQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzbWFsbFRodW1iczogdGhpcy5zbWFsbFRodW1ic1xyXG4gICAgICAgICAgICAgICAgICAgIH07XHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgc2V0OiBmdW5jdGlvbiAobmV3UHJlZnMpIHtcclxuICAgICAgICAgICAgICAgICAgICBpZiAoIW5ld1ByZWZzKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5zbWFsbFRodW1icyA9IG5ld1ByZWZzLnNtYWxsVGh1bWJzO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSxcclxuICAgICAgICBtb3VudGVkOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuXHJcbiAgICAgICAgICAgIHNlbGYucGF0aHMgPSBpbml0aWFsUGF0aHM7XHJcblxyXG4gICAgICAgICAgICBzZWxmLiRvbignc2VsZWN0QW5kRGVsZXRlTWVkaWFSZXF1ZXN0ZWQnLCBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0QW5kRGVsZXRlTWVkaWEobWVkaWEpO1xyXG4gICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgIHNlbGYuJG9uKCdzZWxlY3RNZWRpYVJlcXVlc3RlZCcsIGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RNZWRpYShtZWRpYSk7XHJcbiAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgc2VsZi4kb24oJ2ZpbGVzVXBsb2FkZWQnLCBmdW5jdGlvbiAoZmlsZXMpIHtcclxuICAgICAgICAgICAgICAgIHNlbGYuYWRkTWVkaWFGaWxlcyhmaWxlcyk7XHJcbiAgICAgICAgICAgIH0pO1xyXG4gICAgICAgIH0sXHJcbiAgICAgICAgbWV0aG9kczoge1xyXG4gICAgICAgICAgICBzZWxlY3RNZWRpYTogZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWEgPSBtZWRpYTtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgc2hvd01vZGFsOiBmdW5jdGlvbiAoZXZlbnQpIHtcclxuICAgICAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuICAgICAgICAgICAgICAgIGlmIChzZWxmLmNhbkFkZE1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgJChcIiNtZWRpYUFwcFwiKS5hcHBlbmRUbygkKG1vZGFsQm9keUVsZW1lbnQpLmZpbmQoJy5tb2RhbC1ib2R5JykpO1xyXG4gICAgICAgICAgICAgICAgICAgICQoXCIjbWVkaWFBcHBcIikuc2hvdygpO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICB2YXIgbW9kYWwgPSBuZXcgYm9vdHN0cmFwLk1vZGFsKG1vZGFsQm9keUVsZW1lbnQpO1xyXG4gICAgICAgICAgICAgICAgICAgIG1vZGFsLnNob3coKTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgJChtb2RhbEJvZHlFbGVtZW50KS5maW5kKCcubWVkaWFGaWVsZFNlbGVjdEJ1dHRvbicpLm9mZignY2xpY2snKS5vbignY2xpY2snLCBmdW5jdGlvbiAodikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLmFkZE1lZGlhRmlsZXMobWVkaWFBcHAuc2VsZWN0ZWRNZWRpYXMpO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgLy8gd2UgZG9uJ3Qgd2FudCB0aGUgaW5jbHVkZWQgbWVkaWFzIHRvIGJlIHN0aWxsIHNlbGVjdGVkIHRoZSBuZXh0IHRpbWUgd2Ugb3BlbiB0aGUgbW9kYWwuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG1lZGlhQXBwLnNlbGVjdGVkTWVkaWFzID0gW107XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBtb2RhbC5oaWRlKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB0cnVlO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBzaG93TWVkaWFUZXh0TW9kYWw6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5tZWRpYVRleHRNb2RhbCA9IG5ldyBib290c3RyYXAuTW9kYWwodGhpcy4kcmVmcy5tZWRpYVRleHRNb2RhbCk7XHJcbiAgICAgICAgICAgICAgICB0aGlzLm1lZGlhVGV4dE1vZGFsLnNob3coKTtcclxuICAgICAgICAgICAgICAgIHRoaXMuYmFja3VwTWVkaWFUZXh0ID0gdGhpcy5zZWxlY3RlZE1lZGlhLm1lZGlhVGV4dDtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgY2FuY2VsTWVkaWFUZXh0TW9kYWw6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5tZWRpYVRleHRNb2RhbC5oaWRlKCk7XHJcbiAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWEubWVkaWFUZXh0ID0gdGhpcy5iYWNrdXBNZWRpYVRleHQ7XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIHNob3dBbmNob3JNb2RhbDogZnVuY3Rpb24gKGV2ZW50KSB7XHJcbiAgICAgICAgICAgICAgICB0aGlzLmFuY2hvcmluZ01vZGFsID0gbmV3IGJvb3RzdHJhcC5Nb2RhbCh0aGlzLiRyZWZzLmFuY2hvcmluZ01vZGFsKTtcclxuICAgICAgICAgICAgICAgIHRoaXMuYW5jaG9yaW5nTW9kYWwuc2hvdygpO1xyXG4gICAgICAgICAgICAgICAgLy8gQ2F1c2UgYSByZWZyZXNoIHRvIHJlY2FsYyBoZWlnaHRzLlxyXG4gICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvciA9IHtcclxuICAgICAgICAgICAgICAgICAgeDogdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvci54LFxyXG4gICAgICAgICAgICAgICAgICB5OiB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yLnlcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIHRoaXMuYmFja3VwQW5jaG9yID0gdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvcjtcclxuICAgICAgICAgICAgfSwgICAgICAgICAgICBcclxuICAgICAgICAgICAgY2FuY2VsQW5jaG9yaW5nTW9kYWw6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5hbmNob3JpbmdNb2RhbC5oaWRlKCk7XHJcbiAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yID0gdGhpcy5iYWNrdXBBbmNob3I7XHJcbiAgICAgICAgICAgIH0sICAgICAgICAgICAgXHJcbiAgICAgICAgICAgIHJlc2V0QW5jaG9yOiBmdW5jdGlvbiAoZXZlbnQpIHtcclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IgPSB7IHg6IDAuNSwgeTogMC41IH07XHJcbiAgICAgICAgICAgIH0sICBcclxuICAgICAgICAgICAgb25BbmNob3JEcm9wOiBmdW5jdGlvbihldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdmFyIGltYWdlID0gdGhpcy4kcmVmcy5hbmNob3JJbWFnZTtcclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IgPSB7XHJcbiAgICAgICAgICAgICAgICAgICB4OiBldmVudC5vZmZzZXRYIC8gaW1hZ2UuY2xpZW50V2lkdGgsXHJcbiAgICAgICAgICAgICAgICAgICB5OiBldmVudC5vZmZzZXRZIC8gaW1hZ2UuY2xpZW50SGVpZ2h0XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGFuY2hvckxlZnQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgIGlmICh0aGlzLiRyZWZzLmFuY2hvckltYWdlICYmIHRoaXMuJHJlZnMubW9kYWxCb2R5ICYmIHRoaXMuc2VsZWN0ZWRNZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgIC8vIFdoZW4gaW1hZ2UgaXMgc2hydW5rIGNvbXBhcmUgYWdhaW5zdCB0aGUgbW9kYWwgYm9keS5cclxuICAgICAgICAgICAgICAgICAgICB2YXIgb2Zmc2V0ID0gKHRoaXMuJHJlZnMubW9kYWxCb2R5LmNsaWVudFdpZHRoIC0gdGhpcy4kcmVmcy5hbmNob3JJbWFnZS5jbGllbnRXaWR0aCkgLyAyO1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBwb3NpdGlvbiA9ICh0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yLnggKiB0aGlzLiRyZWZzLmFuY2hvckltYWdlLmNsaWVudFdpZHRoKSArIG9mZnNldDtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgYW5jaG9ySWNvbiA9IE1hdGgucm91bmQodGhpcy4kcmVmcy5tb2RhbEJvZHkucXVlcnlTZWxlY3RvcignLmljb24tbWVkaWEtYW5jaG9yJykuY2xpZW50V2lkdGgpO1xyXG4gICAgICAgICAgICAgICAgICAgIGlmKE51bWJlci5pc0ludGVnZXIoYW5jaG9ySWNvbikpXHJcbiAgICAgICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBwb3NpdGlvbiA9IHBvc2l0aW9uIC0gYW5jaG9ySWNvbi8yO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gcG9zaXRpb24gKyAncHgnO1xyXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gJzAnO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LCAgICAgICAgICAgIFxyXG4gICAgICAgICAgICBhbmNob3JUb3A6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgIGlmICh0aGlzLiRyZWZzLmFuY2hvckltYWdlICYmIHRoaXMuc2VsZWN0ZWRNZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBwb3NpdGlvbiA9IHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IueSAqIHRoaXMuJHJlZnMuYW5jaG9ySW1hZ2UuY2xpZW50SGVpZ2h0O1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBwb3NpdGlvbiArICdweCc7XHJcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiAnMCc7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIHNldEFuY2hvcjogZnVuY3Rpb24gKGV2ZW50KSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgaW1hZ2UgPSB0aGlzLiRyZWZzLmFuY2hvckltYWdlO1xyXG4gICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvciA9IHtcclxuICAgICAgICAgICAgICAgICAgICB4OiBldmVudC5vZmZzZXRYIC8gaW1hZ2UuY2xpZW50V2lkdGgsXHJcbiAgICAgICAgICAgICAgICAgICAgeTogZXZlbnQub2Zmc2V0WSAvIGltYWdlLmNsaWVudEhlaWdodFxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LCAgICAgICAgIFxyXG4gICAgICAgICAgICBhZGRNZWRpYUZpbGVzOiBmdW5jdGlvbiAoZmlsZXMpIHtcclxuICAgICAgICAgICAgICAgIGlmICgoZmlsZXMubGVuZ3RoID4gMSkgJiYgKGFsbG93TXVsdGlwbGUgPT09IGZhbHNlKSkge1xyXG4gICAgICAgICAgICAgICAgICAgIGFsZXJ0KCQoJyNvbmx5T25lSXRlbU1lc3NhZ2UnKS52YWwoKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgbWVkaWFGaWVsZEFwcC5tZWRpYUl0ZW1zLnB1c2goZmlsZXNbMF0pO1xyXG4gICAgICAgICAgICAgICAgICAgIG1lZGlhRmllbGRBcHAuaW5pdGlhbGl6ZWQgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUZpZWxkQXBwLm1lZGlhSXRlbXMgPSBtZWRpYUZpZWxkQXBwLm1lZGlhSXRlbXMuY29uY2F0KGZpbGVzKTtcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUZpZWxkQXBwLmluaXRpYWxpemVkID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgcmVtb3ZlU2VsZWN0ZWQ6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgaWYgKHRoaXMuc2VsZWN0ZWRNZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBpbmRleCA9IHRoaXMubWVkaWFJdGVtcyAmJiB0aGlzLm1lZGlhSXRlbXMuaW5kZXhPZih0aGlzLnNlbGVjdGVkTWVkaWEpO1xyXG4gICAgICAgICAgICAgICAgICAgIGlmIChpbmRleCA+IC0xKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMubWVkaWFJdGVtcy5zcGxpY2UoaW5kZXgsIDEpO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgIC8vIFRoZSByZW1vdmUgYnV0dG9uIGNhbiBhbHNvIHJlbW92ZSBhIHVuaXF1ZSBtZWRpYSBpdGVtXHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKHRoaXMubWVkaWFJdGVtcy5sZW5ndGggPT09IDEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5tZWRpYUl0ZW1zLnNwbGljZSgwLCAxKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWEgPSBudWxsO1xyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBzZWxlY3RBbmREZWxldGVNZWRpYTogZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcbiAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdGVkTWVkaWEgPSBtZWRpYTtcclxuICAgICAgICAgICAgICAgIC8vIHNldFRpbWVvdXQgYmVjYXVzZSBzb21ldGltZXMgcmVtb3ZlU2VsZWN0ZWQgd2FzIGNhbGxlZCBldmVuIGJlZm9yZSB0aGUgbWVkaWEgd2FzIHNldC5cclxuICAgICAgICAgICAgICAgIHNldFRpbWVvdXQoZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgIHNlbGYucmVtb3ZlU2VsZWN0ZWQoKTtcclxuICAgICAgICAgICAgICAgIH0sIDEwMCk7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9LFxyXG4gICAgICAgIHdhdGNoOiB7XHJcbiAgICAgICAgICAgIG1lZGlhSXRlbXM6IHtcclxuICAgICAgICAgICAgICAgIGRlZXA6IHRydWUsXHJcbiAgICAgICAgICAgICAgICBoYW5kbGVyICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAvLyBUcmlnZ2VyIHByZXZpZXcgcmVuZGVyaW5nXHJcbiAgICAgICAgICAgICAgICAgICAgc2V0VGltZW91dChmdW5jdGlvbiAoKSB7ICQoZG9jdW1lbnQpLnRyaWdnZXIoJ2NvbnRlbnRwcmV2aWV3OnJlbmRlcicpOyB9LCAxMDApOyBcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSwgICAgICAgICAgICBcclxuICAgICAgICAgICAgY3VycmVudFByZWZzOiBmdW5jdGlvbiAobmV3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RpYS1pdGVtcy1ncmlkXCIgPlxcXHJcbiAgICAgICAgICAgIDxsaSB2LWZvcj1cIm1lZGlhIGluIG1lZGlhSXRlbXNcIlxcXHJcbiAgICAgICAgICAgICAgICA6a2V5PVwibWVkaWEudnVla2V5XCIgXFxcclxuICAgICAgICAgICAgICAgIGNsYXNzPVwibWVkaWEtY29udGFpbmVyLW1haW4tbGlzdC1pdGVtIGNhcmQgcC0wXCJcXFxyXG4gICAgICAgICAgICAgICAgOnN0eWxlPVwie3dpZHRoOiB0aHVtYlNpemUgKyAyICsgXFwncHhcXCd9XCJcXFxyXG4gICAgICAgICAgICAgICAgOmNsYXNzPVwie3NlbGVjdGVkOiBzZWxlY3RlZE1lZGlhID09IG1lZGlhfVwiXFxcclxuICAgICAgICAgICAgICAgIHYtb246Y2xpY2s9XCJzZWxlY3RNZWRpYShtZWRpYSlcIiB2LWlmPVwiIW1lZGlhLmlzUmVtb3ZlZFwiPlxcXHJcbiAgICAgICAgICAgICAgICAgICAgPGRpdiB2LWlmPVwibWVkaWEubWVkaWFQYXRoIT09IFxcJ25vdC1mb3VuZFxcJ1wiPlxcXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJ0aHVtYi1jb250YWluZXJcIiA6c3R5bGU9XCJ7aGVpZ2h0OiB0aHVtYlNpemUgKyBcXCdweFxcJ31cIiA+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxpbWcgdi1pZj1cIm1lZGlhLm1pbWUuc3RhcnRzV2l0aChcXCdpbWFnZVxcJylcIiBcXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgOnNyYz1cImJ1aWxkTWVkaWFVcmwobWVkaWEudXJsLCB0aHVtYlNpemUpXCIgXFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDpkYXRhLW1pbWU9XCJtZWRpYS5taW1lXCJcXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgOnN0eWxlPVwie21heEhlaWdodDogdGh1bWJTaXplICsgXFwncHhcXCcgLCBtYXhXaWR0aDogdGh1bWJTaXplICsgXFwncHhcXCd9XCIvPlxcXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICA8aSB2LWVsc2UgOmNsYXNzPVwiZ2V0Zm9udEF3ZXNvbWVDbGFzc05hbWVGb3JGaWxlTmFtZShtZWRpYS5uYW1lLCBcXCdmYS00eFxcJylcIiA6ZGF0YS1taW1lPVwibWVkaWEubWltZVwiPjwvaT5cXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgPC9kaXY+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJtZWRpYS1jb250YWluZXItbWFpbi1pdGVtLXRpdGxlIGNhcmQtYm9keVwiPlxcXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPGEgaHJlZj1cImphdmFzY3JpcHQ6O1wiIGNsYXNzPVwiYnRuIGJ0bi1saWdodCBidG4tc20gZmxvYXQtZW5kIGlubGluZS1tZWRpYS1idXR0b24gZGVsZXRlLWJ1dHRvblwiXFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdi1vbjpjbGljay5zdG9wPVwic2VsZWN0QW5kRGVsZXRlTWVkaWEobWVkaWEpXCI+PGkgY2xhc3M9XCJmYS1zb2xpZCBmYS10cmFzaFwiIGFyaWEtaGlkZGVuPVwidHJ1ZVwiPjwvaT48L2E+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8YSA6aHJlZj1cIm1lZGlhLnVybFwiIHRhcmdldD1cIl9ibGFua1wiIGNsYXNzPVwiYnRuIGJ0bi1saWdodCBidG4tc20gZmxvYXQtZW5kIGlubGluZS1tZWRpYS1idXR0b24gdmlldy1idXR0b25cIlwiPjxpIGNsYXNzPVwiZmEtc29saWQgZmEtZG93bmxvYWRcIiBhcmlhLWhpZGRlbj1cInRydWVcIj48L2k+PC9hPiBcXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxzcGFuIGNsYXNzPVwibWVkaWEtZmlsZW5hbWUgY2FyZC10ZXh0IHNtYWxsXCIgOnRpdGxlPVwibWVkaWEubWVkaWFQYXRoXCI+e3sgbWVkaWEuaXNOZXcgPyBtZWRpYS5uYW1lLnN1YnN0cigzNikgOiBtZWRpYS5uYW1lIH19PC9zcGFuPlxcXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cXFxyXG4gICAgICAgICAgICAgICAgICAgIDwvZGl2PlxcXHJcbiAgICAgICAgICAgICAgICAgICAgPGRpdiB2LWVsc2U+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cInRodW1iLWNvbnRhaW5lciBmbGV4LWNvbHVtblwiIDpzdHlsZT1cIntoZWlnaHQ6IHRodW1iU2l6ZSArIFxcJ3B4XFwnfVwiPlxcXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICA8aSBjbGFzcz1cImZhLXNvbGlkIGZhLWJhbiB0ZXh0LWRhbmdlciBkLWJsb2NrXCIgYXJpYS1oaWRkZW49XCJ0cnVlXCI+PC9pPlxcXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICA8c3BhbiBjbGFzcz1cInRleHQtZGFuZ2VyIHNtYWxsIGQtYmxvY2tcIj57eyBULm1lZGlhTm90Rm91bmQgfX08L3NwYW4+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxzcGFuIGNsYXNzPVwidGV4dC1kYW5nZXIgc21hbGwgZC1ibG9jayB0ZXh0LWNlbnRlclwiPnt7IFQuZGlzY2FyZFdhcm5pbmcgfX08L3NwYW4+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgPC9kaXY+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1lZGlhLWNvbnRhaW5lci1tYWluLWl0ZW0tdGl0bGUgY2FyZC1ib2R5XCI+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxhIGhyZWY9XCJqYXZhc2NyaXB0OjtcIiBjbGFzcz1cImJ0biBidG4tbGlnaHQgYnRuLXNtIGZsb2F0LWVuZCBpbmxpbmUtbWVkaWEtYnV0dG9uIGRlbGV0ZS1idXR0b25cIlxcXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdi1vbjpjbGljay5zdG9wPVwic2VsZWN0QW5kRGVsZXRlTWVkaWEobWVkaWEpXCI+PGkgY2xhc3M9XCJmYS1zb2xpZCBmYS10cmFzaFwiIGFyaWEtaGlkZGVuPVwidHJ1ZVwiPjwvaT48L2E+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxzcGFuIGNsYXNzPVwibWVkaWEtZmlsZW5hbWUgY2FyZC10ZXh0IHNtYWxsIHRleHQtZGFuZ2VyXCIgOnRpdGxlPVwibWVkaWEubmFtZVwiPnt7IG1lZGlhLm5hbWUgfX08L3NwYW4+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgPC9kaXY+XFxcclxuICAgICAgICAgICAgICAgICAgIDwvZGl2PlxcXHJcbiAgICAgICAgICAgIDwvbGk+XFxcclxuICAgICAgICAgPC9kcmFnZ2FibGU+XFxcclxuICAgICAgIDwvZGl2PlxcXHJcbiAgICAnLFxyXG4gICAgZGF0YTogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgIHJldHVybiB7XHJcbiAgICAgICAgICAgIFQ6IHt9XHJcbiAgICAgICAgfTtcclxuICAgIH0sXHJcbiAgICBwcm9wczoge1xyXG4gICAgICAgIG1lZGlhSXRlbXM6IEFycmF5LFxyXG4gICAgICAgIHNlbGVjdGVkTWVkaWE6IE9iamVjdCxcclxuICAgICAgICB0aHVtYlNpemU6IE51bWJlcixcclxuICAgICAgICBpZFByZWZpeDogU3RyaW5nXHJcbiAgICB9LFxyXG4gICAgY3JlYXRlZDogZnVuY3Rpb24gKCkge1xyXG5cclxuICAgICAgICB2YXIgc2VsZiA9IHRoaXM7X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RlbC5lcnJvck1lc3NhZ2VcIj4gRXJyb3I6IHt7IG1vZGVsLmVycm9yTWVzc2FnZSB9fSA8L3NwYW4+IFxcXHJcbiAgICAgICAgICAgIDwvZGl2PiBcXFxyXG4gICAgICAgIDwvZGl2PiBcXFxyXG4gICAgICAgICcsXHJcbiAgICBwcm9wczoge1xyXG4gICAgICAgIG1vZGVsOiBPYmplY3QsXHJcbiAgICAgICAgdXBsb2FkSW5wdXRJZDogU3RyaW5nXHJcbiAgICB9LFxyXG4gICAgbW91bnRlZDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuICAgICAgICB2YXIgdXBsb2FkSW5wdXQgPSBkb2N1bWVudC5nZXRFbGVtZW50QnlJZChzZWxmLnVwbG9hZElucHV0SWQgPz8gJ2ZpbGV1cGxvYWQnKTtcclxuICAgICAgICAkKHVwbG9hZElucHV0KS5iaW5kKCdmaWxldXBsb2FkcHJvZ3Jlc3MnLCBmdW5jdGlvbiAoZSwgZGF0YSkge1xyXG4gICAgICAgICAgICBpZiAoZGF0YS5maWxlc1swXS5uYW1lICE9PSBzZWxmLm1vZGVsLm5hbWUpIHtcclxuICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgfSAgICAgICAgICAgIFxyXG4gICAgICAgICAgICBzZWxmLm1vZGVsLnBlcmNlbnRhZ2UgPSBwYXJzZUludChkYXRhLmxvYWRlZCAvIGRhdGEudG90YWwgKiAxMDAsIDEwKTtcclxuICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgJCh1cGxvYWRJbnB1dCkuYmluZCgnZmlsZXVwbG9hZGRvbmUnLCBmdW5jdGlvbiAoZSwgZGF0YSkge1xyXG4gICAgICAgICAgICBpZiAoZGF0YS5maWxlc1swXS5uYW1lICE9PSBzZWxmLm1vZGVsLm5hbWUpIHtcclxuICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBpZiAoZGF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S1zb2xpZCBmYS1jaGV2cm9uLWRvd25cIiBhcmlhLWhpZGRlbj1cInRydWVcIj48L2k+IFxcXHJcbiAgICAgICAgICAgICAgICAgICAgPC9kaXY+IFxcXHJcbiAgICAgICAgICAgICAgICAgICAgPGRpdiB2LXNob3c9XCIhZXhwYW5kZWRcIj4gXFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgPGkgY2xhc3M9XCJmYS1zb2xpZCBmYS1jaGV2cm9uLXVwXCIgYXJpYS1oaWRkZW49XCJ0cnVlXCI+PC9pPiBcXFxyXG4gICAgICAgICAgICAgICAgICAgIDwvZGl2PiBcXFxyXG4gICAgICAgICAgICAgICAgPC9kaXY+IFxcXHJcbiAgICAgICAgICAgIDwvZGl2PiBcXFxyXG4gICAgICAgICAgICA8ZGl2IGNsYXNzPVwiY2FyZC1ib2R5XCIgdi1zaG93PVwiZXhwYW5kZWRcIj4gXFxcclxuICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJkLWZsZXggZmxleC13cmFwXCI+IFxcXHJcbiAgICAgICAgICAgICAgICAgICAgPHVwbG9hZCA6dXBsb2FkLWlucHV0LWlkPVwidXBsb2FkSW5wdXRJZFwiIHYtZm9yPVwiZiBpbiBmaWxlc1wiIDprZXk9XCJmLm5hbWVcIiAgOm1vZGVsPVwiZlwiPjwvdXBsb2FkPiBcXFxyXG4gICAgICAgICAgICAgICAgPC9kaXYgPiBcXFxyXG4gICAgICAgICAgICA8L2Rpdj4gXFxcclxuICAgICAgICA8L2Rpdj4gXFxcclxuICAgICAgICAnLFxyXG4gICAgZGF0YTogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgIHJldHVybiB7XHJcbiAgICAgICAgICAgIGZpbGVzOiBbXSxcclxuICAgICAgICAgICAgVDoge30sXHJcbiAgICAgICAgICAgIGV4cGFuZGVkOiBmYWxzZSxcclxuICAgICAgICAgICAgcGVuZGluZ0NvdW50OiAwLFxyXG4gICAgICAgICAgICBlcnJvckNvdW50OiAwXHJcbi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gICAgdmFyIGFscmVhZHlJbkxpc3QgPSBzZWxmLmZpbGVzLnNvbWUoZnVuY3Rpb24gKGYpIHtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gZi5uYW1lID09IG5ld0ZpbGUubmFtZTtcclxuICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgIGlmICghYWxyZWFkeUluTGlzdCkge1xyXG4gICAgICAgICAgICAgICAgICAgIHNlbGYuZmlsZXMucHVzaCh7IG5hbWU6IG5ld0ZpbGUubmFtZSwgcGVyY2VudGFnZTogMCwgZXJyb3JNZXNzYWdlOiAnJyB9KTtcclxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcignQSBmaWxlIHdpdGggdGhlIHNhbWUgbmFtZSBpcyBhbHJlYWR5IG9uIHRoZSBxdWV1ZTonICsgbmV3RmlsZS5uYW1lKTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgfSk7XHJcblxyXG4gICAgICAgIGJ1cy4kb24oJ3JlbW92YWxSZXF1ZXN0JywgZnVuY3Rpb24gKGZpbGVVcGxvYWQpIHtcclxuICAgICAgICAgICAgc2VsZi5maWxlcy5mb3JFYWNoKGZ1bmN0aW9uIChpdGVtLCBpbmRleCwgYXJyYXkpIHtcclxuICAgICAgICAgICAgICAgIGlmIChpdGVtLm5hbWUgPT0gZmlsZVVwbG9hZC5uYW1lKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgYXJyYXkuc3BsaWNlKGluZGV4LCAxKTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgfSk7XHJcblxyXG4gICAgICAgIGJ1cy4kb24oJ0Vycm9yT25VcGxvYWQnLCBmdW5jdGlvbiAoZmlsZVVwbG9hZCkge1xyXG4gICAgICAgICAgICBzZWxmLnVwZGF0ZUNvdW50KCk7XHJcbiAgICAgICAgfSk7XHJcbiAgICB9LFxyXG4gICAgbWV0aG9kczoge1xyXG4gICAgICAgIHVwZGF0ZUNvdW50OiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgIHRoaXMuZXJyb3JDb3VudCA9IHRoaXMuZmlsZXMuZmlsdGVyKGZ1bmN0aW9uIChpdGVtKSB7XHJcbiAgICAgICAgICAgICAgICByZXR1cm4gaXRlbS5lcnJvck1lc3NhZ2UgIT0gJyc7XHJcbiAgICAgICAgICAgIH0pLmxlbmd0aDtcclxuICAgICAgICAgICAgdGhpcy5wZW5kaW5nQ291bnQgPSB0aGlzLmZpbGVzLmxlbmd0aCAtIHRoaXMuZXJyb3JDb3VudDtcclxuICAgICAgICAgICAgaWYgKHRoaXMuZmlsZXMubGVuZ3RoIDwgMSkge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5leHBhbmRlZCA9IGZhbHNlO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSxcclxuICAgICAgICBjbGVhckVycm9yczogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICB0aGlzLmZpbGVzID0gdGhpcy5maWxlcy5maWx0ZXIoZnVuY3Rpb24gKGl0ZW0pIHtcclxuICAgICAgICAgICAgICAgIHJldHVybiBpdGVtLmVycm9yTWVzc2FnZSA9PSAnJztcclxuICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgfVxyXG4gICAgfSxcclxuICAgIHdhdGNoOiB7XHJcbiAgICAgICAgZmlsZXM6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgdGhpcy51cGRhdGVDb3VudCgpO1xyXG4gICAgICAgIH1cclxuICAgIH1cclxufSk7XHJcbiJdfQ== +//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImpxdWVyeS5maWxldXBsb2FkLmpzIiwianF1ZXJ5LmlmcmFtZS10cmFuc3BvcnQuanMiLCJoZWxwZXJzLmpzIiwiTWVk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AgICBmb3IgKHByb3AgaW4gb2JqLl9yZXNwb25zZSkge1xuICAgICAgICAgIGlmIChPYmplY3QucHJvdG90eXBlLmhhc093blByb3BlcnR5LmNhbGwob2JqLl9yZXNwb25zZSwgcHJvcCkpIHtcbiAgICAgICAgICAgIGRlbGV0ZSBvYmouX3Jlc3BvbnNlW3Byb3BdO1xuICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgICAgfSBlbHNlIHtcbiAgICAgICAgb2JqLl9yZXNwb25zZSA9IHt9O1xuICAgICAgfVxuICAgIH0sXG5cbiAgICBfb25Qcm9ncmVzczogZnVuY3Rpb24gKGUsIGRhdGEpIHtcbiAgICAgIGlmIChlLmxlbmd0aENvbXB1dGFibGUpIHtcbiAgICAgICAgdmFyIG5vdyA9IERhdGUubm93ID8gRGF0ZS5ub3coKSA6IG5ldyBEYXRlKCkuZ2V0VGltZSgpLFxuICAgICAgICAgIGxvYWRlZDtcbiAgICAgICAgaWYgKFxuICAgICAgICAgIGRhdGEuX3RpbWUgJiZcbiAgICAgICAgICBkYXRhLnByb2dyZXNzSW50ZXJ2YWwgJiZcbiAgICAgICAgICBub3cgLSBkYXRhLl90aW1lIDwgZGF0YS5wcm9ncmVzc0ludGVydmFsICYmXG4gICAgICAgICAgZS5sb2FkZWQgIT09IGUudG90YWxcbiAgICAgICAgKSB7XG4gICAgICAgICAgcmV0dXJuO1xuICAgICAgICB9XG4gICAgICAgIGRhdGEuX3RpbWUgPSBub3c7XG4gICAgICAgIGxvYWRlZCA9XG4gICAgICAgICAgTWF0aC5mbG9vcihcbiAgICAgICAgICAgIChlLmxvYWRlZCAvIGUudG90YWwpICogKGRhdGEuY2h1bmtTaXplIHx8IGRhdGEuX3Byb2dyZXNzLnRvdGFsKVxuICAgICAgICAgICkgKyAoZGF0YS51cGxvYWRlZEJ5dGVzIHx8IDApO1xuICAgICAgICAvLyBBZGQgdGhlIGRpZmZlcmVuY2UgZnJvbSB0aGUgcHJldmlvdXNseSBsb2FkZWQgc3R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14uXSspPyQvLFxuICAgICAgICAgIGZ1bmN0aW9uIChfLCBwMSwgcDIpIHtcbiAgICAgICAgICAgIHZhciBpbmRleCA9IHAxID8gTnVtYmVyKHAxKSArIDEgOiAxO1xuICAgICAgICAgICAgdmFyIGV4dCA9IHAyIHx8ICcnO1xuICAgICAgICAgICAgcmV0dXJuICcgKCcgKyBpbmRleCArICcpJyArIGV4dDtcbiAgICAgICAgICB9XG4gICAgICAgICk7XG4gICAgICAgIHJldHVybiB0aGlzLl9nZXRVbmlxdWVGaWxlbmFtZShuYW1lLCBtYXApO1xuICAgICAgfVxuICAgICAgbWFwW25hbWVdID0gdHJ1ZTtcbiAgICAgIHJldHVybiBuYW1lO1xuICAgIH0sXG5cbiAgICBfaW5pdFhIUkRhdGE6IGZ1bmN0aW9uIChvcHRpb25zKSB7XG4gICAgICB2YXIgdGhhdCA9IHRoaXMsXG4gICAgICAgIGZvcm1EYXRhLFxuICAgICAgICBmaWxlID0gb3B0aW9ucy5maWxlc1swXSxcbiAgICAgICAgLy8gSWdub3JlIG5vbi1tdWx0aXBhcnQgc2V0dGluZyBpZiBub3Qgc3VwcG9ydGVkOlxuICAgICAgICBtdWx0aXBhcnQgPSBvcHRpb25zLm11bHRpcGFydCB8fCAhJC5zdXBwb3J0LnhockZpbGVVcGxvYWQsXG4gICAgICAgIHBhcmFtTmFtZSA9XG4gICAgICAgICAgJC50eXBlKG9wdGlvbnMucGFyYW1OYW1lKSA9PT0gJ2FycmF5J1xuICAgICAgICAgICAgPyBvcHRpb25zLnBhcmFtTmFtZVswXVxuICAgICAgICAgICAgOiBvcHRpb25zLnBhcmFtTmFtZTtcbiAgICAgIG9wdGlvbnMuaGVhZGVycyA9ICQuZXh0ZW5kKHt9LCBvcHRpb25zLmhlYWRlcnMpO1xuICAgICAgaWYgKG9wdGlvbnMuY29udGVudFJhbmdlKSB7XG4gICAgICAgIG9wdGlvbnMuaGVhZGVyc1snQ29udGVudC1SYW5nZSddID0gb3B0aW9ucy5jb250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AgICAgZm9ybURhdGEucHVzaCh7XG4gICAgICAgICAgICAgIG5hbWU6IHBhcmFtTmFtZSxcbiAgICAgICAgICAgICAgdmFsdWU6IG9wdGlvbnMuYmxvYlxuICAgICAgICAgICAgfSk7XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICQuZWFjaChvcHRpb25zLmZpbGVzLCBmdW5jdGlvbiAoaW5kZXgsIGZpbGUpIHtcbiAgICAgICAgICAgICAgZm9ybURhdGEucHVzaCh7XG4gICAgICAgICAgICAgICAgbmFtZTpcbiAgICAgICAgICAgICAgICAgICgkLnR5cGUob3B0aW9ucy5wYXJhbU5hbWUpID09PSAnYXJyYXknICYmXG4gICAgICAgICAgICAgICAgICAgIG9wdGlvbnMucGFyYW1OYW1lW2luZGV4XSkgfHxcbiAgICAgICAgICAgICAgICAgIHBhcmFtTmFtZSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogZmlsZVxuICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICBpZiAodGhhdC5faXNJbnN0YW5jZU9mKCdGb3JtRGF0YScsIG9wdGlvbnMuZm9ybURhdGEpKSB7XG4gICAgICAgICAgICBmb3JtRGF0YSA9IG9wdGlvbnMuZm9ybURhdGE7XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGZvcm1EYXRhID0gbmV3IEZvcm1EYXRhKCk7XG4gICAgICAgICAgICAkLmVhY2godGhpcy5fZ2V0Rm9ybURhdGEob3B0aW9ucyksIGZ1bmN0aW9uIChpbmRleCwgZmllbGQpIHtcbiAgICAgICAgICAgICAgZm9ybURhdGEuYXBwZW5kKGZpZWxkLm5hbWUsIGZpZWxkLnZhbHVlKTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgIH1cbiAgICAgICAgICBpZiAob3B0aW9ucy5ibG9iKSB7XG4gICAgICAgICAgICBmb3JtRGF0YS5hcHBlbmQoXG4gICAgICAgICAgICAgIHBhcmFtTmFtZSxcbiAgICAgICAgICAgICAgb3B0aW9ucy5ibG9iLFxuICAgICAgICAgICAgICBmaWxlLnVwbG9hZE5hbWUgfHwgZmlsZS5uYW1lXG4gICAgICAgICAgICApO1xuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAkLmVhY2gob3B0aW9ucy5maWxlcywgZnVuY3Rpb24gKGluZGV4LCBmaWxlKSB7XG4gICAgICAgICAgICAgIC8vIFRoaXMgY2hlY2sgYWxsb3dzIHRoZSB0ZXN0cyB0byBydW4gd2l0aFxuICAgICAgICAgICAgICAvLyBkdW1teSBvYmplY3RzOlxuICAgICAgICAgICAgICBpZiAoXG4gICAgICAgICAgICAgICAgdGhhdC5faXNJbnN0YW5jZU9mKCdGaWxlJywgZmlsZSkgfHxcbiAgICAgICAgICAgICAgICB0aGF0Ll9pc0luc3RhbmNlT2YoJ0Jsb2InLCBmaWxlKVxuICAgICAgICAgICAgICApIHtcbiAgICAgICAgICAgICAgICB2YXIgZmlsZU5hbWUgPSBmaWxlLnVwbG9hZE5hbWUgfHwgZmlsZS5uYW1lO1xuICAgICAgICAgICAgICAgIGlmIChvcHRpb25zLnVuaXF1ZUZpbGVuYW1lcykge1xuICAgICAgICAgICAgICAgICAgZmlsZU5hbWUgPSB0aGF0Ll9nZXRVbmlxdWVGaWxlbmFtZShcbiAgICAgICAgICAgICAgICAgICAgZmlsZU5hbWUsXG4gICAgICAgICAgICAgICAgICAgIG9wdGlvbnMudW5pcXVlRmlsZW5hbWVzXG4gICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBmb3JtRGF0YS5hcHBlbmQoXG4gICAgICAgICAgICAgICAgICAoJC50eXBlKG9wdGlvbnMucGFyYW1OYW1lKSA9PT0gJ2FycmF5JyAmJlxuICAgICAgICAgICAgICAgICAgICBvcHRpb25zLnBhcmFtTmFtZVtpbmRleF0pIHx8XG4gICAg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bWNzKSA8IGZzKVxuICAgICAgICApIHx8XG4gICAgICAgIG9wdGlvbnMuZGF0YVxuICAgICAgKSB7XG4gICAgICAgIHJldHVybiBmYWxzZTtcbiAgICAgIH1cbiAgICAgIGlmICh0ZXN0T25seSkge1xuICAgICAgICByZXR1cm4gdHJ1ZTtcbiAgICAgIH1cbiAgICAgIGlmICh1YiA+PSBmcykge1xuICAgICAgICBmaWxlLmVycm9yID0gb3B0aW9ucy5pMThuKCd1cGxvYWRlZEJ5dGVzJyk7XG4gICAgICAgIHJldHVybiB0aGlzLl9nZXRYSFJQcm9taXNlKGZhbHNlLCBvcHRpb25zLmNvbnRleHQsIFtcbiAgICAgICAgICBudWxsLFxuICAgICAgICAgICdlcnJvcicsXG4gICAgICAgICAgZmlsZS5lcnJvclxuICAgICAgICBdKTtcbiAgICAgIH1cbiAgICAgIC8vIFRoZSBjaHVuayB1cGxvYWQgbWV0aG9kOlxuICAgICAgdXBsb2FkID0gZnVuY3Rpb24gKCkge1xuICAgICAgICAvLyBDbG9uZSB0aGUgb3B0aW9ucyBvYmplY3QgZm9yIGVhY2ggY2h1bmsgdXBsb2FkOlxuICAgICAgICB2YXIgbyA9ICQuZXh0ZW5kKHt9LCBvcHRpb25zKSxcbiAgICAgICAgICBjdXJyZW50TG9hZGVkID0gby5fcHJvZ3Jlc3MubG9hZGVkO1xuICAgICAgICBvLmJsb2IgPSBzbGljZS5jYWxsKFxuICAgICAgICAgIGZpbGUsXG4gICAgICAgICAgdWIsXG4gICAgICAgICAgdWIgKyAoJC50eXBlKG1jcykgPT09ICdmdW5jdGlvbicgPyBtY3MobykgOiBtY3MpLFxuICAgICAgICAgIGZpbGUudHlwZVxuICAgICAgICApO1xuICAgICAgICAvLyBTdG9yZSB0aGUgY3VycmVudCBjaHVuayBzaXplLCBhcyB0aGUgYmxvYiBpdHNlbGZcbiAgICAgICAgLy8gd2lsbCBiZSBkZXJlZmVyZW5jZWQgYWZ0ZXIgZGF0YSBwcm9jZXNzaW5nO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zcyBldmVudCBpZiBubyBmaW5hbCBwcm9ncmVzcyBldmVudFxuICAgICAgICAgICAgLy8gd2l0aCBsb2FkZWQgZXF1YWxpbmcgdG90YWwgaGFzIGJlZW4gdHJpZ2dlcmVkXG4gICAgICAgICAgICAvLyBmb3IgdGhpcyBjaHVuazpcbiAgICAgICAgICAgIGlmIChjdXJyZW50TG9hZGVkICsgby5jaHVua1NpemUgLSBvLl9wcm9ncmVzcy5sb2FkZWQpIHtcbiAgICAgICAgICAgICAgdGhhdC5fb25Qcm9ncmVzcyhcbiAgICAgICAgICAgICAgICAkLkV2ZW50KCdwcm9ncmVzcycsIHtcbiAgICAgICAgICAgICAgICAgIGxlbmd0aENvbXB1dGFibGU6IHRydWUsXG4gICAgICAgICAgICAgICAgICBsb2FkZWQ6IHViIC0gby51cGxvYWRlZEJ5dGVzLFxuICAgICAgICAgICAgICAgICAgdG90YWw6IHViIC0gby51cGxvYWRlZEJ5dGVzXG4gICAgICAgICAgICAgICAgfSksXG4gICAgICAgICAgICAgICAgb1xuICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgb3B0aW9ucy51cGxvYWRlZEJ5dGVzID0gby51cGxvYWRlZEJ5dGVzID0gdWI7XG4gICAgICAgICAgICBvLnJlc3VsdCA9IHJlc3VsdDtcbiAgICAgICAgICAgIG8udGV4dFN0YXR1cyA9IHRleHRTdGF0dXM7XG4gICAgICAgICAgICBvLmpxWEhSID0ganFYSFI7XG4gICAgICAgICAgICB0aGF0Ll90cmlnZ2VyKCdjaHVua2RvbmUnLCBudWxsLCBvKTtcbiAgICAgICAgICAgIHRoYXQuX3RyaWdnZXIoJ2NodW5rYWx3YXlzJywgbnVsbCwgbyk7XG4gICAgICAgICAgICBpZiAodWIgPCBmcykge1xuICAgICAgICAgICAgICAvLyBGaWxlIHVwbG9hZCBub3QgeWV0IGNvbXBsZXRlLFxuICAgICAgICAgICAgICAvLyBjb250aW51ZSB3aXRoIHRoZSBuZXh0IGNodW5rOlxuICAgICAgICAgICAgICB1cGxvYWQoKTtcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgIGRmZC5yZXNvbHZlV2l0aChvLmNvbnRleHQsIFtyZXN1bHQsIHRleHRTdGF0dXMsIGpxWEhSXSk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSlcbiAgICAgICAgICAuZmFpbChmdW5jdGlvbiAoanFYSFIsIHRleHRTdGF0dXMsIGVycm9yVGhyb3duKSB7XG4gICAgICAgICAgICBvLmpxWEhSID0ganFYSFI7XG4gICAgICAgICAgICBvLnRleHRTdGF0dXMgPSB0ZXh0U3RhdHVzO1xuICAgICAgICAgICAgby5lcnJvclRocm93biA9IGVycm9yVGhyb3duO1xuICAgICAgICAgICAgdGhhdC5fdHJpZ2dlcignY2h1bmtmYWlsJywgbnVsbCwgbyk7XG4gICAgICAgICAgICB0aGF0Ll90cmlnZ2VyKCdjaHVua2Fsd2F5cycsIG51bGwsIG8pO1xuICAgICAgICAgICAgZGZkLnJlamVjdFdpdGgoby5jb250ZXh0LCBbanFYSFIsIHRleHRTdGF0dXMsIGVycm9yVGhyb3duXSk7XG4gICAgICAgICAgfSlcbiAgICAgICAgICAuYWx3YXlzKGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICAgIHRoYXQuX2RlaW5pdFByb2dyZXNzTGlzdGVuZXIobyk7XG4gICAgICAgICAgfSk7XG4gICAgICB9O1xuICAgICAgdGhpcy5fZW5oYW5jZVByb21pc2UocHJvbWlzZSk7XG4gICAgICBwcm9taXNlLmFib3J0ID0gZnVuY3Rpb24gKCkge1xuICAgICAgICByZXR1cm4ganFYSFIuYWJvcnQoKTtcbiAgICAgIH07XG4gICAgICB1cGxvYWQoKTtcbiAgICAgIHJldHVybiBwcm9taXNlO1xuICAgIH0sXG5cbiAgICBfYmVmb3JlU2VuZDogZnVuY3Rpb24gKGUsIGRhdGEpIHtcbiAgICAgIGlmICh0aGlzLl9hY3RpdmUgPT09IDApIHtc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4gICAgICAgICAgICAgICAgICAkLkV2ZW50KCdzZW5kJywgeyBkZWxlZ2F0ZWRFdmVudDogZSB9KSxcbiAgICAgICAgICAgICAgICAgIG9wdGlvbnNcbiAgICAgICAgICAgICAgICApID09PSBmYWxzZSkgJiZcbiAgICAgICAgICAgICAgICB0aGF0Ll9nZXRYSFJQcm9taXNlKGZhbHNlLCBvcHRpb25zLmNvbnRleHQsIGFib3J0ZWQpKSB8fFxuICAgICAgICAgICAgICB0aGF0Ll9jaHVua2VkVXBsb2FkKG9wdGlvbnMpIHx8XG4gICAgICAgICAgICAgICQuYWpheChvcHRpb25zKVxuICAgICAgICAgICAgKVxuICAgICAgICAgICAgICAuZG9uZShmdW5jdGlvbiAocmVzdWx0LCB0ZXh0U3RhdHVzLCBqcVhIUikge1xuICAgICAgICAgICAgICAgIHRoYXQuX29uRG9uZShyZXN1bHQsIHRleHRTdGF0dXMsIGpxWEhSLCBvcHRpb25zKTtcbiAgICAgICAgICAgICAgfSlcbiAgICAgICAgICAgICAgLmZhaWwoZnVuY3Rpb24gKGpxWEhSLCB0ZXh0U3RhdHVzLCBlcnJvclRocm93bikge1xuICAgICAgICAgICAgICAgIHRoYXQuX29uRmFpbChqcVhIUiwgdGV4dFN0YXR1cywgZXJyb3JUaHJvd24sIG9wdGlvbnMpO1xuICAgICAgICAgICAgICB9KVxuICAgICAgICAgICAgICAuYWx3YXlzKGZ1bmN0aW9uIChqcVhIUm9yUmVzdWx0LCB0ZXh0U3RhdHVzLCBqcVhIUm9yRXJyb3IpIHtcbiAgICAgICAgICAgICAgICB0aGF0Ll9kZWluaXRQcm9ncmVzc0xpc3RlbmVyKG9wdGlvbnMpO1xuICAgICAgICAgICAgICAgIHRoYXQuX29uQWx3YXlzKFxuICAgICAgICAgICAgICAgICAganFYSFJvclJlc3VsdCxcbiAgICAgICAgICAgICAgICAgIHRleHRTdGF0dXMsXG4gICAgICAgICAgICAgICAgICBqcVhIUm9yRXJyb3IsXG4gICAgICAgICAgICAgICAgICBvcHRpb25zXG4gICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgICAgICB0aGF0Ll9zZW5kaW5nIC09IDE7XG4gICAgICAgICAgICAgICAgdGhhdC5fYWN0aXZlIC09IDE7XG4gICAgICAgICAgICAgICAgaWYgKFxuICAgICAgICAgICAgICAgICAgb3B0aW9ucy5saW1pdENvbmN1cnJlbnRVcGxvYWRzICYmXG4gICAgICAgICAgICAgICAgICBvcHRpb25zLmxpbWl0Q29uY3VycmVudFVwbG9hZHMgPiB0aGF0Ll9zZW5kaW5nXG4gICAgICAgICAgICAgICAgKSB7XG4gICAgICAgICAgICAgICAgICAvLyBTdGFydCB0aGUgbmV4dCBxdWV1ZWQgdXBsb2FkLFxuICAgICAgICAgICAgICAgICAgLy8gdGhhdCBoYXMgbm90IGJlZW4gYWJvcnRlZDpcbiAgICAgICAgICAgICAgICAgIHZhciBuZXh0U2xvdCA9IHRoYXQuX3Nsb3RzLnNoaWZ0KCk7XG4gICAgICAgICAgICAgICAgICB3aGlsZSAobmV4dFNsb3QpIHtcbiAgICAgICAgICAgICAgICAgICAgaWYgKHRoYXQuX2dldERlZmVycmVkU3RhdGUobmV4dFNsb3QpID09PSAncGVuZGluZycpIHtcbiAgICAgICAgICAgICAgICAgICAgICBuZXh0U2xvdC5yZXNvbHZlKCk7XG4gICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgbmV4dFNsb3QgPSB0aGF0Ll9zbG90cy5zaGlmdCgpO1xuICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBpZiAodGhhdC5fYWN0aXZlID09PSAwKSB7XG4gICAgICAgICAgICAgICAgICAvLyBUaGUgc3RvcCBjYWxsYmFjayBpcyB0cmlnZ2VyZWQgd2hlbiBhbGwgdXBsb2FkcyBoYXZlXG4gICAgICAgICAgICAgICAgICAvLyBiZWVuIGNvbXB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ICAgICAgICAgICAgcGFyYW1OYW1lU2xpY2UgPSBwYXJhbU5hbWU7XG4gICAgICAgICAgfVxuICAgICAgICAgIHBhcmFtTmFtZVNldC5wdXNoKHBhcmFtTmFtZVNsaWNlKTtcbiAgICAgICAgfVxuICAgICAgfSBlbHNlIGlmICghb3B0aW9ucy5zaW5nbGVGaWxlVXBsb2FkcyAmJiBsaW1pdFNpemUpIHtcbiAgICAgICAgZmlsZVNldCA9IFtdO1xuICAgICAgICBwYXJhbU5hbWVTZXQgPSBbXTtcbiAgICAgICAgZm9yIChpID0gMDsgaSA8IGZpbGVzTGVuZ3RoOyBpID0gaSArIDEpIHtcbiAgICAgICAgICBiYXRjaFNpemUgKz0gZmlsZXNbaV0uc2l6ZSArIG92ZXJoZWFkO1xuICAgICAgICAgIGlmIChcbiAgICAgICAgICAgIGkgKyAxID09PSBmaWxlc0xlbmd0aCB8fFxuICAgICAgICAgICAgYmF0Y2hTaXplICsgZmlsZXNbaSArIDFdLnNpemUgKyBvdmVyaGVhZCA+IGxpbWl0U2l6ZSB8fFxuICAgICAgICAgICAgKGxpbWl0ICYmIGkgKyAxIC0gaiA+PSBsaW1pdClcbiAgICAgICAgICApIHtcbiAgICAgICAgICAgIGZpbGVTZXQucHVzaChmaWxlcy5zbGljZShqLCBpICsgMSkpO1xuICAgICAgICAgICAgcGFyYW1OYW1lU2xpY2UgPSBwYXJhbU5hbWUuc2xpY2UoaiwgaSArIDEpO1xuICAgICAgICAgICAgaWYgKCFwYXJhbU5hbWVTbGljZS5sZW5ndGgpIHtcbiAgICAgICAgICAgICAgcGFyYW1OYW1lU2xpY2UgPSBwYXJhbU5hbWU7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBwYXJhbU5hbWVTZXQucHVzaChwYXJhbU5hbWVTbGljZSk7XG4gICAgICAgICAgICBqID0gaSArIDE7XG4gICAgICAgICAgICBiYXRjaFNpemUgPSAwO1xuICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgICAgfSBlbHNl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b25lIHNldDpcbiAgICAgICAgICBkZmQucmVzb2x2ZShbZV0pO1xuICAgICAgICB9LFxuICAgICAgICBzdWNjZXNzSGFuZGxlciA9IGZ1bmN0aW9uIChlbnRyaWVzKSB7XG4gICAgICAgICAgdGhhdFxuICAgICAgICAgICAgLl9oYW5kbGVGaWxlVHJlZUVudHJpZXMoZW50cmllcywgcGF0aCArIGVudHJ5Lm5hbWUgKyAnLycpXG4gICAgICAgICAgICAuZG9uZShmdW5jdGlvbiAoZmlsZXMpIHtcbiAgICAgICAgICAgICAgZGZkLnJlc29sdmUoZmlsZXMpO1xuICAgICAgICAgICAgfSlcbiAgICAgICAgICAgIC5mYWlsKGVycm9ySGFuZGxlcik7XG4gICAgICAgIH0sXG4gICAgICAgIHJlYWRFbnRyaWVzID0gZnVuY3Rpb24gKCkge1xuICAgICAgICAgIGRpclJlYWRlci5yZWFkRW50cmllcyhmdW5jdGlvbiAocmVzdWx0cykge1xuICAgICAgICAgICAgaWYgKCFyZXN1bHRzLmxlbmd0aCkge1xuICAgICAgICAgICAgICBzdWNjZXNzSGFuZGxlcihlbnRyaWVzKTtcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgIGVudHJpZXMgPSBlbnRyaWVzLmNvbmNhdChyZXN1bHRzKTtcbiAgICAgICAgICAgICAgcmVhZEVudHJpZXMoKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9LCBlcnJvckhhbmRsZXIpO1xuICAgICAgICB9O1xuICAgICAgLy8gZXNsaW50LWRpc2FibGUtbmV4dC1saW5lIG5vLXBhcmFtLXJlYXNzaWduXG4gICAgICBwYXRoID0gcGF0aCB8fCAnJztcbiAgICAgIGlmIChlbnRyeS5pc0ZpbGUpIHtcbiAgICAgICAgaWYgKGVudHJ5Ll9maWxlKSB7XG4gICAgICAgICAgLy8gV29ya2Fyb3VuZCBmb3IgQ2hyb21lIGJ1ZyAjMTQ5NzM1XG4gICAgICAgICAgZW50cnkuX2ZpbGUucmVsYXRpdmVQYXRoID0gcGF0aDtcbiAgICAgICAgICBkZmQucmVzb2x2ZShlbnRyeS5fZmlsZSk7XG4gICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgZW50cnkuZmlsZShmdW5jdGlvbiAoZmlsZSkge1xuICAgICAgICAgICAgZmlsZS5yZWxhdGl2ZVBhdGggPSBwYXRoO1xuICAgICAgICAgICAgZGZkLnJlc29sdmUoZmlsZSk7XG4gICAgICAgICAgfSwgZXJyb3JIYW5kbGVyKTtcbiAgICAgICAgfVxuICAgICAgfSBlbHNlIGlmIChlbnRyeS5pc0RpcmVjdG9yeSkge1xuICAgICAgICBkaXJSZWFkZXIgPSBlbnRyeS5jcmVhdGVSZWFkZXIoKTtcbiAgICAgICAgcmVhZEVudHJpZXMoKTtcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIC8vIFJldHVybiBhbiBlbXB0eSBsaXN0IGZvciBmaWxlIHN5c3RlbSBpdGVtc1xuICAgICAgICAvLyBvdGhlciB0aGFuIGZpbGVzIG9yIGRpcmVjdG9yaWVzOlxuICAgICAgICBkZmQucmVzb2x2ZShbXSk7XG4gICAgICB9XG4gICAgICByZXR1cm4gZGZkLnByb21pc2UoKTtcbiAgICB9LFxuXG4gICAgX2hhbmRsZUZpbGVUcmVlRW50cmllczogZnVuY3Rpb24gKGVudHJpZXMsIHBhdGgpIHtcbiAgICAgIHZhciB0aGF0ID0gdGhpcztcbiAgICAgIHJldHVybiAkLndoZW5cbiAgICAgICAgLmFwcGx5KFxuICAgICAgICAgICQsXG4gICAgICAgICAgJC5tYXAoZW50cmllcywgZnVuY3Rpb24gKGVudHJ5KSB7XG4gICAgICAgICAgICByZXR1cm4gdGhhdC5faGFuZGxlRmlsZVRyZWVFbnRyeShlbnRyeSwgcGF0aCk7XG4gICAgICAgICAgfSlcbiAgICAgICAgKVxuICAgICAgICBbdGhpcy5fcHJvbWlzZVBpcGVdKGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICByZXR1cm4gQXJyYXkucHJvdG90eXBlLmNvbmNhdC5hcHBseShbXSwgYXJndW1lbnRzKTtcbiAgICAgICAgfSk7XG4gICAgfSxcblxuICAgIF9nZXREcm9wcGVkRmlsZXM6IGZ1bmN0aW9uIChkYXRhVHJhbnNmZXIpIHtcbiAgICAgIC8vIGVzbGludC1kaXNhYmxlLW5leHQtbGluZSBuby1wYXJhbS1yZWFzc2lnblxuICAgICAgZGF0YVRyYW5zZmVyID0gZGF0YVRyYW5zZmVyIHx8IHt9O1xuICAgICAgdmFyIGl0ZW1zID0gZGF0YVRyYW5zZmVyLml0ZW1zO1xuICAgICAgaWYgKFxuICAgICAgICBpdGVtcyAmJlxuICAgICAgICBpdGVtcy5sZW5ndGggJiZcbiAgICAgICAgKGl0ZW1zWzBdLndlYmtpdEdldEFzRW50cnkgfHwgaXRlbXNbMF0uZ2V0QXNFbnRyeSlcbiAgICAgICkge1xuICAgICAgICByZXR1cm4gdGhpcy5faGFuZGxlRmlsZVRyZWVFbnRyaWVzKFxuICAgICAgICAgICQubWFwKGl0ZW1zLCBmdW5jdGlvbiAoaXRlbSkge1xuICAgICAgICAgICAgdmFyIGVudHJ5O1xuICAgICAgICAgICAgaWYgKGl0ZW0ud2Via2l0R2V0QXNFbnRyeSkge1xuICAgICAgICAgICAgICBlbnRyeSA9IGl0ZW0ud2Via2l0R2V0QXNFbnRyeSgpO1xuICAgICAgICAgICAgICBpZiAoZW50cnkpIHtcbiAgICAgICAgICAgICAgICAvLyBXb3JrYXJvdW5kIGZvciBDaHJvbWUgYnVnICMxNDk3MzU6XG4gICAgICAgICAgICAgICAgZW50cnkuX2ZpbGUgPSBpdGVtLmdldEFzRmlsZSgpO1xuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIHJldHVybiBlbnRyeTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHJldHVybiBpdGVtLmdldEFzRW50cnkoKTtcbiAgICAgICAgICB9KVxuICAgICAgICApO1xuICAgICAgfVxuICAgICAgcmV0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KGZpbGVzKSB7XG4gICAgICAgICAgICBpZiAoYWJvcnRlZCkge1xuICAgICAgICAgICAgICByZXR1cm47XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBpZiAoIWZpbGVzLmxlbmd0aCkge1xuICAgICAgICAgICAgICBkZmQucmVqZWN0KCk7XG4gICAgICAgICAgICAgIHJldHVybjtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGRhdGEuZmlsZXMgPSBmaWxlcztcbiAgICAgICAgICAgIGpxWEhSID0gdGhhdC5fb25TZW5kKG51bGwsIGRhdGEpO1xuICAgICAgICAgICAganFYSFIudGhlbihcbiAgICAgICAgICAgICAgZnVuY3Rpb24gKHJlc3VsdCwgdGV4dFN0YXR1cywganFYSFIpIHtcbiAgICAgICAgICAgICAgICBkZmQucmVzb2x2ZShyZXN1bHQsIHRleHRTdGF0dXMsIGpxWEhSKTtcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgZnVuY3Rpb24gKGpxWEhSLCB0ZXh0U3RhdHVzLCBlcnJvclRocm93bikge1xuICAgICAgICAgICAgICAgIGRmZC5yZWplY3QoanFYSFIsIHRleHRTdGF0dXMsIGVycm9yVGhyb3duKTtcbiAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgKTtcbiAgICAgICAgICB9KTtcbiAgICAgICAgICByZXR1cm4gdGhpcy5fZW5oYW5jZVByb21pc2UocHJvbWlzZSk7XG4gICAgICAgIH1cbiAgICAgICAgZGF0YS5maWxlcyA9ICQubWFrZUFycmF5KGRhdGEuZmlsZXMpO1xuICAgICAgICBpZiAoZGF0YS5maWxlcy5sZW5ndGgpIHtcbiAgICAgICAgICByZXR1cm4gdGhpcy5fb25TZW5kKG51bGwsIGRhdGEpO1xuICAgICAgICB9XG4gICAgICB9XG4gICAgICByZXR1cm4gdGhpcy5fZ2V0WEhSUHJvbWlzZShmYWxzZSwgZGF0YSAmJiBkYXRhLmNvbnRleHQpO1xuICAgIH1cbiAgfSk7XG59KTtcbiIs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dfbWV0aG9kPVBVVCc7XG4gICAgICAgICAgICBvcHRpb25zLnR5cGUgPSAnUE9TVCc7XG4gICAgICAgICAgfSBlbHNlIGlmIChvcHRpb25zLnR5cGUgPT09ICdQQVRDSCcpIHtcbiAgICAgICAgICAgIG9wdGlvbnMudXJsID0gb3B0aW9ucy51cmwgKyBhZGRQYXJhbUNoYXIgKyAnX21ldGhvZD1QQVRDSCc7XG4gICAgICAgICAgICBvcHRpb25zLnR5cGUgPSAnUE9TVCc7XG4gICAgICAgICAgfVxuICAgICAgICAgIC8vIElFIHZlcnNpb25zIGJlbG93IElFOCBjYW5ub3Qgc2V0IHRoZSBuYW1lIHByb3BlcnR5IG9mXG4gICAgICAgICAgLy8gZWxlbWVudHMgdGhhdCBoYXZlIGFscmVhZHkgYmVlbiBhZGRlZCB0byB0aGUgRE9NLFxuICAgICAgICAgIC8vIHNvIHdlIHNldCB0aGUgbmFtZSBhbG9uZyB3aXRoIHRoZSBpZnJhbWUgSFRNTCBtYXJrdXA6XG4gICAgICAgICAgY291bnRlciArPSAxO1xuICAgICAgICAgIGlmcmFtZSA9ICQoXG4gICAgICAgICAgICAnPGlmcmFtZSBzcmM9XCInICtcbiAgICAgICAgICAgICAgaW5pdGlhbElmcmFtZVNyYyArXG4gICAgICAgICAgICAgICdcIiBuYW1lPVwiaWZyYW1lLXRyYW5zcG9ydC0nICtcbiAgICAgICAgICAgICAgY291bnRlciArXG4gICAgICAgICAgICAgICdcIj48L2lmcmFtZT4nXG4gICAgICAgICAgKS5vbignbG9hZCcsIGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICAgIHZhciBmaWxlSW5wdXRDbG9uZXMsXG4gICAgICAgICAgICAgIHBhcmFtTmFtZXMgPSAkLmlzQXJyYXkob3B0aW9ucy5wYXJhbU5hbWUpXG4gICAgICAgICAgICAgICAgPyBvcHRpb25zLnBhcmFtTmFtZVxuICAgICAgICAgICAgICAgIDogW29wdGlvbnMucGFyYW1OYW1lXTtcbiAgICAgICAgICAgIGlmcmFtZS5vZmYoJ2xvYWQnKS5vbignbG9hZCcsIGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICAgICAgdmFyIHJlc3BvbnNlO1xuICAgICAgICAgICAgICAvLyBXcmFwIGluIGEgdHJ5L2NhdGNoIGJsb2NrIHRvIGNhdGNoIGV4Y2VwdGlvbnMgdGhyb3duXG4gICAgICAgICAgICAgIC8vIHdoZW4gdHJ5aW5nIHRvIGFjY2VzcyBjcm9zcy1kb21haW4gaWZyYW1lIGNvbnRlbnRzOlxuICAgICAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgICAgIHJlc3BvbnNlID0gaWZyYW1lLmNvbnRlbnRzKCk7XG4gICAgICAgICAgICAgICAgLy8gR29vZ2xlIENocm9tZSBhbmQgRmlyZWZveCBkbyBub3QgdGhyb3cgYW5cbiAgICAgICAgICAgICAgICAvLyBleGNlcHRpb24gd2hlbiBjYWxsaW5nIGlmcmFtZS5jb250ZW50cygpIG9uXG4gICAgICAgICAgICAgICAgLy8gY3Jvc3MtZG9tYWluIHJlcXVlc3RzLCBzbyB3ZSB1bmlmeSB0aGUgcmVzcG9uc2U6XG4gICAgICAgICAgICAgICAgaWYgKCFyZXNwb25zZS5sZW5ndGggfHwgIXJlc3BvbnNlWzBdLmZpcnN0Q2hpbGQpIHtcbiAgICAgICAgICAgICAgICAgIHRocm93IG5ldyBFcnJvcigpO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgfSBjYXRjaCAoZSkge1xuICAgICAgICAgICAgICAgIHJlc3BvbnNlID0gdW5kZWZpbmVkO1xuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIC8vIFRoZSBjb21wbGV0ZSBjYWxsYmFjayByZXR1cm5zIHRoZVxuICAgICAgICAgICAgICAvLyBpZnJhbWUgY29udGVudCBkb2N1bWVudCBhcyByZXNwb25zZSBvYmplY3Q6XG4gICAgICAgICAgICAgIGNvbXBsZXRlQ2FsbGJhY2soMjAwLCAnc3VjY2VzcycsIHsgaWZyYW1lOiByZXNwb25zZSB9KTtcbiAgICAgICAgICAgICAgLy8gRml4IGZvciBJRSBlbmRsZXNzIHByb2dyZXNzIGJhciBhY3Rpdml0eSBidWdcbiAgICAgICAgICAgICAgLy8gKGhhcHBlbnMgb24gZm9ybSBzdWJtaXRzIHRvIGlmcmFtZSB0YXJnZXRzKTpcbiAgICAgICAgICAgICAgJCgnPGlmcmFtZSBzcmM9XCInICsgaW5pdGlhbElmcmFtZVNyYyArICdcIj48L2lmcmFtZT4nKS5hcHBlbmRUbyhcbiAgICAgICAgICAgICAgICBmb3JtXG4gICAgICAgICAgICAgICk7XG4gICAgICAgICAgICAgIHdpbmRvdy5zZXRUaW1lb3V0KGZ1bmN0aW9uICgpIHtcbiAgICAgICAgICAgICAgICAvLyBSZW1vdmluZyB0aGUgZm9ybSBpbiBhIHNldFRpbWVvdXQgY2FsbFxuICAgICAgICAgICAgICAgIC8vIGFsbG93cyBDaHJvbWUncyBkZXZlbG9wZXIgdG9vbHMgdG8gZGlzcGxheVxuICAgICAgICAgICAgICAgIC8vIHRoZSByZXNwb25zZSByZXN1bHRcbiAgICAgICAgICAgICAgICBmb3JtLnJlbW92ZSgpO1xuICAgICAgICAgICAgICB9LCAwKTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgZm9ybVxuICAgICAgICAgICAgICAucHJvcCgndGFyZ2V0JywgaWZyYW1lLnByb3AoJ25hbWUnKSlcbiAgICAgICAgICAgICAgLnByb3AoJ2FjdGlvbicsIG9wdGlvbnMudXJsKVxuICAgICAgICAgICAgICAucHJvcCgnbWV0aG9kJywgb3B0aW9ucy50eXBlKTtcbiAgICAgICAgICAgIGlmIChvcHRpb25zLmZvcm1EYXRhKSB7XG4gICAgICAgICAgICAgICQuZWFjaChvcHRpb25zLmZvcm1EYXRhLCBmdW5jdGlvbiAoaW5kZXgsIGZpZWxkKSB7XG4gICAgICAgICAgICAgICAgJCgnPGlucHV0IHR5cGU9XCJoaWRkZW5cIi8+JylcbiAgICAgICAgICAgICAgICAgIC5wcm9wKCduYW1lJywgZmllbGQubmFtZSlcbiAgICAgICAgICAgICAgICAgIC52YWwoZmllbGQudmFsdWUpXG4gICAgICAgICAgICAgICAgICAuYXBwZW5kVG8oZm9ybSk7XG4gICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgaWYgKFxuICAgICAgICAgICAgICBvcHRpb25zLmZpbGVJbnB1dCAmJlxuICAgICAgICAgICAgICBvcHRpb25zLmZpbGVJbnB1dC5sZW5ndGggJiZcbiAgICAgICAgICAgICAgb3B0aW9ucy50eXBlID09PSAnUE9TVCdcbiAgICAgICAgICAgICkge1xuICAgICAgICAgICAgICBmaWxlSW5wdXRDbG9uZXMgPSBvcHRpb25zLmZpbGVJbnB1dC5jbG9uZSgpO1xuICAgICAgICAgICAgICAvLyBJbnNlcnQgYSBjbG9uZSBmb3IgZWFjaCBmaWxlIGlucHV0IGZpZWxkOlxuICAgICAgICAgICAgICBvcHRpb25zLmZpbGVJbnB1dC5hZnRlcihmdW5jdGlvbiAoaW5kZXgpIHtcbiAgICAgICAgICAgICAgICByZXR1cm4gZmlsZUlucHV0Q2xvbmVzW2luZGV4XTtcbiAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgIGlmIChvcHRpb25zLnBhcmFtTmFtZSkge1xuICAgICAgICAgICAgICAgIG9wdGlvbnMuZmlsZUlucHV0LmVhY2goZnVuY3Rpb24gKGluZGV4KSB7XG4gICAgICAgICAgICAgICAgICAkKHRoaXMpLnByb3AoJ25hbWUnLCBwYXJhbU5hbWVzW2luZGV4XSB8fCBvcHRpb25zLnBhcmFtTmFtZSk7XG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgLy8gQXBwZW5kaW5nIHRoZSBmaWxlIGlucHV0IGZpZWxkcyB0byB0aGUgaGlkZGVuIGZvcm1cbiAgICAgICAgICAgICAgLy8gcmVtb3Zlcy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aGVpciBvcmlnaW5hbCBsb2NhdGlvblxuICAgICAgICAgICAgICAvLyBieSByZXBsYWNpbmcgdGhlIGNsb25lcyB3aXRoIHRoZSBvcmlnaW5hbHM6XG4gICAgICAgICAgICAgIGlmIChmaWxlSW5wdXRDbG9uZXMgJiYgZmlsZUlucHV0Q2xvbmVzLmxlbmd0aCkge1xuICAgICAgICAgICAgICAgIG9wdGlvbnMuZmlsZUlucHV0LmVhY2goZnVuY3Rpb24gKGluZGV4LCBpbnB1dCkge1xuICAgICAgICAgICAgICAgICAgdmFyIGNsb25lID0gJChmaWxlSW5wdXRDbG9uZXNbaW5kZXhdKTtcbiAgICAgICAgICAgICAgICAgIC8vIFJlc3RvcmUgdGhlIG9yaWdpbmFsIG5hbWUgYW5kIGZvcm0gcHJvcGVydGllczpcbiAgICAgICAgICAgICAgICAgICQoaW5wdXQpXG4gICAgICAgICAgICAgICAgICAgIC5wcm9wKCduYW1lJywgY2xvbmUucHJvcCgnbmFtZScpKVxuICAgICAgICAgICAgICAgICAgICAuYXR0cignZm9ybScsIGNsb25lLmF0dHIoJ2Zvcm0nKSk7XG4gICAgICAgICAgICAgICAgICBjbG9uZS5yZXBsYWNlV2l0aChpbnB1dCk7XG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH0sIDApO1xuICAgICAgICAgIH0pO1xuICAgICAgICAgIGZvcm0uYXBwZW5kKGlmcmFtZSkuYXBwZW5kVG8oZG9jdW1lbnQuYm9keSk7XG4gICAgICAgIH0sXG4gICAgICAgIGFib3J0OiBmdW5jdGlvbiAoKSB7XG4gICAgICAgICAgaWYgKGlmcmFtZSkge1xuICAgICAgICAgICAgLy8gamF2YXNjcmlwdDpmYWxzZSBhcyBpZnJhbWUgc3JjIGFib3J0cyB0aGUgcmVxdWVzdFxuICAgICAgICAgICAgLy8gYW5kIHByZXZlbnRzIHdhcm5pbmcgcG9wdXBzIG9uIEhUVFBTIGluIElFNi5cbiAgICAgIC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nRhLWNvbnRlbnQnKS5hcHBlbmQoY29udGVudCk7XHJcblxyXG4gICAgICAgICAgICAkKGRvY3VtZW50KS50cmlnZ2VyKCdtZWRpYWFwcGxpY2F0aW9uOnJlYWR5Jyk7XHJcblxyXG4gICAgICAgICAgICB2YXIgcm9vdCA9IHtcclxuICAgICAgICAgICAgICAgIG5hbWU6ICQoJyN0LW1lZGlhTGlicmFyeScpLnRleHQoKSxcclxuICAgICAgICAgICAgICAgIHBhdGg6ICcnLFxyXG4gICAgICAgICAgICAgICAgZm9sZGVyOiAnJyxcclxuICAgICAgICAgICAgICAgIGlzRGlyZWN0b3J5OiB0cnVlXHJcbiAgICAgICAgICAgIH07XHJcblxyXG4gICAgICAgICAgICBtZWRpYUFwcCA9IG5ldyBWdWUoe1xyXG4gICAgICAgICAgICAgICAgZWw6ICcjbWVkaWFBcHAnLFxyXG4gICAgICAgICAgICAgICAgZGF0YToge1xyXG4gICAgICAgICAgICAgICAgICAgIHNlbGVjdGVkRm9sZGVyOiB7fSxcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUl0ZW1zOiBbXSxcclxuICAgICAgICAgICAgICAgICAgICBzZWxlY3RlZE1lZGlhczogW10sXHJcbiAgICAgICAgICAgICAgICAgICAgZXJyb3JzOiBbXSxcclxuICAgICAgICAgICAgICAgICAgICBkcmFnRHJvcFRodW1ibmFpbDogbmV3IEltYWdlKCksXHJcbiAgICAgICAgICAgICAgICAgICAgc21hbGxUaHVtYnM6IGZhbHNlLFxyXG4gICAgICAgICAgICAgICAgICAgIGdyaWRWaWV3OiBmYWxzZSxcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUZpbHRlcjogJycsXHJcbiAgICAgICAgICAgICAgICAgICAgc29ydEJ5OiAnJyxcclxuICAgICAgICAgICAgICAgICAgICBzb3J0QXNjOiB0cnVlLFxyXG4gICAgICAgICAgICAgICAgICAgIGl0ZW1zSW5QYWdlOiBbXVxyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIGNyZWF0ZWQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIHNlbGYuZHJhZ0Ryb3BUaHVtYm5haWwuc3JjID0gKHBhdGhCYXNlIHx8ICcnKSArICcvT3JjaGFyZENvcmUuTWVkaWEvSW1hZ2VzL2RyYWctdGh1bWJuYWlsLnBuZyc7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIGJ1cy4kb24oJ2ZvbGRlclNlbGVjdGVkJywgZnVuY3Rpb24gKGZvbGRlcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdGVkRm9sZGVyID0gZm9sZGVyO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdmb2xkZXJEZWxldGVkJywgZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdFJvb3QoKTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRvbignZm9sZGVyQWRkZWQnLCBmdW5jdGlvbiAoZm9sZGVyKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0ZWRGb2xkZXIgPSBmb2xkZXI7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGZvbGRlci5zZWxlY3RlZCA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIGJ1cy4kb24oJ21lZGlhTGlzdE1vdmVkJywgZnVuY3Rpb24gKGVycm9ySW5mbykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLmxvYWRGb2xkZXIoc2VsZi5zZWxlY3RlZEZvbGRlcik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChlcnJvckluZm8pIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuZXJyb3JzLnB1c2goZXJyb3JJbmZvKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdtZWRpYVJlbmFtZWQnLCBmdW5jdGlvbiAobmV3TmFtZSwgbmV3UGF0aCwgb2xkUGF0aCwgbmV3VXJsKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBtZWRpYSA9IHNlbGYubWVkaWFJdGVtcy5maWx0ZXIoZnVuY3Rpb24gKGl0ZW0pIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBpdGVtLm1lZGlhUGF0aCA9PT0gb2xkUGF0aDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSlbMF07XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBtZWRpYS5tZWRpYVBhdGggPSBuZXdQYXRoO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBtZWRpYS5uYW1lID0gbmV3TmFtZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgbWVkaWEudXJsID0gbmV3VXJsO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBidXMuJG9uKCdjcmVhdGVGb2xkZXJSZXF1ZXN0ZWQnLCBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5jcmVhdGVGb2xkZXIoKTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRvbignZGVsZXRlRm9sZGVyUmVxdWVzdGVkJywgZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuZGVsZXRlRm9sZGVyKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIC8vIGNvbW1vbiBoYW5kbGVycyBmb3IgYWN0aW9ucyBpbiBib3RoIGdyaWQgYW5kIHRhYmxlIHZpZXcuXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRvbignc29ydENoYW5nZVJlcXVlc3RlZCcsIGZ1bmN0aW9uIChuZXdTb3J0KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuY2hhbmdlU29ydChuZXdTb3J0KTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRvbignbWVkaWFUb2dnbGVSZXF1ZXN0ZWQnLCBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi50b2dnbGVTZWxlY3Rpb25PZk1lZGlhKG1lZGlhKTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRvbigncmVuYW1lTWVkaWFSZXF1ZXN0ZWQnLCBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5yZW5hbWVNZWRpYShtZWRpYSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIGJ1cy4kb24oJ2RlbGV0ZU1lZGlhUmVxdWVzdGVkJywgZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuZGVsZXRlTWVkaWFJdGVtKG1lZGlhKTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRvbignbWVkaWFEcmFnU3RhcnRSZXF1ZXN0ZWQnLCBmdW5jdGlvbiAobWVkaWEsIGUpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5oYW5kbGVEcmFnU3RhcnQobWVkaWEsIGUpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuXHJcbiAgICAgICAgICAgICAgICAgICAgLy8gaGFuZGxlciBmb3IgcGFnZXIgZXZlbnRzXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRvbigncGFnZXJFdmVudCcsIGZ1bmN0aW9uIChpdGVtc0luUGFnZSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmLml0ZW1zSW5QYWdlID0gaXRlbXNJblBhZ2U7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0ZWRNZWRpYXMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKCFsb2NhbFN0b3JhZ2UuZ2V0SXRlbSgnbWVkaWFBcHBsaWNhdGlvblByZWZzJykpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RlZEZvbGRlciA9IHJvb3Q7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIHNlbGYuY3VycmVudFByZWZzID0gSlNPTi5wYXJzZShsb2NhbFN0b3JhZ2UuZ2V0SXRlbSgnbWVkaWFBcHBsaWNhdGlvblByZWZzJykpO1xyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIGNvbXB1dGVkOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgaXNIb21lOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLnNlbGVjdGVkRm9sZGVyID09IHJvb3Q7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBwYXJlbnRzOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHBhcmVudEZvbGRlciA9IHRoaXMuc2VsZWN0ZWRGb2xkZXI7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHdoaWxlIChwYXJlbnRGb2xkZXIgJiYgcGFyZW50Rm9sZGVyLnBhdGggIT0gJycpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHAudW5zaGlmdChwYXJlbnRGb2xkZXIpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcGFyZW50Rm9sZGVyID0gcGFyZW50Rm9sZGVyLnBhcmVudDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcDtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHJvb3Q6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJvb3Q7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBmaWx0ZXJlZE1lZGlhSXRlbXM6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RlZE1lZGlhcyA9IFtdO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGZpbHRlcmVkID0gc2VsZi5tZWRpYUl0ZW1zLmZpbHRlcihmdW5jdGlvbiAoaXRlbSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGl0ZW0ubmFtZS50b0xvd2VyQ2FzZSgpLmluZGV4T2Yoc2VsZi5tZWRpYUZpbHRlci50b0xvd2VyQ2FzZSgpKSA+IC0gMTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBzd2l0Y2ggKHNlbGYuc29ydEJ5KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBjYXNlICdzaXplJzpcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmaWx0ZXJlZC5zb3J0KGZ1bmN0aW9uIChhLCBiKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBzZWxmLnNvcnRBc2MgPyBhLnNpemUgLSBiLnNpemUgOiBiLnNpemUgLSBhLnNpemU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBjYXNlICdtaW1lJzpcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmaWx0ZXJlZC5zb3J0KGZ1bmN0aW9uIChhLCBiKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBzZWxmLnNvcnRBc2MgPyBhLm1pbWUudG9Mb3dlckNhc2UoKS5sb2NhbGVDb21wYXJlKGIubWltZS50b0xvd2VyQ2FzZSgpKSA6IGIubWltZS50b0xvd2VyQ2FzZSgpLmxvY2FsZUNvbXBhcmUoYS5taW1lLnRvTG93ZXJDYXNlKCkpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY2FzZSAnbGFzdE1vZGlmeSc6XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZmlsdGVyZWQuc29ydChmdW5jdGlvbiAoYSwgYikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gc2VsZi5zb3J0QXNjID8gYS5sYXN0TW9kaWZ5IC0gYi5sYXN0TW9kaWZ5IDogYi5sYXN0TW9kaWZ5IC0gYS5sYXN0TW9kaWZ5O1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZGVmYXVsdDpcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmaWx0ZXJlZC5zb3J0KGZ1bmN0aW9uIChhLCBiKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBzZWxmLnNvcnRBc2MgPyBhLm5hbWUudG9Mb3dlckNhc2UoKS5sb2NhbGVDb21wYXJlKGIubmFtZS50b0xvd2VyQ2FzZSgpKSA6IGIubmFtZS50b0xvd2VyQ2FzZSgpLmxvY2FsZUNvbXBhcmUoYS5uYW1lLnRvTG93ZXJDYXNlKCkpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gZmlsdGVyZWQ7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBoaWRkZW5Db3VudDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVzdWx0ID0gMDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0gdGhpcy5tZWRpYUl0ZW1zLmxlbmd0aCAtIHRoaXMuZmlsdGVyZWRNZWRpYUl0ZW1zLmxlbmd0aDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJlc3VsdDtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHRodW1iU2l6ZTogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gdGhpcy5zbWFsbFRodW1icyA/IDEwMCA6IDI0MDtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGN1cnJlbnRQcmVmczoge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBnZXQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc21hbGxUaHVtYnM6IHRoaXMuc21hbGxUaHVtYnMsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZWN0ZWRGb2xkZXI6IHRoaXMuc2VsZWN0ZWRGb2xkZXIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZ3JpZFZpZXc6IHRoaXMuZ3JpZFZpZXdcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH07XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNldDogZnVuY3Rpb24gKG5ld1ByZWZzKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoIW5ld1ByZWZzKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc21hbGxUaHVtYnMgPSBuZXdQcmVmcy5zbWFsbFRodW1icztcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRGb2xkZXIgPSBuZXdQcmVmcy5zZWxlY3RlZEZvbGRlcjtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuZ3JpZFZpZXcgPSBuZXdQcmVmcy5ncmlkVmlldztcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICB3YXRjaDoge1xyXG4gICAgICAgICAgICAgICAgICAgIGN1cnJlbnRQcmVmczogZnVuY3Rpb24gKG5ld1ByZWZzKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGxvY2FsU3RvcmFnZS5zZXRJdGVtKCdtZWRpYUFwcGxpY2F0aW9uUHJlZnMnLCBKU09OLnN0cmluZ2lmeShuZXdQcmVmcykpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZWN0ZWRGb2xkZXI6IGZ1bmN0aW9uIChuZXdGb2xkZXIpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5tZWRpYUZpbHRlciA9ICcnO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkRm9sZGVyID0gbmV3Rm9sZGVyO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLmxvYWRGb2xkZXIobmV3Rm9sZGVyKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIG1vdW50ZWQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICB0aGlzLiRyZWZzLnJvb3RGb2xkZXIudG9nZ2xlKCk7XHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgbWV0aG9kczoge1xyXG4gICAgICAgICAgICAgICAgICAgIHVwbG9hZFVybDogZnVuY3Rpb24gKCkge1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKCF0aGlzLnNlbGVjdGVkRm9sZGVyKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gbnVsbDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHVybFZhbHVlID0gJCgnI3VwbG9hZEZpbGVzJykudmFsKCk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gdXJsVmFsdWUgKyAodXJsVmFsdWUuaW5kZXhPZignPycpID09IC0xID8gJz8nIDogJyYnKSArIFwicGF0aD1cIiArIGVuY29kZVVSSUNvbXBvbmVudCh0aGlzLnNlbGVjdGVkRm9sZGVyLnBhdGgpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZWN0Um9vdDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkRm9sZGVyID0gdGhpcy5yb290O1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgbG9hZEZvbGRlcjogZnVuY3Rpb24gKGZvbGRlcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLmVycm9ycyA9IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWFzID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1lZGlhVXJsID0gJCgnI2dldE1lZGlhSXRlbXNVcmwnKS52YWwoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2coZm9sZGVyLnBhdGgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAkLmFqYXgoe1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiBtZWRpYVVybCArIChtZWRpYVVybC5pbmRleE9mKCc/JykgPT0gLTEgPyAnPycgOiAnJicpICsgXCJwYXRoPVwiICsgZW5jb2RlVVJJQ29tcG9uZW50KGZvbGRlci5wYXRoKSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJ0dFVCcsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBzdWNjZXNzOiBmdW5jdGlvbiAoZGF0YSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGEuZm9yRWFjaChmdW5jdGlvbiAoaXRlbSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtLm9wZW4gPSBmYWxzZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLm1lZGlhSXRlbXMgPSBkYXRhO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0ZWRNZWRpYXMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLnNvcnRCeSA9ICcnO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuc29ydEFzYyA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZXJyb3I6IGZ1bmN0aW9uIChlcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKCdlcnJvciBsb2FkaW5nIGZvbGRlcjonICsgZm9sZGVyLnBhdGgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0Um9vdCgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHNlbGVjdEFsbDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWFzID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGZvciAodmFyIGkgPSAwOyBpIDwgdGhpcy5maWx0ZXJlZE1lZGlhSXRlbXMubGVuZ3RoOyBpKyspIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYXMucHVzaCh0aGlzLmZpbHRlcmVkTWVkaWFJdGVtc1tpXSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHVuU2VsZWN0QWxsOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYXMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGludmVydFNlbGVjdGlvbjogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgdGVtcCA9IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBmb3IgKHZhciBpID0gMDsgaSA8IHRoaXMuZmlsdGVyZWRNZWRpYUl0ZW1zLmxlbmd0aDsgaSsrKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAodGhpcy5pc01lZGlhU2VsZWN0ZWQodGhpcy5maWx0ZXJlZE1lZGlhSXRlbXNbaV0pID09IGZhbHNlKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdGVtcC5wdXNoKHRoaXMuZmlsdGVyZWRNZWRpYUl0ZW1zW2ldKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWFzID0gdGVtcDtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHRvZ2dsZVNlbGVjdGlvbk9mTWVkaWE6IGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAodGhpcy5pc01lZGlhU2VsZWN0ZWQobWVkaWEpID09IHRydWUpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYXMuc3BsaWNlKHRoaXMuc2VsZWN0ZWRNZWRpYXMuaW5kZXhPZihtZWRpYSksIDEpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhcy5wdXNoKG1lZGlhKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgaXNNZWRpYVNlbGVjdGVkOiBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlc3VsdCA9IHRoaXMuc2VsZWN0ZWRNZWRpYXMuc29tZShmdW5jdGlvbiAoZWxlbWVudCwgaW5kZXgsIGFycmF5KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gZWxlbWVudC51cmwudG9Mb3dlckNhc2UoKSA9PT0gbWVkaWEudXJsLnRvTG93ZXJDYXNlKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVzdWx0O1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgZGVsZXRlRm9sZGVyOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBmb2xkZXIgPSB0aGlzLnNlbGVjdGVkRm9sZGVyO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vIFRoZSByb290IGZvbGRlciBjYW4ndCBiZSBkZWxldGVkXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChmb2xkZXIgPT0gdGhpcy5yb290Lm1vZGVsKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbmZpcm1EaWFsb2coe1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLi4uJChcIiNkZWxldGVGb2xkZXJcIikuZGF0YSgpLCBjYWxsYmFjazogZnVuY3Rpb24gKHJlc3ApIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzcCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAkLmFqYXgoe1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiAkKCcjZGVsZXRlRm9sZGVyVXJsJykudmFsKCkgKyBcIj9wYXRoPVwiICsgZW5jb2RlVVJJQ29tcG9uZW50KGZvbGRlci5wYXRoKSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJ1BPU1QnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIF9fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuOiAkKFwiaW5wdXRbbmFtZT0nX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW4nXVwiKS52YWwoKVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHN1Y2Nlc3M6IGZ1bmN0aW9uIChkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYnVzLiRlbWl0KCdkZWxldGVGb2xkZXInLCBmb2xkZXIpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGVycm9yOiBmdW5jdGlvbiAoZXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmVycm9yKGVycm9yLnJlc3BvbnNlVGV4dCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBjcmVhdGVGb2xkZXI6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgJCgnI2NyZWF0ZUZvbGRlck1vZGFsLWVycm9ycycpLmVtcHR5KCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBtb2RhbCA9IGJvb3RzdHJhcC5Nb2RhbC5nZXRPckNyZWF0ZUluc3RhbmNlKCQoJyNjcmVhdGVGb2xkZXJNb2RhbCcpKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgbW9kYWwuc2hvdygpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAkKCcjY3JlYXRlRm9sZGVyTW9kYWwgLm1vZGFsLWJvZHkgaW5wdXQnKS52YWwoJycpLmZvY3VzKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICByZW5hbWVNZWRpYTogZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICQoJyNyZW5hbWVNZWRpYU1vZGFsLWVycm9ycycpLmVtcHR5KCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBtb2RhbCA9IGJvb3RzdHJhcC5Nb2RhbC5nZXRPckNyZWF0ZUluc3RhbmNlKCQoJyNyZW5hbWVNZWRpYU1vZGFsJykpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBtb2RhbC5zaG93KCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICQoJyNvbGQtaXRlbS1uYW1lJykudmFsKG1lZGlhLm5hbWUpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAkKCcjcmVuYW1lTWVkaWFNb2RhbCAubW9kYWwtYm9keSBpbnB1dCcpLnZhbChtZWRpYS5uYW1lKS5mb2N1cygpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZWN0QW5kRGVsZXRlTWVkaWE6IGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLmRlbGV0ZU1lZGlhKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBkZWxldGVNZWRpYUxpc3Q6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1lZGlhTGlzdCA9IHRoaXMuc2VsZWN0ZWRNZWRpYXM7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChtZWRpYUxpc3QubGVuZ3RoIDwgMSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBjb25maXJtRGlhbG9nKHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC4uLiQoXCIjZGVsZXRlTWVkaWFcIikuZGF0YSgpLCBjYWxsYmFjazogZnVuY3Rpb24gKHJlc3ApIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzcCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcGF0aHMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBtZWRpYUxpc3QubGVuZ3RoOyBpKyspIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBhdGhzLnB1c2gobWVkaWFMaXN0W2ldLm1lZGlhUGF0aCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICQuYWpheCh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6ICQoJyNkZWxldGVNZWRpYUxpc3RVcmwnKS52YWwoKSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJ1BPU1QnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIF9fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuOiAkKFwiaW5wdXRbbmFtZT0nX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW4nXVwiKS52YWwoKSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYXRoczogcGF0aHNcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzdWNjZXNzOiBmdW5jdGlvbiAoZGF0YSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGZvciAodmFyIGkgPSAwOyBpIDwgc2VsZi5zZWxlY3RlZE1lZGlhcy5sZW5ndGg7IGkrKykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgaW5kZXggPSBzZWxmLm1lZGlhSXRlbXMgJiYgc2VsZi5tZWRpYUl0ZW1zLmluZGV4T2Yoc2VsZi5zZWxlY3RlZE1lZGlhc1tpXSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpbmRleCA+IC0xKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLm1lZGlhSXRlbXMuc3BsaWNlKGluZGV4LCAxKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJ1cy4kZW1pdCgnbWVkaWFEZWxldGVkJywgc2VsZi5zZWxlY3RlZE1lZGlhc1tpXSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RlZE1lZGlhcyA9IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGVycm9yOiBmdW5jdGlvbiAoZXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmVycm9yKGVycm9yLnJlc3BvbnNlVGV4dCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICBkZWxldGVNZWRpYUl0ZW06IGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICghbWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgY29uZmlybURpYWxvZyh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAuLi4kKFwiI2RlbGV0ZU1lZGlhXCIpLmRhdGEoKSwgY2FsbGJhY2s6IGZ1bmN0aW9uIChyZXNwKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHJlc3ApIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgJC5hamF4KHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJCgnI2RlbGV0ZU1lZGlhVXJsJykudmFsKCkgKyBcIj9wYXRoPVwiICsgZW5jb2RlVVJJQ29tcG9uZW50KG1lZGlhLm1lZGlhUGF0aCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICdQT1NUJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGE6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBfX1JlcXVlc3RWZXJpZmljYXRpb25Ub2tlbjogJChcImlucHV0W25hbWU9J19fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuJ11cIikudmFsKClcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzdWNjZXNzOiBmdW5jdGlvbiAoZGF0YSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBpbmRleCA9IHNlbGYubWVkaWFJdGVtcyAmJiBzZWxmLm1lZGlhSXRlbXMuaW5kZXhPZihtZWRpYSlcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoaW5kZXggPiAtMSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLm1lZGlhSXRlbXMuc3BsaWNlKGluZGV4LCAxKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYnVzLiRlbWl0KCdtZWRpYURlbGV0ZWQnLCBtZWRpYSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vc2VsZi5zZWxlY3RlZE1lZGlhID0gbnVsbDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlcnJvcjogZnVuY3Rpb24gKGVycm9yKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcihlcnJvci5yZXNwb25zZVRleHQpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgaGFuZGxlRHJhZ1N0YXJ0OiBmdW5jdGlvbiAobWVkaWEsIGUpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgLy8gZmlyc3QgcGFydCBvZiBtb3ZlIG1lZGlhIHRvIGZvbGRlcjpcclxuICAgICAgICAgICAgICAgICAgICAgICAgLy8gcHJlcGFyZSB0aGUgZGF0YSB0aGF0IHdpbGwgYmUgaGFuZGxlZCBieSB0aGUgZm9sZGVyIGNvbXBvbmVudCBvbiBkcm9wIGV2ZW50XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBtZWRpYU5hbWVzID0gW107XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYXMuZm9yRWFjaChmdW5jdGlvbiAoaXRlbSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbWVkaWFOYW1lcy5wdXNoKGl0ZW0ubmFtZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgLy8gaW4gY2FzZSB0aGUgdXNlciBkcmFncyBhbiB1bnNlbGVjdGVkIGl0ZW0sIHdlIHNlbGVjdCBpdCBmaXJzdFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAodGhpcy5pc01lZGlhU2VsZWN0ZWQobWVkaWEpID09IGZhbHNlKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZWRpYU5hbWVzLnB1c2gobWVkaWEubmFtZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWFzLnB1c2gobWVkaWEpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICBlLmRhdGFUcmFuc2Zlci5zZXREYXRhKCdtZWRpYU5hbWVzJywgSlNPTi5zdHJpbmdpZnkobWVkaWFOYW1lcykpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBlLmRhdGFUcmFuc2Zlci5zZXREYXRhKCdzb3VyY2VGb2xkZXInLCB0aGlzLnNlbGVjdGVkRm9sZGVyLnBhdGgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBlLmRhdGFUcmFuc2Zlci5zZXREcmFnSW1hZ2UodGhpcy5kcmFnRHJvcFRodW1ibmFpbCwgMTAsIDEwKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgZS5kYXRhVHJhbnNmZXIuZWZmZWN0QWxsb3dlZCA9ICdtb3ZlJztcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGhhbmRsZVNjcm9sbFdoaWxlRHJhZzogZnVuY3Rpb24gKGUpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGUuY2xpZW50WSA8IDE1MCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgd2luZG93LnNjcm9sbEJ5KDAsIC0xMCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChlLmNsaWVudFkgPiB3aW5kb3cuaW5uZXJIZWlnaHQgLSAxMDApIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHdpbmRvdy5zY3JvbGxCeSgwLCAxMCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGNoYW5nZVNvcnQ6IGZ1bmN0aW9uIChuZXdTb3J0KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICh0aGlzLnNvcnRCeSA9PSBuZXdTb3J0KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnNvcnRBc2MgPSAhdGhpcy5zb3J0QXNjO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zb3J0QXNjID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc29ydEJ5ID0gbmV3U29ydDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAkKCcjY3JlYXRlLWZvbGRlci1uYW1lJykua2V5cHJlc3MoZnVuY3Rpb24gKGUpIHtcclxuICAgICAgICAgICAgICAgIHZhciBrZXkgPSBlLndoaWNoO1xyXG4gICAgICAgICAgICAgICAgaWYgKGtleSA9PSAxMykgeyAgLy8gdGhlIGVudGVyIGtleSBjb2RlXHJcbiAgICAgICAgICAgICAgICAgICAgJCgnI21vZGFsRm9vdGVyT2snKS5jbGljaygpO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBmYWxzZTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAkKCcjbW9kYWxGb290ZXJPaycpLm9uKCdjbGljaycsIGZ1bmN0aW9uIChlKSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgbmFtZSA9ICQoJyNjcmVhdGUtZm9sZGVyLW5hbWUnKS52YWwoKTtcclxuXHJcbiAgICAgICAgICAgICAgICBpZiAobmFtZSA9PT0gXCJcIikge1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAkLmFqYXgoe1xyXG4gICAgICAgICAgICAgICAgICAgIHVybDogJCgnI2NyZWF0ZUZvbGRlclVybCcpLnZhbCgpICsgXCI/cGF0aD1cIiArIGVuY29kZVVSSUNvbXBvbmVudChtZWRpYUFwcC5zZWxlY3RlZEZvbGRlci5wYXRoKSArIFwiJm5hbWU9XCIgKyBlbmNvZGVVUklDb21wb25lbnQobmFtZSksXHJcbiAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnUE9TVCcsXHJcbiAgICAgICAgICAgICAgICAgICAgZGF0YToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBfX1JlcXVlc3RWZXJpZmljYXRpb25Ub2tlbjogJChcImlucHV0W25hbWU9J19fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuJ11cIikudmFsKClcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHN1Y2Nlc3M6IGZ1bmN0aW9uIChkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJ1cy4kZW1pdCgnYWRkRm9sZGVyJywgbWVkaWFBcHAuc2VsZWN0ZWRGb2xkZXIsIGRhdGEpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgbW9kYWwgPSBib290c3RyYXAuTW9kYWwuZ2V0T3JDcmVhdGVJbnN0YW5jZSgkKCcjY3JlYXRlRm9sZGVyTW9kYWwnKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG1vZGFsLmhpZGUoKTtcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIGVycm9yOiBmdW5jdGlvbiAoZXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgJCgnI2NyZWF0ZUZvbGRlck1vZGFsLWVycm9ycycpLmVtcHR5KCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBlcnJvck1lc3NhZ2UgPSBKU09OLnBhcnNlKGVycm9yLnJlc3BvbnNlVGV4dCkudmFsdWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICQoJzxkaXYgY2xhc3M9XCJhbGVydCBhbGVydC1kYW5nZXJcIiByb2xlPVwiYWxlcnRcIj48L2Rpdj4nKS50ZXh0KGVycm9yTWVzc2FnZSkuYXBwZW5kVG8oJCgnI2NyZWF0ZUZvbGRlck1vZGFsLWVycm9ycycpKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAkKCcjcmVuYW1lTWVkaWFNb2RhbEZvb3Rlck9rJykub24oJ2NsaWNrJywgZnVuY3Rpb24gKGUpIHtcclxuICAgICAgICAgICAgICAgIHZhciBuZXdOYW1lID0gJCgnI25ldy1pdGVtLW5hbWUnKS52YWwoKTtcclxuICAgICAgICAgICAgICAgIHZhciBvbGROYW1lID0gJCgnI29sZC1pdGVtLW5hbWUnKS52YWwoKTtcclxuXHJcbiAgICAgICAgICAgICAgICBpZiAobmV3TmFtZSA9PT0gXCJcIikge1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICB2YXIgY3VycmVudEZvbGRlciA9IG1lZGlhQXBwLnNlbGVjdGVkRm9sZGVyLnBhdGggKyBcIi9cIjtcclxuICAgICAgICAgICAgICAgIGlmIChjdXJyZW50Rm9sZGVyID09PSBcIi9cIikge1xyXG4gICAgICAgICAgICAgICAgICAgIGN1cnJlbnRGb2xkZXIgPSBcIlwiO1xyXG4gICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgIHZhciBuZXdQYXRoID0gY3VycmVudEZvbGRlciArIG5ld05hbWU7XHJcbiAgICAgICAgICAgICAgICB2YXIgb2xkUGF0aCA9IGN1cnJlbnRGb2xkZXIgKyBvbGROYW1lO1xyXG5cclxuICAgICAgICAgICAgICAgIGlmIChuZXdQYXRoLnRvTG93ZXJDYXNlKCkgPT09IG9sZFBhdGgudG9Mb3dlckNhc2UoKSkge1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBtb2RhbCA9IGJvb3RzdHJhcC5Nb2RhbC5nZXRPckNyZWF0ZUluc3RhbmNlKCQoJyNyZW5hbWVNZWRpYU1vZGFsJykpO1xyXG4gICAgICAgICAgICAgICAgICAgIG1vZGFsLmhpZGUoKTtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgJC5hamF4KHtcclxuICAgICAgICAgICAgICAgICAgICB1cmw6ICQoJyNyZW5hbWVNZWRpYVVybCcpLnZhbCgpICsgXCI/b2xkUGF0aD1cIiArIGVuY29kZVVSSUNvbXBvbmVudChvbGRQYXRoKSArIFwiJm5ld1BhdGg9XCIgKyBlbmNvZGVVUklDb21wb25lbnQobmV3UGF0aCksXHJcbiAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnUE9TVCcsXHJcbiAgICAgICAgICAgICAgICAgICAgZGF0YToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBfX1JlcXVlc3RWZXJpZmljYXRpb25Ub2tlbjogJChcImlucHV0W25hbWU9J19fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuJ11cIikudmFsKClcclxuICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHN1Y2Nlc3M6IGZ1bmN0aW9uIChkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBtb2RhbCA9IGJvb3RzdHJhcC5Nb2RhbC5nZXRPckNyZWF0ZUluc3RhbmNlKCQoJyNyZW5hbWVNZWRpYU1vZGFsJykpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBtb2RhbC5oaWRlKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJ1cy4kZW1pdCgnbWVkaWFSZW5hbWVkJywgbmV3TmFtZSwgbmV3UGF0aCwgb2xkUGF0aCwgZGF0YS5uZXdVcmwpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgZXJyb3I6IGZ1bmN0aW9uIChlcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAkKCcjcmVuYW1lTWVkaWFNb2RhbC1lcnJvcnMnKS5lbXB0eSgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgZXJyb3JNZXNzYWdlID0gSlNPTi5wYXJzZShlcnJvci5yZXNwb25zZVRleHQpLnZhbHVlO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAkKCc8ZGl2IGNsYXNzPVwiYWxlcnQgYWxlcnQtZGFuZ2VyXCIgcm9sZT1cImFsZXJ0XCI+PC9kaXY+JykudGV4dChlcnJvck1lc3NhZ2UpLmFwcGVuZFRvKCQoJyNyZW5hbWVNZWRpYU1vZGFsLWVycm9ycycpKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICBpZiAoZGlzcGxheU1lZGlhQXBwbGljYXRpb24pIHtcclxuICAgICAgICAgICAgICAgIGRvY3VtZW50LmdldEVsZW1lbnRCeUlkKCdtZWRpYUFwcCcpLnN0eWxlLmRpc3BsYXkgPSBcIlwiO1xyXG4gICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAkKGRvY3VtZW50KS50cmlnZ2VyKCdtZWRpYUFwcDpyZWFkeScpO1xyXG5cclxuICAgICAgICB9LFxyXG4gICAgICAgIGVycm9yOiBmdW5jdGlvbiAoZXJyb3IpIHtcclxuICAgICAgICAgICAgY29uc29sZS5lcnJvcihlcnJvci5yZXNwb25zZVRleHQpO1xyXG4gICAgICAgIH1cclxuICAgIH0pO1xyXG59XHJcbiIsIiQoZG9jdW1lbnQpLm9uKCdtZWRpYUFwcDpyZWFkeScsIGZ1bmN0aW9uICgpIHtcclxuICAgIHZhciBjaHVua2VkRmlsZVVwbG9hZElkID0gcmFuZG9tVVVJRCgpO1xyXG5cclxuICAgICQoJyNmaWxldXBsb2FkJylcclxuICAgICAgICAuZmlsZXVwbG9hZCh7XHJcbiAgICAgICAgICAgIGRyb3Bab25lOiAkKCcjbWVkaWFBcHAnKSxcclxuICAgICAgICAgICAgbGltaXRDb25jdXJyZW50VXBsb2FkczogMjAsXHJcbiAgICAgICAgICAgIGRhdGFUeXBlOiAnanNvbicsXHJcbiAgICAgICAgICAgIHVybDogJCgnI3VwbG9hZEZpbGVzJykudmFsKCksXHJcbiAgICAgICAgICAgIG1heENodW5rU2l6ZTogTnVtYmVyKCQoJyNtYXhVcGxvYWRDaHVua1NpemUnKS52YWwoKSB8fCAwKSxcclxuICAgICAgICAgICAgZm9ybURhdGE6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgIHZhciBhbnRpRm9yZ2VyeVRva2VuID0gJChcImlucHV0W25hbWU9X19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW5dXCIpLnZhbCgpO1xyXG5cclxuICAgICAgICAgICAgICAgIHJldHVybiBbXHJcbiAgICAgICAgICAgICAgICAgICAgeyBuYW1lOiAncGF0aCcsIHZhbHVlOiBtZWRpYUFwcC5zZWxlY3RlZEZvbGRlci5wYXRoIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgeyBuYW1lOiAnX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW4nLCB2YWx1ZTogYW50aUZvcmdlcnlUb2tlbiB9LFxyXG4gICAgICAgICAgICAgICAgICAgIHsgbmFtZTogJ19fY2h1bmtlZEZpbGVVcGxvYWRJZCcsIHZhbHVlOiBjaHVua2VkRmlsZVVwbG9hZElkIH0sXHJcbiAgICAgICAgICAgICAgICBdXHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGRvbmU6IGZ1bmN0aW9uIChlLCBkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAkLmVhY2goZGF0YS5yZXN1bHQuZmlsZXMsIGZ1bmN0aW9uIChpbmRleCwgZmlsZSkge1xyXG4gICAgICAgICAgICAgICAgICAgIGlmICghZmlsZS5lcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBtZWRpYUFwcC5tZWRpYUl0ZW1zLnB1c2goZmlsZSlcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH0pXHJcbiAgICAgICAgLm9uKCdmaWxldXBsb2FkY2h1bmtiZWZvcmVzZW5kJywgKGUsIG9wdGlvbnMpID0+IHtcclxuICAgICAgICAgICAgbGV0IGZpbGUgPSBvcHRpb25zLmZpbGVzWzBdO1xyXG4gICAgICAgICAgICAvLyBIZXJlIHdlIHJlcGxhY2UgdGhlIGJsb2Igd2l0aCBhIEZpbGUgb2JqZWN0IHRvIGVuc3VyZSB0aGUgZmlsZSBuYW1lIGFuZCBvdGhlcnMgYXJlIHByZXNlcnZlZCBmb3IgdGhlIGJhY2tlbmQuXHJcbiAgICAgICAgICAgIG9wdGlvbnMuYmxvYiA9IG5ldyBGaWxlKFxyXG4gICAgICAgICAgICAgICAgW29wdGlvbnMuYmxvYl0sXHJcbiAgICAgICAgICAgICAgICBmaWxlLm5hbWUsXHJcbiAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgdHlwZTogZmlsZS50eXBlLFxyXG4gICAgICAgICAgICAgICAgICAgIGxhc3RNb2RpZmllZDogZmlsZS5sYXN0TW9kaWZpZWQsXHJcbiAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICB9KTtcclxufSk7XHJcblxyXG5cclxuJChkb2N1bWVudCkuYmluZCgnZHJhZ292ZXInLCBmdW5jdGlvbiAoZSkge1xyXG4gICAgdmFyIGR0ID0gZS5vcmlnaW5hbEV2ZW50LmRhdGFUcmFuc2ZlcjtcclxuICAgIGlmIChkdC50eXBlcyAmJiAoZHQudHlwZXMuaW5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bGRlcigpKSl7XHJcbiAgICAgICAgICAgIHRoaXMudG9nZ2xlKCk7XHJcbiAgICAgICAgfVxyXG5cclxuICAgICAgICB0aGlzLnBhZGRpbmcgPSB0aGlzLmxldmVsIDwgMyA/ICAxNiA6IDE2ICsgKHRoaXMubGV2ZWwgKiA4KTtcclxuICAgIH0sXHJcbiAgICBjcmVhdGVkOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG4gICAgICAgIGJ1cy4kb24oJ2RlbGV0ZUZvbGRlcicsIGZ1bmN0aW9uIChmb2xkZXIpIHtcclxuICAgICAgICAgICAgaWYgKHNlbGYuY2hpbGRyZW4pIHtcclxuICAgICAgICAgICAgICAgIHZhciBpbmRleCA9IHNlbGYuY2hpbGRyZW4gJiYgc2VsZi5jaGlsZHJlbi5pbmRleE9mKGZvbGRlcilcclxuICAgICAgICAgICAgICAgIGlmIChpbmRleCA+IC0xKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZi5jaGlsZHJlbi5zcGxpY2UoaW5kZXgsIDEpXHJcbiAgICAgICAgICAgICAgICAgICAgYnVzLiRlbWl0KCdmb2xkZXJEZWxldGVkJyk7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgYnVzLiRvbignYWRkRm9sZGVyJywgZnVuY3Rpb24gKHRhcmdldCwgZm9sZGVyKSB7XHJcbiAgICAgICAgICAgIGlmIChzZWxmLm1vZGVsID09IHRhcmdldCkge1xyXG4gICAgICAgICAgICAgICAgaWYgKHNlbGYuY2hpbGRyZW4gIT09IG51bGwpIHtcclxuICAgICAgICAgICAgICAgICAgICBzZWxmLmNoaWxkcmVuLnB1c2goZm9sZGVyKTtcclxuICAgICAgICAgICAgICAgIH0gICAgICAgICAgICAgICAgXHJcbiAgICAgICAgICAgICAgICBmb2xkZXIucGFyZW50ID0gc2VsZi5tb2RlbDtcclxuICAgICAgICAgICAgICAgIGJ1cy4kZW1pdCgnZm9sZGVyQWRkZWQnLCBmb2xkZXIpO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSk7XHJcbiAgICB9LFxyXG4gICAgbWV0aG9kczoge1xyXG4gICAgICAgIGlzQW5jZXN0b3JPZlNlbGVjdGVkRm9sZGVyOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgIHBhcmVudEZvbGRlciA9IG1lZGlhQXBwLnNlbGVjdGVkRm9sZGVyO1xyXG4gICAgICAgICAgICB3aGlsZSAocGFyZW50Rm9sZGVyKSB7XHJcbiAgICAgICAgICAgICAgICBpZiAocGFyZW50Rm9sZGVyLnBhdGggPT0gdGhpcy5tb2RlbC5wYXRoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHRydWU7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIHBhcmVudEZvbGRlciA9IHBhcmVudEZvbGRlci5wYXJlbnQ7XHJcbiAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgIHJldHVybiBmYWxzZTtcclxuICAgICAgICB9LFxyXG4gICAgICAgIHRvZ2dsZTogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICB0aGlzLm9wZW4gPSAhdGhpcy5vcGVuO1xyXG4gICAgICAgICAgICBpZiAodGhpcy5vcGVuICYmICF0aGlzLmNoaWxkcmVuKSB7XHJcbiAgICAgICAgICAgICAgICB0aGlzLmxvYWRDaGlsZHJlbigpO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSxcclxuICAgICAgICBzZWxlY3Q6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgYnVzLiRlbWl0KCdmb2xkZXJTZWxlY3RlZCcsIHRoaXMubW9kZWwpO1xyXG4gICAgICAgICAgICB0aGlzLmxvYWRDaGlsZHJlbigpO1xyXG4gICAgICAgIH0sXHJcbiAgICAgICAgY3JlYXRlRm9sZGVyOiBmdW5jdGlvbiAoKSB7ICAgICAgICAgICBcclxuICAgICAgICAgICAgYnVzLiRlbWl0KCdjcmVhdGVGb2xkZXJSZXF1ZXN0ZWQnKTtcclxuICAgICAgICB9LFxyXG4gICAgICAgIGRlbGV0ZUZvbGRlcjogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICBidXMuJGVtaXQoJ2RlbGV0ZUZvbGRlclJlcXVlc3RlZCcpO1xyXG4gICAgICAgIH0sXHJcbiAgICAgICAgbG9hZENoaWxkcmVuOiBmdW5jdGlvbiAoKSB7ICAgICAgICAgICAgXHJcbiAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuICAgICAgICAgICAgaWYgKHRoaXMub3BlbiA9PSBmYWxzZSkge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5vcGVuID0gdHJ1ZTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAkLmFqYXgoe1xyXG4gICAgICAgICAgICAgICAgdXJsOiAkKCcjZ2V0Rm9sZGVyc1VybCcpLnZhbCgpICsgXCI/cGF0aD1cIiArIGVuY29kZVVSSUNvbXBvbmVudChzZWxmLm1vZGVsLnBhdGgpLFxyXG4gICAgICAgICAgICAgICAgbWV0aG9kOiAnR0VUJyxcclxuICAgICAgICAgICAgICAgIHN1Y2Nlc3M6IGZ1bmN0aW9uIChkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZi5jaGlsZHJlbiA9IGRhdGE7XHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZi5jaGlsZHJlbi5mb3JFYWNoKGZ1bmN0aW9uIChjKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGMucGFyZW50ID0gc2VsZi5tb2RlbDtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBlcnJvcjogZnVuY3Rpb24gKGVycm9yKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgZW10cHkgPSBmYWxzZTtcclxuICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmVycm9yKGVycm9yLnJlc3BvbnNlVGV4dCk7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0pO1xyXG4gICAgICAgIH0sXHJcbiAgICAgICAgaGFuZGxlRHJhZ092ZXI6IGZ1bmN0aW9uIChlKSB7XHJcbiAgICAgICAgICAgIHRoaXMuaXNIb3ZlcmVkID0gdHJ1ZTtcclxuICAgICAgICB9LFxyXG4gICAgICAgIGhhbmRsZURyYWdMZWF2ZTogZnVuY3Rpb24gKGUpIHtcclxuICAgICAgICAgICAgdGhpcy5pc0hvdmVyZWQgPSBmYWxzZTsgICAgICAgICAgICBcclxuICAgICAgICB9LFxyXG4gICAgICAgIG1vdmVNZWRpYVRvRm9sZGVyOiBmdW5jdGlvbiAoZm9sZGVyLCBlKSB7XHJcblxyXG4gICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcbiAgICAgICAgICAgIHNlbGYuaXNIb3ZlcmVkID0gZmFsc2U7XHJcblxyXG4gICAgICAgICAgICB2YXIgbWVkaWFOYW1lcyA9IEpTT04ucGFyc2UoZS5kYXRhVHJhbnNmZXIuZ2V0RGF0YSgnbWVkaWFOYW1lcycpKTsgXHJcblxyXG4gICAgICAgICAgICBpZiAobWVkaWFOYW1lcy5sZW5ndGggPCAxKSB7XHJcbiAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgIHZhciBzb3VyY2VGb2xkZXIgPSBlLmRhdGFUcmFuc2Zlci5nZXREYXRhKCdzb3VyY2VGb2xkZXInKTtcclxuICAgICAgICAgICAgdmFyIHRhcmdldEZvbGRlciA9IGZvbGRlci5wYXRoO1xyXG5cclxuICAgICAgICAgICAgaWYgKHNvdXJjZUZvbGRlciA9PT0gJycpIHtcclxuICAgICAgICAgICAgICAgIHNvdXJjZUZvbGRlciA9ICdyb290JztcclxuICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgaWYgKHRhcmdldEZvbGRlciA9PT0gJycpIHtcclxuICAgICAgICAgICAgICAgIHRhcmdldEZvbGRlciA9ICdyb290JztcclxuICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgaWYgKHNvdXJjZUZvbGRlciA9PT0gdGFyZ2V0Rm9sZGVyKSB7XHJcbiAgICAgICAgICAgICAgICBhbGVydCgkKCcjc2FtZUZvbGRlck1lc3NhZ2UnKS52YWwoKSk7XHJcbiAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgIGNvbmZpcm1EaWFsb2coey4uLiQoXCIjbW92ZU1lZGlhXCIpLmRhdGEoKSwgY2FsbGJhY2s6IGZ1bmN0aW9uIChyZXNwKSB7XHJcbiAgICAgICAgICAgICAgICBpZiAocmVzcCkge1xyXG4gICAgICAgICAgICAgICAgICAgICQuYWpheCh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJCgnI21vdmVNZWRpYUxpc3RVcmwnKS52YWwoKSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnUE9TVCcsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGRhdGE6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIF9fUmVxdWVzdFZlcmlmaWNhdGlvblRva2VuOiAkKFwiaW5wdXRbbmFtZT0nX19SZXF1ZXN0VmVyaWZpY2F0aW9uVG9rZW4nXVwiKS52YWwoKSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1lZGlhTmFtZXM6IG1lZGlhTmFtZXMsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBzb3VyY2VGb2xkZXI6IHNvdXJjZUZvbGRlcixcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRhcmdldEZvbGRlcjogdGFyZ2V0Rm9sZGVyXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHN1Y2Nlc3M6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJ1cy4kZW1pdCgnbWVkaWFMaXN0TW92ZWQnKTsgLy8gTWVkaWFBcHAgd2lsbCBsaXN0ZW4gdG8gdGhpcywgYW5kIHRoZW4gaXQgd2lsbCByZWxvYWQgcGFnZSBzbyB0aGUgbW92ZWQgbWVkaWFzIHdvbid0IGJlIHRoZXJlIGFueW1vcmVcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgZXJyb3I6IGZ1bmN0aW9uIChlcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcihlcnJvci5yZXNwb25zZVRleHQpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYnVzLiRlbWl0KCdtZWRpYUxpc3RNb3ZlZCcsIGVycm9yLnJlc3BvbnNlVGV4dCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfX0pO1xyXG4gICAgICAgIH1cclxuXHJcbiAgICB9XHJcbn0pO1xyXG4iLCIvLyBodHRwczovL2dpdGh1Yi5jb20vc3BhdGllL2ZvbnQtYXdlc29tZS1maWxldHlwZXNcclxuXHJcbmNvbnN0IGZhSWNvbnMgPSB7XHJcbiAgICBpbWFnZTogJ2ZhLXJlZ3VsYXIgZmEtaW1hZ2UnLFxyXG4gICAgcGRmOiAnZmEtcmVndWxhciBmYS1maWxlLXBkZicsXHJcbiAgICB3b3JkOiAnZmEtcmVndWxhciBmYS1maWxlLXdvcmQnLFxyXG4gICAgcG93ZXJwb2ludDogJ2ZhLXJlZ3VsYXIgZmEtZmlsZS1wb3dlcnBvaW50JyxcclxuICAgIGV4Y2VsOiAnZmEtcmVndW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gICAgICAgICAgICAgICAgICA6a2V5PVwibWVkaWEubmFtZVwiIFxyXG4gICAgICAgICAgICAgICAgICAgIGNsYXNzPVwibWVkaWEtaXRlbSBtZWRpYS1jb250YWluZXItbWFpbi1saXN0LWl0ZW0gY2FyZCBwLTBcIlxyXG4gICAgICAgICAgICAgICAgICAgIDpzdHlsZT1cInt3aWR0aDogdGh1bWJTaXplICsgMiArICdweCd9XCJcclxuICAgICAgICAgICAgICAgICAgICA6Y2xhc3M9XCJ7c2VsZWN0ZWQ6IGlzTWVkaWFTZWxlY3RlZChtZWRpYSl9XCJcclxuICAgICAgICAgICAgICAgICAgICB2LW9uOmNsaWNrLnN0b3A9XCJ0b2dnbGVTZWxlY3Rpb25PZk1lZGlhKG1lZGlhKVwiXHJcbiAgICAgICAgICAgICAgICAgICAgZHJhZ2dhYmxlPVwidHJ1ZVwiIHYtb246ZHJhZ3N0YXJ0PVwiZHJhZ1N0YXJ0KG1lZGlhLCAkZXZlbnQpXCI+XHJcbiAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cInRodW1iLWNvbnRhaW5lclwiIDpzdHlsZT1cIntoZWlnaHQ6IHRodW1iU2l6ZSArJ3B4J31cIj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgPGltZyB2LWlmPVwibWVkaWEubWltZS5zdGFydHNXaXRoKCdpbWFnZScpXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA6c3JjPVwiYnVpbGRNZWRpYVVybChtZWRpYS51cmwsIHRodW1iU2l6ZSlcIlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDpkYXRhLW1pbWU9XCJtZWRpYS5taW1lXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA6c3R5bGU9XCJ7bWF4SGVpZ2h0OiB0aHVtYlNpemUgKydweCcsIG1heFdpZHRoOiB0aHVtYlNpemUgKydweCd9XCIgLz5cclxuICAgICAgICAgICAgICAgICAgICAgICAgPGkgdi1lb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BzY29wZT1cImNvbFwiIHYtb246Y2xpY2s9XCJjaGFuZ2VTb3J0KCdsYXN0TW9kaWZ5JylcIj4gXHJcbiAgICAgICAgICAgICAgICAgICAgICAge3sgVC5sYXN0TW9kaWZ5SGVhZGVyIH19IFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgPHNvcnQtaW5kaWNhdG9yIGNvbG5hbWU9XCJsYXN0TW9kaWZ5XCIgOnNlbGVjdGVkY29sbmFtZT1cInNvcnRCeVwiIDphc2M9XCJzb3J0QXNjXCI+PC9zb3J0LWluZGljYXRvcj4gXHJcbiAgICAgICAgICAgICAgICAgICAgPC90aD4gXHJcbiAgICAgICAgICAgICAgICAgICAgPHRoIHNjb3BlPVwiY29sXCIgdi1vbjpjbGljaz1cImNoYW5nZVNvcnQoJ3NpemUnKVwiPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICA8c3BhbiBjbGFzcz1cIm9wdGlvbmFsLWNvbFwiPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAge3sgVC5zaXplSGVhZGVyIH19XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICA8c29ydC1pbmRpY2F0b3IgY29sbmFtZT1cInNpemVcIiA6c2VsZWN0ZWRjb2xuYW1lPVwic29ydEJ5XCIgOmFzYz1cInNvcnRBc2NcIj48L3NvcnQtaW5kaWNhdG9yPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICA8L3NwYW4+XHJcbiAgICAgICAgICAgICAgICAgICAgPC90aD5cclxuICAgICAgICAgICAgICAgICAgICA8dGggc2NvcGU9XCJjb2xcIiB2LW9uOmNsaWNrPVwiY2hhbmdlU29ydCgnbWltZScpXCI+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIDxzcGFuIGNsYXNzPVwib3B0aW9uYWwtY29sXCI+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgIHt7IFQudHlwZUhlYWRlciB9fVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgPHNvcnQtaW5kaWNhdG9yIGNvbG5hbWU9XCJtaW1lXCIgOnNlbGVjdGVkY29sbmFtZT1cInNvcnRCeVwiIDphc2M9XCJzb3J0QXNjXCI+PC9zb3J0LWluZGljYXRvcj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgPC9zcGFuPlxyXG4gICAgICAgICAgICAgICAgICAgIDwvdGg+XHJcbiAgICAgICAgICAgICAgICA8L3RyPlxyXG4gICAgICAgICAgICA8L3RoZWFkPlxyXG4gICAgICAgICAgICA8dGJvZHk+XHJcbiAgICAgICAgICAgICAgICAgICAgPHRyIHYtZm9yPVwibWVkaWEgaW4gZmlsdGVyZWRNZWRpYUl0ZW1zXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgICBjbGFzcz1cIm1lZGlhLWl0ZW1cIlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgIDpjbGFzcz1cIntzZWxlY3RlZDogaXNNZWRpYVNlbGVjdGVkKG1lZGlhKX1cIlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgIHYtb246Y2xpY2suc3RvcD1cInRvZ2dsZVNlbGVjdGlvbk9mTWVkaWEobWVkaWEpXCJcclxuICAgICAgICAgICAgICAgICAgICAgICAgICBkcmFnZ2FibGU9XCJ0cnVlXCIgdi1vbjpkcmFnc3RhcnQ9XCJkcmFnU3RhcnQobWVkaWEsICRldmVudClcIlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgIDprZXk9XCJtZWRpYS5uYW1lXCI+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPHRkIGNsYXNzPVwidGh1bWJuYWlsLWNvbHVtblwiPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJpbWctd3JhcHBlclwiPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8aW1nIHYtaWY9XCJtZWRpYS5taW1lLnN0YXJ0c1dpdGgoJ2ltYWdlJylcIiBkcmFnZ2FibGU9XCJmYWxzZVwiIDpzcmM9XCJidWlsZE1lZGlhVXJsKG1lZGlhLnVybCwgdGh1bWJTaXplKVwiIC8+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxpIHYtZWxzZSA6Y2xhc3M9XCJnZXRmb250QXdlc29tZUNsYXNzTmFtZUZvckZpbGVOYW1lKG1lZGlhLm5hbWUsIFxcJ2ZhLTR4XFwnKVwiIDpkYXRhLW1pbWU9XCJtZWRpYS5taW1lXCI+PC9pPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDwvZGl2PlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPC90ZD5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDx0ZD5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwibWVkaWEtbmFtZS1jZWxsXCI+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPHNwYW4gY2xhc3M9XCJicmVhay13b3JkXCI+IHt7IG1lZGlhLm5hbWUgfX0gPC9zcGFuPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwiYnV0dG9ucy1jb250YWluZXJcIj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxhIGhyZWY9XCJqYXZhc2NyaXB0OjtcIiBjbGFzcz1cImJ0biBidG4tbGluayBidG4tc20gbWUtMSBlZGl0LWJ1dHRvblwiIHYtb246Y2xpY2suc3RvcD1cInJlbmFtZU1lZGlhKG1lZGlhKVwiPiB7eyBULmVkaXRCdXR0b24gfX0gPC9hID5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxhIGhyZWY9XCJqYXZhc2NyaXB0OjtcIiBjbGFzcz1cImJ0biBidG4tbGluayBidG4tc20gZGVsZXRlLWJ1dHRvblwiIHYtb246Y2xpY2suc3RvcD1cImRlbGV0ZU1lZGlhKG1lZGlhKVwiPiB7eyBULmRlbGV0ZUJ1dHRvbiB9fSA8L2E+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8YSA6aHJlZj1cIm1lZGlhLnVybFwiIHRhcmdldD1cIl9ibGFua1wiIGNsYXNzPVwiYnRuIGJ0bi1saW5rIGJ0bi1zbSB2aWV3LWJ1dHRvblwiPiB7eyBULnZpZXdCdXR0b24gfX0gPC9hPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDwvdGQ+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICA8dGQ+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cInRleHQtY29sXCI+IHt7IHByaW50RGF0ZVRpbWUobWVkaWEubGFzdE1vZGlmeSkgfX0gPC9kaXY+XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICA8L3RkPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPHRkPlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJ0ZXh0LWNvbCBvcHRpb25hbC1jb2xcIj4ge3sgaXNOYU4obWVkaWEuc2l6ZSk/IDAgOiBNYXRoLnJvdW5kKG1lZGlhLnNpemUgLyAxMDI0KSB9fSBLQjwvZGl2PlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPC90ZD5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDx0ZD5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwidGV4dC1jb2wgb3B0aW9uYWwtY29sXCI+e3sgbWVkaWEubWltZSB9fTwvZGl2PlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPC90ZD5cclxu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AgICAgICAgICAgICAgICAgICAgICAgPC9zZWxlY3Q+XHJcbiAgICAgICAgICAgICAgICAgICAgPC9kaXY+XHJcbiAgICAgICAgICAgICAgICA8L2xpPlxyXG4gICAgICAgICAgICA8L3VsPlxyXG4gICAgICAgIDwvbmF2PlxyXG4gICAgICAgIDxuYXYgY2xhc3M9XCJkLWZsZXgganVzdGlmeS1jb250ZW50LWNlbnRlclwiPlxyXG4gICAgICAgICAgICA8dWwgY2xhc3M9XCJwYWdpbmF0aW9uIHBhZ2luYXRpb24tc20gbS0wIG10LTJcIj5cclxuICAgICAgICAgICAgICAgIDxsaSBjbGFzcz1cInBhZ2UtaXRlbSBtcy00IHBhZ2UtaW5mb1wiPlxyXG4gICAgICAgICAgICAgICAgICAgIDxzcGFuIGNsYXNzPVwicGFnZS1saW5rIGRpc2FibGVkIHRleHQtbXV0ZWQgXCI+e3sgVC5wYWdlclBhZ2VMYWJlbCB9fSB7e2N1cnJlbnQgKyAxfX0ve3t0b3RhbFBhZ2VzfX08L3NwYW4+XHJcbiAgICAgICAgICAgICAgICA8L2xpPlxyXG4gICAgICAgICAgICAgICAgPGxpIGNsYXNzPVwicGFnZS1pdGVtIG1zLTQgdG90YWwtaW5mb1wiPlxyXG4gICAgICAgICAgICAgICAgICAgIDxzcGFuIGNsYXNzPVwicGFnZS1saW5rIGRpc2FibGVkIHRleHQtbXV0ZWQgXCI+IHt7IFQucGFnZXJUb3RhbExhYmVsIH19IHt7dG90YWx9fTwvc3Bhbj5cclxuICAgICAgICAgICAgICAgIDwvbGk+XHJcbiAgICAgICAgICAgIDwvdWw+XHJcbiAgICAgICAgPC9uYXY+XHJcbiAgICAgICAgPC9kaXY+XHJcbiAgICAgICAgYCxcclxuICAgIHByb3BzOiB7XHJcbiAgICAgICAgc291cmNlSXRlbXM6IEFycmF5XHJcbiAgICB9LFxyXG4gICAgZGF0YTogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgIHJldHVybiB7XHJcbiAgICAgICAgICAgIHBh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WVkaWFGaWVsZEFwcCA9IG5ldyBWdWUoe1xyXG4gICAgICAgIGVsOiBtZWRpYUZpZWxkRWRpdG9yLmdldCgwKSxcclxuICAgICAgICBkYXRhOiB7XHJcbiAgICAgICAgICAgIG1lZGlhSXRlbXM6IFtdLFxyXG4gICAgICAgICAgICBzZWxlY3RlZE1lZGlhOiBudWxsLFxyXG4gICAgICAgICAgICBzbWFsbFRodW1iczogZmFsc2UsXHJcbiAgICAgICAgICAgIGlkUHJlZml4OiBpZHByZWZpeCxcclxuICAgICAgICAgICAgaW5pdGlhbGl6ZWQ6IGZhbHNlLFxyXG4gICAgICAgICAgICBhbGxvd01lZGlhVGV4dDogYWxsb3dNZWRpYVRleHQsXHJcbiAgICAgICAgICAgIGJhY2t1cE1lZGlhVGV4dDogJycsXHJcbiAgICAgICAgICAgIGFsbG93QW5jaG9yczogYWxsb3dBbmNob3JzLFxyXG4gICAgICAgICAgICBiYWNrdXBBbmNob3I6IG51bGwsXHJcbiAgICAgICAgICAgIG1lZGlhVGV4dG1vZGFsOiBudWxsLFxyXG4gICAgICAgICAgICBhbmNob3JpbmdNb2RhbDogbnVsbFxyXG4gICAgICAgIH0sXHJcbiAgICAgICAgY3JlYXRlZDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcblxyXG4gICAgICAgICAgICBzZWxmLmN1cnJlbnRQcmVmcyA9IEpTT04ucGFyc2UobG9jYWxTdG9yYWdlLmdldEl0ZW0oJ21lZGlhRmllbGRQcmVmcycpKTtcclxuICAgICAgICB9LFxyXG4gICAgICAgIGNvbXB1dGVkOiB7XHJcbiAgICAgICAgICAgIHBhdGhzOiB7XHJcbiAgICAgICAgICAgICAgICBnZXQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgbWVkaWFQYXRocyA9IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgIGlmICghdGhpcy5pbml0aWFsaXplZCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gSlNPTi5zdHJpbmdpZnkoaW5pdGlhbFBhdGhzKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5tZWRpYUl0ZW1zLmZvckVhY2goZnVuY3Rpb24gKHgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHgubWVkaWFQYXRoID09PSAnbm90LWZvdW5kJykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG1lZGlhUGF0aHMucHVzaCh7IHBhdGg6IHgubWVkaWFQYXRoLCBpc1JlbW92ZWQ6IHguaXNSZW1vdmVkLCBpc05ldzogeC5pc05ldywgbWVkaWFUZXh0OiB4Lm1lZGlhVGV4dCwgYW5jaG9yOiB4LmFuY2hvciwgYXR0YWNoZWRGaWxlTmFtZTogeC5hdHRhY2hlZEZpbGVOYW1lIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBKU09OLnN0cmluZ2lmeShtZWRpYVBhdGhzKTtcclxuICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBzZXQ6IGZ1bmN0aW9uICh2YWx1ZXMpIHtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIG1lZGlhUGF0aHMgPSB2YWx1ZXMgfHwgW107XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIHNpZ25hbCA9ICQuRGVmZXJyZWQoKTtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgaXRlbXMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgbGVuZ3RoID0gMDtcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYVBhdGhzLmZvckVhY2goZnVuY3Rpb24gKHgsIGkpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaXRlbXMucHVzaCh7IG5hbWU6ICcgJyArIHgucGF0aCwgbWltZTogJycsIG1lZGlhUGF0aDogJycsIGFuY2hvcjogeC5hbmNob3IsIGF0dGFjaGVkRmlsZU5hbWU6IHguYXR0YWNoZWRGaWxlTmFtZSB9KTsgLy8gZG9uJ3QgcmVtb3ZlIHRoZSBzcGFjZS4gU29tZXRoaW5nIGRpZmZlcmVudCBpcyBuZWVkZWQgb3IgaXQgd29udCByZWFjdCB3aGVuIHRoZSByZWFsIG5hbWUgYXJyaXZlcy5cclxuICAgICAgICAgICAgICAgICAgICAgICAgcHJvbWlzZSA9ICQud2hlbihzaWduYWwpLmRvbmUoZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgJC5hamF4KHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IG1lZGlhSXRlbVVybCArIFwiP3BhdGg9XCIgKyBlbmNvZGVVUklDb21wb25lbnQoeC5wYXRoKSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICdHRVQnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHN1Y2Nlc3M6IGZ1bmN0aW9uIChkYXRhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGEudnVla2V5ID0gZGF0YS5uYW1lICsgaS50b1N0cmluZygpOyAvLyBCZWNhdXNlIGEgdW5pcXVlIGtleSBpcyByZXF1aXJlZCBieSBWdWUgb24gdi1mb3IgXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGEubWVkaWFUZXh0ID0geC5tZWRpYVRleHQ7IC8vIFRoaXMgdmFsdWUgaXMgbm90IHJldHVybmVkIGZyb20gdGhlIGFqYXggY2FsbC5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS5hbmNob3IgPSB4LmFuY2hvcjsgLy8gVGhpcyB2YWx1ZSBpcyBub3QgcmV0dXJuZWQgZnJvbSB0aGUgYWpheCBjYWxsLlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhLmF0dGFjaGVkRmlsZU5hbWUgPSB4LmF0dGFjaGVkRmlsZU5hbWU7Ly8gVGhpcyB2YWx1ZSBpcyBub3QgcmV0dXJuZWQgZnJvbSB0aGUgYWpheCBjYWxsLlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtcy5zcGxpY2UoaSwgMSwgZGF0YSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpdGVtcy5sZW5ndGggPT09ICsrbGVuZ3RoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtcy5mb3JFYWNoKGZ1bmN0aW9uICh4KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5tZWRpYUl0ZW1zLnB1c2goeCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuaW5pdGlhbGl6ZWQgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlcnJvcjogZnVuY3Rpb24gKGVycm9yKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKEpTT04uc3RyaW5naWZ5KGVycm9yKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGl0ZW1zLnNwbGljZShpLCAxLCB7IG5hbWU6IHgucGF0aCwgbWltZTogJycsIG1lZGlhUGF0aDogJ25vdC1mb3VuZCcsIG1lZGlhVGV4dDogJycsIGFuY2hvcjogeyB4OiAwLjUsIHk6IDAuNSB9LCBhdHRhY2hlZEZpbGVOYW1lOiB4LmF0dGFjaGVkRmlsZU5hbWUgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpdGVtcy5sZW5ndGggPT09ICsrbGVuZ3RoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtcy5mb3JFYWNoKGZ1bmN0aW9uICh4KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5tZWRpYUl0ZW1zLnB1c2goeCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuaW5pdGlhbGl6ZWQgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBzaWduYWwucmVzb2x2ZSgpO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBmaWxlU2l6ZTogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuIE1hdGgucm91bmQodGhpcy5zZWxlY3RlZE1lZGlhLnNpemUgLyAxMDI0KTtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgY2FuQWRkTWVkaWE6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgIHZhciBub25SZW1vdmVkTWVkaWFJdGVtcyA9IFtdO1xyXG4gICAgICAgICAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCB0aGlzLm1lZGlhSXRlbXMubGVuZ3RoOyBpKyspIHtcclxuICAgICAgICAgICAgICAgICAgICBpZiAoIXRoaXMubWVkaWFJdGVtc1tpXS5pc1JlbW92ZWQpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgbm9uUmVtb3ZlZE1lZGlhSXRlbXMucHVzaCh0aGlzLm1lZGlhSXRlbXNbaV0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICByZXR1cm4gbm9uUmVtb3ZlZE1lZGlhSXRlbXMubGVuZ3RoID09PSAwIHx8IG5vblJlbW92ZWRNZWRpYUl0ZW1zLmxlbmd0aCA+IDAgJiYgYWxsb3dNdWx0aXBsZTtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgdGh1bWJTaXplOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICByZXR1cm4gdGhpcy5zbWFsbFRodW1icyA/IDEyMCA6IDI0MDtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgY3VycmVudFByZWZzOiB7XHJcbiAgICAgICAgICAgICAgICBnZXQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBzbWFsbFRodW1iczogdGhpcy5zbWFsbFRodW1ic1xyXG4gICAgICAgICAgICAgICAgICAgIH07XHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgc2V0OiBmdW5jdGlvbiAobmV3UHJlZnMpIHtcclxuICAgICAgICAgICAgICAgICAgICBpZiAoIW5ld1ByZWZzKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5zbWFsbFRodW1icyA9IG5ld1ByZWZzLnNtYWxsVGh1bWJzO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSxcclxuICAgICAgICBtb3VudGVkOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuXHJcbiAgICAgICAgICAgIHNlbGYucGF0aHMgPSBpbml0aWFsUGF0aHM7XHJcblxyXG4gICAgICAgICAgICBzZWxmLiRvbignc2VsZWN0QW5kRGVsZXRlTWVkaWFSZXF1ZXN0ZWQnLCBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0QW5kRGVsZXRlTWVkaWEobWVkaWEpO1xyXG4gICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgIHNlbGYuJG9uKCdzZWxlY3RNZWRpYVJlcXVlc3RlZCcsIGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RNZWRpYShtZWRpYSk7XHJcbiAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgdmFyIHNlbGVjdG9yID0gJyMnICsgaWRPZlVwbG9hZEJ1dHRvbjtcclxuICAgICAgICAgICAgdmFyIGVkaXRvcklkID0gbWVkaWFGaWVsZEVkaXRvci5hdHRyKCdpZCcpO1xyXG4gICAgICAgICAgICB2YXIgY2h1bmtlZEZpbGVVcGxvYWRJZCA9IHJhbmRvbVVVSUQoKTtcclxuXHJcbiAgICAgICAgICAgICQoc2VsZWN0b3IpXHJcbiAgICAgICAgICAgICAgICAuZmlsZXVwbG9hZCh7XHJcbiAgICAgICAgICAgICAgICAgICAgbGltaXRDb25jdXJyZW50VXBsb2FkczogMjAsXHJcbiAgICAgICAgICAgICAgICAgICAgZHJvcFpvbmU6ICQoJyMnICsgZWRpdG9ySWQpLFxyXG4gICAgICAgICAgICAgICAgICAgIGRhdGFUeXBlOiAnanNvbicsXHJcbiAgICAgICAgICAgICAgICAgICAgdXJsOiB1cGxvYWRBY3Rpb24sXHJcbiAgICAgICAgICAgICAgICAgICAgbWF4Q2h1bmtTaXplOiBtYXhVcGxvYWRDaHVua1NpemUsXHJcbiAgICAgICAgICAgICAgICAgICAgYWRkOiBmdW5jdGlvbiAoZSwgZGF0YSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgY291bnQgPSBkYXRhLmZpbGVzLmxlbmd0aDtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGZvciAoaSA9IDA7IGkgPCBjb3VudDsgaSsrKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhLmZpbGVzW2ldLnVwbG9hZE5hbWUgPVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuZ2V0VW5pcXVlSWQoKSArIGRhdGEuZmlsZXNbaV0ubmFtZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGEuZmlsZXNbaV0uYXR0YWNoZWRGaWxlTmFtZSA9IGRhdGEuZmlsZXNbaV0ubmFtZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICBkYXRhLnN1Ym1pdCgpO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgZm9ybURhdGE6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGFudGlGb3JnZXJ5VG9rZW4gPSAkKFwiaW5wdXRbbmFtZT1fX1JlcXVlc3RWZXJpZmljYXRpb25Ub2tlbl1cIikudmFsKCk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gW1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgeyBuYW1lOiAncGF0aCcsIHZhbHVlOiB0ZW1wVXBsb2FkRm9sZGVyIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB7IG5hbWU6ICdfX1JlcXVlc3RWZXJpZmljYXRpb25Ub2tlbicsIHZhbHVlOiBhbnRpRm9yZ2VyeVRva2VuIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB7IG5hbWU6ICdfX2NodW5rZWRGaWxlVXBsb2FkSWQnLCB2YWx1ZTogY2h1bmtlZEZpbGVVcGxvYWRJZCB9LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBdO1xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgZG9uZTogZnVuY3Rpb24gKGUsIGRhdGEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG5ld01lZGlhSXRlbXMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGVycm9ybXNnID0gXCJcIjtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChkYXRhLnJlc3VsdC5maWxlcy5sZW5ndGggPiAwKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBmb3IgKHZhciBpID0gMDsgaSA8IGRhdGEucmVzdWx0LmZpbGVzLmxlbmd0aDsgaSsrKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS5yZXN1bHQuZmlsZXNbaV0uaXNOZXcgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vaWYgZXJyb3IgaXMgZGVmaW5lZCBwcm9iYWJseSB0aGUgZmlsZSB0eXBlIGlzIG5vdCBhbGxvd2VkXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGRhdGEucmVzdWx0LmZpbGVzW2ldLmVycm9yID09PSB1bmRlZmluZWQgfHwgZGF0YS5yZXN1bHQuZmlsZXNbaV0uZXJyb3IgPT09IG51bGwpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS5yZXN1bHQuZmlsZXNbaV0uYXR0YWNoZWRGaWxlTmFtZSA9IGRhdGEuZmlsZXNbaV0uYXR0YWNoZWRGaWxlTmFtZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbmV3TWVkaWFJdGVtcy5wdXNoKGRhdGEucmVzdWx0LmZpbGVzW2ldKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZWxzZVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlcnJvcm1zZyArPSBkYXRhLnJlc3VsdC5maWxlc1tpXS5lcnJvciArIFwiXFxuXCI7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChlcnJvcm1zZyAhPT0gXCJcIikge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYWxlcnQoZXJyb3Jtc2cpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKG5ld01lZGlhSXRlbXMpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAobmV3TWVkaWFJdGVtcy5sZW5ndGggPiAxICYmIGFsbG93TXVsdGlwbGUgPT09IGZhbHNlKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBhbGVydCgkKCcjb25seU9uZUl0ZW1NZXNzYWdlJykudmFsKCkpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbWVkaWFGaWVsZEFwcC5tZWRpYUl0ZW1zLnB1c2gobmV3TWVkaWFJdGVtc1swXSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZWRpYUZpZWxkQXBwLmluaXRpYWxpemVkID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1lZGlhRmllbGRBcHAubWVkaWFJdGVtcyA9IG1lZGlhRmllbGRBcHAubWVkaWFJdGVtcy5jb25jYXQobmV3TWVkaWFJdGVtcyk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZWRpYUZpZWxkQXBwLmluaXRpYWxpemVkID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICAgICAgZXJyb3I6IGZ1bmN0aW9uIChqcVhIUiwgdGV4dFN0YXR1cywgZXJyb3JUaHJvd24pIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2coJ0Vycm9yIG9uIHVwbG9hZC4nKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2coanFYSFIpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmxvZyh0ZXh0U3RhdHVzKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2coZXJyb3JUaHJvd24pO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH0pXHJcbiAgICAgICAgICAgICAgICAub24oJ2ZpbGV1cGxvYWRjaHVua2JlZm9yZXNlbmQnLCAoZSwgb3B0aW9ucykgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgIGxldCBmaWxlID0gb3B0aW9ucy5maWxlc1swXTtcclxuICAgICAgICAgICAgICAgICAgICAvLyBIZXJlIHdlIHJlcGxhY2UgdGhlIGJsb2Igd2l0aCBhIEZpbGUgb2JqZWN0IHRvIGVuc3VyZSB0aGUgZmlsZSBuYW1lIGFuZCBvdGhlcnMgYXJlIHByZXNlcnZlZCBmb3IgdGhlIGJhY2tlbmQuXHJcbiAgICAgICAgICAgICAgICAgICAgb3B0aW9ucy5ibG9iID0gbmV3IEZpbGUoXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIFtvcHRpb25zLmJsb2JdLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBmaWxlLm5hbWUsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHR5cGU6IGZpbGUudHlwZSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxhc3RNb2RpZmllZDogZmlsZS5sYXN0TW9kaWZpZWQsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgfSxcclxuICAgICAgICBtZXRob2RzOiB7XHJcbiAgICAgICAgICAgIHNlbGVjdE1lZGlhOiBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYSA9IG1lZGlhO1xyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBnZXRVbmlxdWVJZDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuICd4eHh4eHh4eC14eHh4LTR4eHgteXh4eC14eHh4eHh4eHh4eHgnLnJlcGxhY2UoL1t4eV0vZywgZnVuY3Rpb24gKGMpIHtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgciA9IE1hdGgucmFuZG9tKCkgKiAxNiB8IDAsIHYgPSBjID09PSAneCcgPyByIDogKHIgJiAweDMgfCAweDgpO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiB2LnRvU3RyaW5nKDE2KTtcclxuICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICByZW1vdmVTZWxlY3RlZDogZnVuY3Rpb24gKGV2ZW50KSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgcmVtb3ZlZCA9IHt9O1xyXG4gICAgICAgICAgICAgICAgaWYgKHRoaXMuc2VsZWN0ZWRNZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBpbmRleCA9IHRoaXMubWVkaWFJdGVtcyAmJiB0aGlzLm1lZGlhSXRlbXMuaW5kZXhPZih0aGlzLnNlbGVjdGVkTWVkaWEpO1xyXG4gICAgICAgICAgICAgICAgICAgIGlmIChpbmRleCA+IC0xKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJlbW92ZWQgPSB0aGlzLm1lZGlhSXRlbXNbaW5kZXhdO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZW1vdmVkLmlzUmVtb3ZlZCA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vdGhpcy5tZWRpYUl0ZW1zLnNwbGljZShbaW5kZXhdLCAxLCByZW1vdmVkKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5tZWRpYUl0ZW1zLnNwbGljZShpbmRleCwgMSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgLy8gVGhlIHJlbW92ZSBidXR0b24gY2FuIGFsc28gcmVtb3ZlIGEgdW5pcXVlIG1lZGlhIGl0ZW1cclxuICAgICAgICAgICAgICAgICAgICBpZiAodGhpcy5tZWRpYUl0ZW1zLmxlbmd0aCA9PT0gMSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZW1vdmVkID0gdGhpcy5tZWRpYUl0ZW1zW2luZGV4XTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmVtb3ZlZC5pc1JlbW92ZWQgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAvL3RoaXMubWVkaWFJdGVtcy5zcGxpY2UoMCwgMSwgcmVtb3ZlZCk7ICAgICAgICAgICAgICAgICAgICAgICAgXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMubWVkaWFJdGVtcy5zcGxpY2UoMCwgMSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhID0gbnVsbDtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgc2hvd01lZGlhVGV4dE1vZGFsOiBmdW5jdGlvbiAoZXZlbnQpIHtcclxuICAgICAgICAgICAgICAgIHRoaXMubWVkaWFUZXh0TW9kYWwgPSBuZXcgYm9vdHN0cmFwLk1vZGFsKHRoaXMuJHJlZnMubWVkaWFUZXh0TW9kYWwpO1xyXG4gICAgICAgICAgICAgICAgdGhpcy5tZWRpYVRleHRNb2RhbC5zaG93KCk7XHJcbiAgICAgICAgICAgICAgICB0aGlzLmJhY2t1cE1lZGlhVGV4dCA9IHRoaXMuc2VsZWN0ZWRNZWRpYS5tZWRpYVRleHQ7XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGNhbmNlbE1lZGlhVGV4dE1vZGFsOiBmdW5jdGlvbiAoZXZlbnQpIHtcclxuICAgICAgICAgICAgICAgIHRoaXMubWVkaWFUZXh0TW9kYWwuaGlkZSgpO1xyXG4gICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhLm1lZGlhVGV4dCA9IHRoaXMuYmFja3VwTWVkaWFUZXh0O1xyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBzaG93QW5jaG9yTW9kYWw6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5hbmNob3JpbmdNb2RhbCA9IG5ldyBib290c3RyYXAuTW9kYWwodGhpcy4kcmVmcy5hbmNob3JpbmdNb2RhbCk7XHJcbiAgICAgICAgICAgICAgICB0aGlzLmFuY2hvcmluZ01vZGFsLnNob3coKTtcclxuICAgICAgICAgICAgICAgIC8vIENhdXNlIGEgcmVmcmVzaCB0byByZWNhbGMgaGVpZ2h0cy5cclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IgPSB7XHJcbiAgICAgICAgICAgICAgICAgICAgeDogdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvci54LFxyXG4gICAgICAgICAgICAgICAgICAgIHk6IHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IueVxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgdGhpcy5iYWNrdXBBbmNob3IgPSB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yO1xyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBjYW5jZWxBbmNob3JpbmdNb2RhbDogZnVuY3Rpb24gKGV2ZW50KSB7XHJcbiAgICAgICAgICAgICAgICB0aGlzLmFuY2hvcmluZ01vZGFsLmhpZGUoKTtcclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IgPSB0aGlzLmJhY2t1cEFuY2hvcjtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgcmVzZXRBbmNob3I6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvciA9IHsgeDogMC41LCB5OiAwLjUgfTtcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgb25BbmNob3JEcm9wOiBmdW5jdGlvbiAoZXZlbnQpIHtcclxuICAgICAgICAgICAgICAgIHZhciBpbWFnZSA9IHRoaXMuJHJlZnMuYW5jaG9ySW1hZ2U7XHJcbiAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yID0ge1xyXG4gICAgICAgICAgICAgICAgICAgIHg6IGV2ZW50Lm9mZnNldFggLyBpbWFnZS5jbGllbnRXaWR0aCxcclxuICAgICAgICAgICAgICAgICAgICB5OiBldmVudC5vZmZzZXRZIC8gaW1hZ2UuY2xpZW50SGVpZ2h0XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGFuY2hvckxlZnQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgIGlmICh0aGlzLiRyZWZzLmFuY2hvckltYWdlICYmIHRoaXMuJHJlZnMubW9kYWxCb2R5ICYmIHRoaXMuc2VsZWN0ZWRNZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgICAgIC8vIFdoZW4gaW1hZ2UgaXMgc2hydW5rIGNvbXBhcmUgYWdhaW5zdCB0aGUgbW9kYWwgYm9keS5cclxuICAgICAgICAgICAgICAgICAgICB2YXIgb2Zmc2V0ID0gKHRoaXMuJHJlZnMubW9kYWxCb2R5LmNsaWVudFdpZHRoIC0gdGhpcy4kcmVmcy5hbmNob3JJbWFnZS5jbGllbnRXaWR0aCkgLyAyO1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBwb3NpdGlvbiA9ICh0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yLnggKiB0aGlzLiRyZWZzLmFuY2hvckltYWdlLmNsaWVudFdpZHRoKSArIG9mZnNldDtcclxuICAgICAgICAgICAgICAgICAgICBpZiAocG9zaXRpb24gPCAxNykgeyAvLyBBZGp1c3Qgc28gdGhlIHRhcmdldCBkb2Vzbid0IHNob3cgb3V0c2lkZSBpbWFnZS5cclxuICAgICAgICAgICAgICAgICAgICAgICAgcG9zaXRpb24gPSAxNztcclxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBwb3NpdGlvbiA9IHBvc2l0aW9uIC0gODsgLy8gQWRqdXN0IHRvIGhpdCB0aGUgbW91c2UgcG9pbnRlci5cclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHBvc2l0aW9uICsgJ3B4JztcclxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuICcwJztcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgYW5jaG9yVG9wOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICBpZiAodGhpcy4kcmVmcy5hbmNob3JJbWFnZSAmJiB0aGlzLnNlbGVjdGVkTWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgcG9zaXRpb24gPSB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yLnkgKiB0aGlzLiRyZWZzLmFuY2hvckltYWdlLmNsaWVudEhlaWdodDtcclxuICAgICAgICAgICAgICAgICAgICBpZiAocG9zaXRpb24gPCAxNSkgeyAvLyBBZGp1c3RtZW50IHNvIHRoZSB0YXJnZXQgZG9lc24ndCBzaG93IG91dHNpZGUgaW1hZ2UuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHBvc2l0aW9uID0gMTU7XHJcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcG9zaXRpb24gPSBwb3NpdGlvbiArIDU7IC8vIEFkanVzdCB0byBoaXQgdGhlIG1vdXNlIHBvaW50ZXIuXHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBwb3NpdGlvbiArICdweCc7XHJcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiAnMCc7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIHNldEFuY2hvcjogZnVuY3Rpb24gKGV2ZW50KSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgaW1hZ2UgPSB0aGlzLiRyZWZzLmFuY2hvckltYWdlO1xyXG4gICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvciA9IHtcclxuICAgICAgICAgICAgICAgICAgICB4OiBldmVudC5vZmZzZXRYIC8gaW1hZ2UuY2xpZW50V2lkdGgsXHJcbiAgICAgICAgICAgICAgICAgICAgeTogZXZlbnQub2Zmc2V0WSAvIGltYWdlLmNsaWVudEhlaWdodFxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBhZGRNZWRpYUZpbGVzOiBmdW5jdGlvbiAoZmlsZXMpIHtcclxuICAgICAgICAgICAgICAgIGlmICgoZmlsZXMubGVuZ3RoID4gMSkgJiYgKGFsbG93TXVsdGlwbGUgPT09IGZhbHNlKSkge1xyXG4gICAgICAgICAgICAgICAgICAgIGFsZXJ0KCQoJyNvbmx5T25lSXRlbU1lc3NhZ2UnKS52YWwoKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgbWVkaWFGaWVsZEFwcC5tZWRpYUl0ZW1zLnB1c2goZmlsZXNbMF0pO1xyXG4gICAgICAgICAgICAgICAgICAgIG1lZGlhRmllbGRBcHAuaW5pdGlhbGl6ZWQgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUZpZWxkQXBwLm1lZGlhSXRlbXMgPSBtZWRpYUZpZWxkQXBwLm1lZGlhSXRlbXMuY29uY2F0KGZpbGVzKTtcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUZpZWxkQXBwLmluaXRpYWxpemVkID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgc2VsZWN0QW5kRGVsZXRlTWVkaWE6IGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG4gICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RlZE1lZGlhID0gbWVkaWE7XHJcbiAgICAgICAgICAgICAgICAvLyBzZXRUaW1lb3V0IGJlY2F1c2Ugc29tZXRpbWVzIFxyXG4gICAgICAgICAgICAgICAgLy8gcmVtb3ZlU2VsZWN0ZWQgd2FzIGNhbGxlZCBldmVuIGJlZm9yZSB0aGUgbWVkaWEgd2FzIHNldC5cclxuICAgICAgICAgICAgICAgIHNldFRpbWVvdXQoZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgIHNlbGYucmVtb3ZlU2VsZWN0ZWQoKTtcclxuICAgICAgICAgICAgICAgIH0sIDEwMCk7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9LFxyXG4gICAgICAgIHdhdGNoOiB7XHJcbiAgICAgICAgICAgIG1lZGlhSXRlbXM6IHtcclxuICAgICAgICAgICAgICAgIGRlZXA6IHRydWUsXHJcbiAgICAgICAgICAgICAgICBoYW5kbGVyKCkge1xyXG4gICAgICAgICAgICAgICAgICAgIC8vIFRyaWdnZXIgcHJldmlldyByZW5kZXJpbmdcclxuICAgICAgICAgICAgICAgICAgICBzZXRUaW1lb3V0KGZ1bmN0aW9uICgpIHsgJChkb2N1bWVudCkudHJpZ2dlcignY29udGVudHByZXZpZXc6cmVuZGVyJyk7IH0sIDEwMCk7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGN1cnJlbnRQcmVmczogZnVuY3Rpb24gKG5ld1ByZWZzKSB7XHJcbiAgICAgICAgICAgICAgICBsb2NhbFN0b3JhZ2Uuc2V0SXRlbSgnbWVkaWFGaWVsZFByZWZzJywgSlNPTi5zdHJpbmdpZnkobmV3UHJlZnMpKTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH1cclxuICAgIH0pKTtcclxufVxyXG4iLCJmdW5jdGlvbiBpbml0aWFsaXplTWVkaWFGaWVsZChlbCwgbW9kYWxCb2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ICAgICBzZWxlY3RlZE1lZGlhOiBudWxsLFxyXG4gICAgICAgICAgICBzbWFsbFRodW1iczogZmFsc2UsXHJcbiAgICAgICAgICAgIGlkUHJlZml4OiBpZHByZWZpeCxcclxuICAgICAgICAgICAgaW5pdGlhbGl6ZWQ6IGZhbHNlLFxyXG4gICAgICAgICAgICBhbGxvd01lZGlhVGV4dDogYWxsb3dNZWRpYVRleHQsXHJcbiAgICAgICAgICAgIGJhY2t1cE1lZGlhVGV4dDogJycsXHJcbiAgICAgICAgICAgIGFsbG93QW5jaG9yczogYWxsb3dBbmNob3JzLFxyXG4gICAgICAgICAgICBiYWNrdXBBbmNob3I6IG51bGwsXHJcbiAgICAgICAgICAgIG1lZGlhVGV4dE1vZGFsOiBudWxsLFxyXG4gICAgICAgICAgICBhbmNob3JpbmdNb2RhbDogbnVsbFxyXG4gICAgICAgIH0sXHJcbiAgICAgICAgY3JlYXRlZDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcblxyXG4gICAgICAgICAgICBzZWxmLmN1cnJlbnRQcmVmcyA9IEpTT04ucGFyc2UobG9jYWxTdG9yYWdlLmdldEl0ZW0oJ21lZGlhRmllbGRQcmVmcycpKTtcclxuICAgICAgICB9LFxyXG4gICAgICAgIGNvbXB1dGVkOiB7XHJcbiAgICAgICAgICAgIHBhdGhzOiB7XHJcbiAgICAgICAgICAgICAgICBnZXQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgbWVkaWFQYXRocyA9IFtdO1xyXG4gICAgICAgICAgICAgICAgICAgIGlmICghdGhpcy5pbml0aWFsaXplZCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gSlNPTi5zdHJpbmdpZnkoaW5pdGlhbFBhdGhzKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5tZWRpYUl0ZW1zLmZvckVhY2goZnVuY3Rpb24gKHgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHgubWVkaWFQYXRoID09PSAnbm90LWZvdW5kJykge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG1lZGlhUGF0aHMucHVzaCh7IHBhdGg6IHgubWVkaWFQYXRoLCBtZWRpYVRleHQ6IHgubWVkaWFUZXh0LCBhbmNob3I6IHguYW5jaG9yIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBKU09OLnN0cmluZ2lmeShtZWRpYVBhdGhzKTtcclxuICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBzZXQ6IGZ1bmN0aW9uICh2YWx1ZXMpIHtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgc2VsZiA9IHRoaXM7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIG1lZGlhUGF0aHMgPSB2YWx1ZXMgfHwgW107XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIHNpZ25hbCA9ICQuRGVmZXJyZWQoKTtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgaXRlbXMgPSBbXTtcclxuICAgICAgICAgICAgICAgICAgICB2YXIgbGVuZ3RoID0gMDtcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYVBhdGhzLmZvckVhY2goZnVuY3Rpb24gKHgsIGkpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaXRlbXMucHVzaCh7IG5hbWU6ICcgJyArIHgucGF0aCwgbWltZTogJycsIG1lZGlhUGF0aDogJycgfSk7IC8vIGRvbid0IHJlbW92ZSB0aGUgc3BhY2UuIFNvbWV0aGluZyBkaWZmZXJlbnQgaXMgbmVlZGVkIG9yIGl0IHdvbnQgcmVhY3Qgd2hlbiB0aGUgcmVhbCBuYW1lIGFycml2ZXMuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHByb21pc2UgPSAkLndoZW4oc2lnbmFsKS5kb25lKGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICQuYWpheCh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiBtZWRpYUl0ZW1VcmwgKyBcIj9wYXRoPVwiICsgZW5jb2RlVVJJQ29tcG9uZW50KHgucGF0aCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnR0VUJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzdWNjZXNzOiBmdW5jdGlvbiAoZGF0YSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhLnZ1ZWtleSA9IGRhdGEubmFtZSArIGkudG9TdHJpbmcoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YS5tZWRpYVRleHQgPSB4Lm1lZGlhVGV4dDsgLy8gVGhpcyB2YWx1ZSBpcyBub3QgcmV0dXJuZWQgZnJvbSB0aGUgYWpheCBjYWxsLlxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhLmFuY2hvciA9IHguYW5jaG9yOyAvLyBUaGlzIHZhbHVlIGlzIG5vdCByZXR1cm5lZCBmcm9tIHRoZSBhamF4IGNhbGwuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGl0ZW1zLnNwbGljZShpLCAxLCBkYXRhKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGl0ZW1zLmxlbmd0aCA9PT0gKytsZW5ndGgpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGl0ZW1zLmZvckVhY2goZnVuY3Rpb24gKHkpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLm1lZGlhSXRlbXMucHVzaCh5KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VsZi5pbml0aWFsaXplZCA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGVycm9yOiBmdW5jdGlvbiAoZXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2coZXJyb3IpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtcy5zcGxpY2UoaSwgMSwgeyBuYW1lOiB4LnBhdGgsIG1pbWU6ICcnLCBtZWRpYVBhdGg6ICdub3QtZm91bmQnLCBtZWRpYVRleHQ6ICcnLCBhbmNob3I6IHsgeDogMCwgeTogMCB9IH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoaXRlbXMubGVuZ3RoID09PSArK2xlbmd0aCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaXRlbXMuZm9yRWFjaChmdW5jdGlvbiAoeCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYubWVkaWFJdGVtcy5wdXNoKHgpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZWxmLmluaXRpYWxpemVkID0gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgXHJcbiAgICAgICAgICAgICAgICAgICAgc2lnbmFsLnJlc29sdmUoKTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgZmlsZVNpemU6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgIHJldHVybiBNYXRoLnJvdW5kKHRoaXMuc2VsZWN0ZWRNZWRpYS5zaXplIC8gMTAyNCk7XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIGNhbkFkZE1lZGlhOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICByZXR1cm4gdGhpcy5tZWRpYUl0ZW1zLmxlbmd0aCA9PT0gMCB8fCB0aGlzLm1lZGlhSXRlbXMubGVuZ3RoID4gMCAmJiBhbGxvd011bHRpcGxlO1xyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICB0aHVtYlNpemU6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLnNtYWxsVGh1bWJzID8gMTIwIDogMjQwO1xyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBjdXJyZW50UHJlZnM6IHtcclxuICAgICAgICAgICAgICAgIGdldDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNtYWxsVGh1bWJzOiB0aGlzLnNtYWxsVGh1bWJzXHJcbiAgICAgICAgICAgICAgICAgICAgfTtcclxuICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBzZXQ6IGZ1bmN0aW9uIChuZXdQcmVmcykge1xyXG4gICAgICAgICAgICAgICAgICAgIGlmICghbmV3UHJlZnMpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgICAgICB0aGlzLnNtYWxsVGh1bWJzID0gbmV3UHJlZnMuc21hbGxUaHVtYnM7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9LFxyXG4gICAgICAgIG1vdW50ZWQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG5cclxuICAgICAgICAgICAgc2VsZi5wYXRocyA9IGluaXRpYWxQYXRocztcclxuXHJcbiAgICAgICAgICAgIHNlbGYuJG9uKCdzZWxlY3RBbmREZWxldGVNZWRpYVJlcXVlc3RlZCcsIGZ1bmN0aW9uIChtZWRpYSkge1xyXG4gICAgICAgICAgICAgICAgc2VsZi5zZWxlY3RBbmREZWxldGVNZWRpYShtZWRpYSk7XHJcbiAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgc2VsZi4kb24oJ3NlbGVjdE1lZGlhUmVxdWVzdGVkJywgZnVuY3Rpb24gKG1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICBzZWxmLnNlbGVjdE1lZGlhKG1lZGlhKTtcclxuICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICBzZWxmLiRvbignZmlsZXNVcGxvYWRlZCcsIGZ1bmN0aW9uIChmaWxlcykge1xyXG4gICAgICAgICAgICAgICAgc2VsZi5hZGRNZWRpYUZpbGVzKGZpbGVzKTtcclxuICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgfSxcclxuICAgICAgICBtZXRob2RzOiB7XHJcbiAgICAgICAgICAgIHNlbGVjdE1lZGlhOiBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYSA9IG1lZGlhO1xyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICBzaG93TW9kYWw6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdmFyIHNlbGYgPSB0aGlzO1xyXG4gICAgICAgICAgICAgICAgaWYgKHNlbGYuY2FuQWRkTWVkaWEpIHtcclxuICAgICAgICAgICAgICAgICAgICAkKFwiI21lZGlhQXBwXCIpLmFwcGVuZFRvKCQobW9kYWxCb2R5RWxlbWVudCkuZmluZCgnLm1vZGFsLWJvZHknKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgJChcIiNtZWRpYUFwcFwiKS5zaG93KCk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIHZhciBtb2RhbCA9IG5ldyBib290c3RyYXAuTW9kYWwobW9kYWxCb2R5RWxlbWVudCk7XHJcbiAgICAgICAgICAgICAgICAgICAgbW9kYWwuc2hvdygpO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAkKG1vZGFsQm9keUVsZW1lbnQpLmZpbmQoJy5tZWRpYUZpZWxkU2VsZWN0QnV0dG9uJykub2ZmKCdjbGljaycpLm9uKCdjbGljaycsIGZ1bmN0aW9uICh2KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlbGYuYWRkTWVkaWFGaWxlcyhtZWRpYUFwcC5zZWxlY3RlZE1lZGlhcyk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICAvLyB3ZSBkb24ndCB3YW50IHRoZSBpbmNsdWRlZCBtZWRpYXMgdG8gYmUgc3RpbGwgc2VsZWN0ZWQgdGhlIG5leHQgdGltZSB3ZSBvcGVuIHRoZSBtb2RhbC5cclxuICAgICAgICAgICAgICAgICAgICAgICAgbWVkaWFBcHAuc2VsZWN0ZWRNZWRpYXMgPSBbXTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG1vZGFsLmhpZGUoKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHRydWU7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICA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5jaG9yLngsXHJcbiAgICAgICAgICAgICAgICAgIHk6IHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IueVxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgdGhpcy5iYWNrdXBBbmNob3IgPSB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yO1xyXG4gICAgICAgICAgICB9LCAgICAgICAgICAgIFxyXG4gICAgICAgICAgICBjYW5jZWxBbmNob3JpbmdNb2RhbDogZnVuY3Rpb24gKGV2ZW50KSB7XHJcbiAgICAgICAgICAgICAgICB0aGlzLmFuY2hvcmluZ01vZGFsLmhpZGUoKTtcclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IgPSB0aGlzLmJhY2t1cEFuY2hvcjtcclxuICAgICAgICAgICAgfSwgICAgICAgICAgICBcclxuICAgICAgICAgICAgcmVzZXRBbmNob3I6IGZ1bmN0aW9uIChldmVudCkge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvciA9IHsgeDogMC41LCB5OiAwLjUgfTtcclxuICAgICAgICAgICAgfSwgIFxyXG4gICAgICAgICAgICBvbkFuY2hvckRyb3A6IGZ1bmN0aW9uKGV2ZW50KSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgaW1hZ2UgPSB0aGlzLiRyZWZzLmFuY2hvckltYWdlO1xyXG4gICAgICAgICAgICAgICAgdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvciA9IHtcclxuICAgICAgICAgICAgICAgICAgIHg6IGV2ZW50Lm9mZnNldFggLyBpbWFnZS5jbGllbnRXaWR0aCxcclxuICAgICAgICAgICAgICAgICAgIHk6IGV2ZW50Lm9mZnNldFkgLyBpbWFnZS5jbGllbnRIZWlnaHRcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgYW5jaG9yTGVmdDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgaWYgKHRoaXMuJHJlZnMuYW5jaG9ySW1hZ2UgJiYgdGhpcy4kcmVmcy5tb2RhbEJvZHkgJiYgdGhpcy5zZWxlY3RlZE1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgLy8gV2hlbiBpbWFnZSBpcyBzaHJ1bmsgY29tcGFyZSBhZ2FpbnN0IHRoZSBtb2RhbCBib2R5LlxyXG4gICAgICAgICAgICAgICAgICAgIHZhciBvZmZzZXQgPSAodGhpcy4kcmVmcy5tb2RhbEJvZHkuY2xpZW50V2lkdGggLSB0aGlzLiRyZWZzLmFuY2hvckltYWdlLmNsaWVudFdpZHRoKSAvIDI7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIHBvc2l0aW9uID0gKHRoaXMuc2VsZWN0ZWRNZWRpYS5hbmNob3IueCAqIHRoaXMuJHJlZnMuYW5jaG9ySW1hZ2UuY2xpZW50V2lkdGgpICsgb2Zmc2V0O1xyXG4gICAgICAgICAgICAgICAgICAgIHZhciBhbmNob3JJY29uID0gTWF0aC5yb3VuZCh0aGlzLiRyZWZzLm1vZGFsQm9keS5xdWVyeVNlbGVjdG9yKCcuaWNvbi1tZWRpYS1hbmNob3InKS5jbGllbnRXaWR0aCk7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYoTnVtYmVyLmlzSW50ZWdlcihhbmNob3JJY29uKSlcclxuICAgICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHBvc2l0aW9uID0gcG9zaXRpb24gLSBhbmNob3JJY29uLzI7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBwb3NpdGlvbiArICdweCc7XHJcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiAnMCc7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sICAgICAgICAgICAgXHJcbiAgICAgICAgICAgIGFuY2hvclRvcDogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICAgICAgaWYgKHRoaXMuJHJlZnMuYW5jaG9ySW1hZ2UgJiYgdGhpcy5zZWxlY3RlZE1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIHBvc2l0aW9uID0gdGhpcy5zZWxlY3RlZE1lZGlhLmFuY2hvci55ICogdGhpcy4kcmVmcy5hbmNob3JJbWFnZS5jbGllbnRIZWlnaHQ7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHBvc2l0aW9uICsgJ3B4JztcclxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuICcwJztcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgc2V0QW5jaG9yOiBmdW5jdGlvbiAoZXZlbnQpIHtcclxuICAgICAgICAgICAgICAgIHZhciBpbWFnZSA9IHRoaXMuJHJlZnMuYW5jaG9ySW1hZ2U7XHJcbiAgICAgICAgICAgICAgICB0aGlzLnNlbGVjdGVkTWVkaWEuYW5jaG9yID0ge1xyXG4gICAgICAgICAgICAgICAgICAgIHg6IGV2ZW50Lm9mZnNldFggLyBpbWFnZS5jbGllbnRXaWR0aCxcclxuICAgICAgICAgICAgICAgICAgICB5OiBldmVudC5vZmZzZXRZIC8gaW1hZ2UuY2xpZW50SGVpZ2h0XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0sICAgICAgICAgXHJcbiAgICAgICAgICAgIGFkZE1lZGlhRmlsZXM6IGZ1bmN0aW9uIChmaWxlcykge1xyXG4gICAgICAgICAgICAgICAgaWYgKChmaWxlcy5sZW5ndGggPiAxKSAmJiAoYWxsb3dNdWx0aXBsZSA9PT0gZmFsc2UpKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgYWxlcnQoJCgnI29ubHlPbmVJdGVtTWVzc2FnZScpLnZhbCgpKTtcclxuICAgICAgICAgICAgICAgICAgICBtZWRpYUZpZWxkQXBwLm1lZGlhSXRlbXMucHVzaChmaWxlc1swXSk7XHJcbiAgICAgICAgICAgICAgICAgICAgbWVkaWFGaWVsZEFwcC5pbml0aWFsaXplZCA9IHRydWU7XHJcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xyXG4gICAgICAgICAgICAgICAgICAgIG1lZGlhRmllbGRBcHAubWVkaWFJdGVtcyA9IG1lZGlhRmllbGRBcHAubWVkaWFJdGVtcy5jb25jYXQoZmlsZXMpO1xyXG4gICAgICAgICAgICAgICAgICAgIG1lZGlhRmllbGRBcHAuaW5pdGlhbGl6ZWQgPSB0cnVlO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICByZW1vdmVTZWxlY3RlZDogZnVuY3Rpb24gKGV2ZW50KSB7XHJcbiAgICAgICAgICAgICAgICBpZiAodGhpcy5zZWxlY3RlZE1lZGlhKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdmFyIGluZGV4ID0gdGhpcy5tZWRpYUl0ZW1zICYmIHRoaXMubWVkaWFJdGVtcy5pbmRleE9mKHRoaXMuc2VsZWN0ZWRNZWRpYSk7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKGluZGV4ID4gLTEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5tZWRpYUl0ZW1zLnNwbGljZShpbmRleCwgMSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgZWxzZSB7XHJcbiAgICAgICAgICAgICAgICAgICAgLy8gVGhlIHJlbW92ZSBidXR0b24gY2FuIGFsc28gcmVtb3ZlIGEgdW5pcXVlIG1lZGlhIGl0ZW1cclxuICAgICAgICAgICAgICAgICAgICBpZiAodGhpcy5tZWRpYUl0ZW1zLmxlbmd0aCA9PT0gMSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLm1lZGlhSXRlbXMuc3BsaWNlKDAsIDEpO1xyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIHRoaXMuc2VsZWN0ZWRNZWRpYSA9IG51bGw7XHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIHNlbGVjdEFuZERlbGV0ZU1lZGlhOiBmdW5jdGlvbiAobWVkaWEpIHtcclxuICAgICAgICAgICAgICAgIHZhciBzZWxmID0gdGhpcztcclxuICAgICAgICAgICAgICAgIHNlbGYuc2VsZWN0ZWRNZWRpYSA9IG1lZGlhO1xyXG4gICAgICAgICAgICAgICAgLy8gc2V0VGltZW91dCBiZWNhdXNlIHNvbWV0aW1lcyByZW1vdmVTZWxlY3RlZCB3YXMgY2FsbGVkIGV2ZW4gYmVmb3JlIHRoZSBtZWRpYSB3YXMgc2V0LlxyXG4gICAgICAgICAgICAgICAgc2V0VGltZW91dChmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZi5yZW1vdmVTZWxlY3RlZCgpO1xyXG4gICAgICAgICAgICAgICAgfSwgMTAwKTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH0sXHJcbiAgICAgICAgd2F0Y2g6IHtcclxuICAgICAgICAgICAgbWVkaWFJdGVtczoge1xyXG4gICAgICAgICAgICAgICAgZGVlcDogdHJ1ZSxcclxuICAgICAgICAgICAgICAgIGhhbmRsZXIgKCkge1xyXG4gICAgICAgICAgICAgICAgICAgIC8vIFRyaWdnZXIgcHJldmlldyByZW5kZXJpbmdcclxuICAgICAgICAgICAgICAgICAgICBzZXRUaW1lb3V0KGZ1bmN0aW9uICgpIHsgJChkb2N1bWVudCkudHJpZ2dlcignY29udGVudHByZXZpZXc6cmVuZGVyJyk7IH0sIDEwMCk7IFxyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9LCAgICA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hc3M9XCJmYS1zb2xpZCBmYS1kb3dubG9hZFwiIGFyaWEtaGlkZGVuPVwidHJ1ZVwiPjwvaT48L2E+IFxcXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPHNwYW4gY2xhc3M9XCJtZWRpYS1maWxlbmFtZSBjYXJkLXRleHQgc21hbGxcIiA6dGl0bGU9XCJtZWRpYS5tZWRpYVBhdGhcIj57eyBtZWRpYS5pc05ldyA/IG1lZGlhLm5hbWUuc3Vic3RyKDM2KSA6IG1lZGlhLm5hbWUgfX08L3NwYW4+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgIDwvZGl2PlxcXHJcbiAgICAgICAgICAgICAgICAgICAgPC9kaXY+XFxcclxuICAgICAgICAgICAgICAgICAgICA8ZGl2IHYtZWxzZT5cXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwidGh1bWItY29udGFpbmVyIGZsZXgtY29sdW1uXCIgOnN0eWxlPVwie2hlaWdodDogdGh1bWJTaXplICsgXFwncHhcXCd9XCI+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxpIGNsYXNzPVwiZmEtc29saWQgZmEtYmFuIHRleHQtZGFuZ2VyIGQtYmxvY2tcIiBhcmlhLWhpZGRlbj1cInRydWVcIj48L2k+XFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxzcGFuIGNsYXNzPVwidGV4dC1kYW5nZXIgc21hbGwgZC1ibG9ja1wiPnt7IFQubWVkaWFOb3RGb3VuZCB9fTwvc3Bhbj5cXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPHNwYW4gY2xhc3M9XCJ0ZXh0LWRhbmdlciBzbWFsbCBkLWJsb2NrIHRleHQtY2VudGVyXCI+e3sgVC5kaXNjYXJkV2FybmluZyB9fTwvc3Bhbj5cXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwibWVkaWEtY29udGFpbmVyLW1haW4taXRlbS10aXRsZSBjYXJkLWJvZHlcIj5cXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPGEgaHJlZj1cImphdmFzY3JpcHQ6O1wiIGNsYXNzPVwiYnRuIGJ0bi1saWdodCBidG4tc20gZmxvYXQtZW5kIGlubGluZS1tZWRpYS1idXR0b24gZGVsZXRlLWJ1dHRvblwiXFxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2LW9uOmNsaWNrLnN0b3A9XCJzZWxlY3RBbmREZWxldGVNZWRpYShtZWRpYSlcIj48aSBjbGFzcz1cImZhLXNvbGlkIGZhLXRyYXNoXCIgYXJpYS1oaWRkZW49XCJ0cnVlXCI+PC9pPjwvYT5cXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgPHNwYW4gY2xhc3M9XCJtZWRpYS1maWxlbmFtZSBjYXJkLXRleHQgc21hbGwgdGV4dC1kYW5nZXJcIiA6dGl0bGU9XCJtZWRpYS5uYW1lXCI+e3sgbWVkaWEubmFtZSB9fTwvc3Bhbj5cXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cXFxyXG4gICAgICAgICAgICAgICAgICAgPC9kaXY+XFxcclxuICAgICAgICAgICAgPC9saT5cXFxyXG4gICAgICAgICA8L2RyYWdnYWJsZT5cXFxyXG4gICAgICAgPC9kaXY+XFxcclxuICAgICcsXHJcbiAgICBkYXRhOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgcmV0dXJuIHtcclxuICAgICAgICAgICAgVDoge31cclxuICAgICAgICB9O1xyXG4gICAgfSxcclxuICAgIHByb3BzOiB7XHJcbiAgICAgICAgbWVkaWFJdGVtczogQXJyYXksXHJcbiAgICAgICAgc2VsZWN0ZWRNZWRpYTogT2JqZWN0LFxyXG4gICAgICAgIHRodW1iU2l6ZTogTnVtYmVyLFxyXG4gICAgICAgIGlkUHJlZml4OiBTdHJpbm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WwubmFtZSkge1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIGlmIChkYXRhLnJlc3VsdC5maWxlc1swXS5lcnJvcikge1xyXG4gICAgICAgICAgICAgICAgc2VsZi5oYW5kbGVGYWlsdXJlKGRhdGEuZmlsZXNbMF0ubmFtZSwgZGF0YS5yZXN1bHQuZmlsZXNbMF0uZXJyb3IpO1xyXG4gICAgICAgICAgICB9IGVsc2UgeyAgXHJcbiAgICAgICAgICAgICAgICBidXMuJGVtaXQoJ3JlbW92YWxSZXF1ZXN0Jywgc2VsZi5tb2RlbCk7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgJCh1cGxvYWRJbnB1dCkuYmluZCgnZmlsZXVwbG9hZGZhaWwnLCBmdW5jdGlvbiAoZSwgZGF0YSkge1xyXG4gICAgICAgICAgICBpZiAoZGF0YS5maWxlc1swXS5uYW1lICE9PSBzZWxmLm1vZGVsLm5hbWUpIHtcclxuICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBzZWxmLmhhbmRsZUZhaWx1cmUoZGF0YS5maWxlc1swXS5uYW1lLCAkKCcjdC1lcnJvcicpLnZhbCgpKTtcclxuICAgICAgICB9KTtcclxuICAgIH0sXHJcbiAgICBtZXRob2RzOiB7XHJcbiAgICAgICAgaGFuZGxlRmFpbHVyZTogZnVuY3Rpb24gKGZpbGVOYW1lLCBtZXNzYWdlKSB7XHJcbiAgICAgICAgICAgIGlmIChmaWxlTmFtZSAhPT0gdGhpcy5tb2RlbC5uYW1lKSB7XHJcbiAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgdGhpcy5tb2RlbC5lcnJvck1lc3NhZ2UgPSBtZXNzYWdlO1xyXG4gICAgICAgICAgICBidXMuJGVtaXQoJ0Vycm9yT25VcGxvYWQn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ICAgICAgICAgPGRpdiB2LXNob3c9XCJleHBhbmRlZFwiPiBcXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICA8aSBjbGFzcz1cImZhLXNvbGlkIGZhLWNoZXZyb24tZG93blwiIGFyaWEtaGlkZGVuPVwidHJ1ZVwiPjwvaT4gXFxcclxuICAgICAgICAgICAgICAgICAgICA8L2Rpdj4gXFxcclxuICAgICAgICAgICAgICAgICAgICA8ZGl2IHYtc2hvdz1cIiFleHBhbmRlZFwiPiBcXFxyXG4gICAgICAgICAgICAgICAgICAgICAgICA8aSBjbGFzcz1cImZhLXNvbGlkIGZhLWNoZXZyb24tdXBcIiBhcmlhLWhpZGRlbj1cInRydWVcIj48L2k+IFxcXHJcbiAgICAgICAgICAgICAgICAgICAgPC9kaXY+IFxcXHJcbiAgICAgICAgICAgICAgICA8L2Rpdj4gXFxcclxuICAgICAgICAgICAgPC9kaXY+IFxcXHJcbiAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJjYXJkLWJvZHlcIiB2LXNob3c9XCJleHBhbmRlZFwiPiBcXFxyXG4gICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cImQtZmxleCBmbGV4LXdyYXBcIj4gXFxcclxuICAgICAgICAgICAgICAgICAgICA8dXBsb2FkIDp1cGxvYWQtaW5wdXQtaWQ9XCJ1cGxvYWRJbnB1dElkXCIgdi1mb3I9XCJmIGluIGZpbGVzXCIgOmtleT1cImYubmFtZVwiICA6bW9kZWw9XCJmXCI+PC91cGxvYWQ+IFxcXHJcbiAgICAgICAgICAgICAgICA8L2RpdiA+IFxcXHJcbiAgICAgICAgICAgIDwvZGl2PiBcXFxyXG4gICAgICAgIDwvZGl2PiBcXFxyXG4gICAgICAgICcsXHJcbiAgICBkYXRhOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgcmV0dXJuIHtcclxuICAgICAgICAgICAgZmlsZXM6IFtdLFxyXG4gICAgICAgICAgICBUOiB7fSxcclxuICAgICAgICAgICAgZXhwYW5kZ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AgICAgIH1cclxuICAgICAgICAgICAgZGF0YS5maWxlcy5mb3JFYWNoKGZ1bmN0aW9uIChuZXdGaWxlKSB7XHJcbiAgICAgICAgICAgICAgICB2YXIgYWxyZWFkeUluTGlzdCA9IHNlbGYuZmlsZXMuc29tZShmdW5jdGlvbiAoZikge1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBmLm5hbWUgPT0gbmV3RmlsZS5uYW1lO1xyXG4gICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgaWYgKCFhbHJlYWR5SW5MaXN0KSB7XHJcbiAgICAgICAgICAgICAgICAgICAgc2VsZi5maWxlcy5wdXNoKHsgbmFtZTogbmV3RmlsZS5uYW1lLCBwZXJjZW50YWdlOiAwLCBlcnJvck1lc3NhZ2U6ICcnIH0pO1xyXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmVycm9yKCdBIGZpbGUgd2l0aCB0aGUgc2FtZSBuYW1lIGlzIGFscmVhZHkgb24gdGhlIHF1ZXVlOicgKyBuZXdGaWxlLm5hbWUpO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9KTtcclxuICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgYnVzLiRvbigncmVtb3ZhbFJlcXVlc3QnLCBmdW5jdGlvbiAoZmlsZVVwbG9hZCkge1xyXG4gICAgICAgICAgICBzZWxmLmZpbGVzLmZvckVhY2goZnVuY3Rpb24gKGl0ZW0sIGluZGV4LCBhcnJheSkge1xyXG4gICAgICAgICAgICAgICAgaWYgKGl0ZW0ubmFtZSA9PSBmaWxlVXBsb2FkLm5hbWUpIHtcclxuICAgICAgICAgICAgICAgICAgICBhcnJheS5zcGxpY2UoaW5kZXgsIDEpO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9KTtcclxuICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgYnVzLiRvbignRXJyb3JPblVwbG9hZCcsIGZ1bmN0aW9uIChmaWxlVXBsb2FkKSB7XHJcbiAgICAgICAgICAgIHNlbGYudXBkYXRlQ291bnQoKTtcclxuICAgICAgICB9KTtcclxuICAgIH0sXHJcbiAgICBtZXRob2RzOiB7XHJcbiAgICAgICAgdXBkYXRlQ291bnQ6IGZ1bmN0aW9uICgpIHtcclxuICAgICAgICAgICAgdGhpcy5lcnJvckNvdW50ID0gdGhpcy5maWxlcy5maWx0ZXIoZnVuY3Rpb24gKGl0ZW0pIHtcclxuICAgICAgICAgICAgICAgIHJldHVybiBpdGVtLmVycm9yTWVzc2FnZSAhPSAnJztcclxuICAgICAgICAgICAgfSkubGVuZ3RoO1xyXG4gICAgICAgICAgICB0aGlzLnBlbmRpbmdDb3VudCA9IHRoaXMuZmlsZXMubGVuZ3RoIC0gdGhpcy5lcnJvckNvdW50O1xyXG4gICAgICAgICAgICBpZiAodGhpcy5maWxlcy5sZW5ndGggPCAxKSB7XHJcbiAgICAgICAgICAgICAgICB0aGlzLmV4cGFuZGVkID0gZmFsc2U7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9LFxyXG4gICAgICAgIGNsZWFyRXJyb3JzOiBmdW5jdGlvbiAoKSB7XHJcbiAgICAgICAgICAgIHRoaXMuZmlsZXMgPSB0aGlzLmZpbGVzLmZpbHRlcihmdW5jdGlvbiAoaXRlbSkge1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuIGl0ZW0uZXJyb3JNZXNzYWdlID09ICcnO1xyXG4gICAgICAgICAgICB9KTtcclxuICAgICAgICB9XHJcbiAgICB9LFxyXG4gICAgd2F0Y2g6IHtcclxuICAgICAgICBmaWxlczogZnVuY3Rpb24gKCkge1xyXG4gICAgICAgICAgICB0aGlzLnVwZGF0ZUNvdW50KCk7XHJcbiAgICAgICAgfVxyXG4gICAgfVxyXG59KTtcclxuIl19 diff --git a/src/OrchardCore.Modules/OrchardCore.Media/wwwroot/Scripts/media.min.js b/src/OrchardCore.Modules/OrchardCore.Media/wwwroot/Scripts/media.min.js index b0089a7915a..76b90bf686f 100644 --- a/src/OrchardCore.Modules/OrchardCore.Media/wwwroot/Scripts/media.min.js +++ b/src/OrchardCore.Modules/OrchardCore.Media/wwwroot/Scripts/media.min.js @@ -1 +1 @@ -function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function randomUUID(){return"object"===("undefined"==typeof crypto?"undefined":_typeof(crypto))&&"function"==typeof crypto.randomUUID?crypto.randomUUID():([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,(function(e){return(e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>e/4).toString(16)}))}function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function ownKeys(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function _objectSpread(e){for(var t=1;t').prop("disabled")),e.support.xhrFileUpload=!(!window.ProgressEvent||!window.FileReader),e.support.xhrFormDataFileUpload=!!window.FormData,e.support.blobSlice=window.Blob&&(Blob.prototype.slice||Blob.prototype.webkitSlice||Blob.prototype.mozSlice),e.widget("blueimp.fileupload",{options:{dropZone:e(document),pasteZone:void 0,fileInput:void 0,replaceFileInput:!0,paramName:void 0,singleFileUploads:!0,limitMultiFileUploads:void 0,limitMultiFileUploadSize:void 0,limitMultiFileUploadSizeOverhead:512,sequentialUploads:!1,limitConcurrentUploads:void 0,forceIframeTransport:!1,redirect:void 0,redirectParamName:void 0,postMessage:void 0,multipart:!0,maxChunkSize:void 0,uploadedBytes:void 0,recalculateProgress:!0,progressInterval:100,bitrateInterval:500,autoUpload:!0,uniqueFilenames:void 0,messages:{uploadedBytes:"Uploaded bytes exceed file size"},i18n:function(t,i){return t=this.messages[t]||t.toString(),i&&e.each(i,(function(e,i){t=t.replace("{"+e+"}",i)})),t},formData:function(e){return e.serializeArray()},add:function(t,i){if(t.isDefaultPrevented())return!1;(i.autoUpload||!1!==i.autoUpload&&e(this).fileupload("option","autoUpload"))&&i.process().done((function(){i.submit()}))},processData:!1,contentType:!1,cache:!1,timeout:0},_promisePipe:(i=e.fn.jquery.split("."),Number(i[0])>1||Number(i[1])>7?"then":"pipe"),_specialOptions:["fileInput","dropZone","pasteZone","multipart","forceIframeTransport"],_blobSlice:e.support.blobSlice&&function(){return(this.slice||this.webkitSlice||this.mozSlice).apply(this,arguments)},_BitrateTimer:function(){this.timestamp=Date.now?Date.now():(new Date).getTime(),this.loaded=0,this.bitrate=0,this.getBitrate=function(e,t,i){var n=e-this.timestamp;return(!this.bitrate||!i||n>i)&&(this.bitrate=(t-this.loaded)*(1e3/n)*8,this.loaded=t,this.timestamp=e),this.bitrate}},_isXHRUpload:function(t){return!t.forceIframeTransport&&(!t.multipart&&e.support.xhrFileUpload||e.support.xhrFormDataFileUpload)},_getFormData:function(t){var i;return"function"===e.type(t.formData)?t.formData(t.form):e.isArray(t.formData)?t.formData:"object"===e.type(t.formData)?(i=[],e.each(t.formData,(function(e,t){i.push({name:e,value:t})})),i):[]},_getTotal:function(t){var i=0;return e.each(t,(function(e,t){i+=t.size||1})),i},_initProgressObject:function(t){var i={loaded:0,total:0,bitrate:0};t._progress?e.extend(t._progress,i):t._progress=i},_initResponseObject:function(e){var t;if(e._response)for(t in e._response)Object.prototype.hasOwnProperty.call(e._response,t)&&delete e._response[t];else e._response={}},_onProgress:function(t,i){if(t.lengthComputable){var n,a=Date.now?Date.now():(new Date).getTime();if(i._time&&i.progressInterval&&a-i._time").prop("href",t.url).prop("host");t.dataType="iframe "+(t.dataType||""),t.formData=this._getFormData(t),t.redirect&&i&&i!==location.host&&t.formData.push({name:t.redirectParamName||"redirect",value:t.redirect})},_initDataSettings:function(e){this._isXHRUpload(e)?(this._chunkedUpload(e,!0)||(e.data||this._initXHRData(e),this._initProgressListener(e)),e.postMessage&&(e.dataType="postmessage "+(e.dataType||""))):this._initIframeSettings(e)},_getParamName:function(t){var i=e(t.fileInput),n=t.paramName;return n?e.isArray(n)||(n=[n]):(n=[],i.each((function(){for(var t=e(this),i=t.prop("name")||"files[]",a=(t.prop("files")||[1]).length;a;)n.push(i),a-=1})),n.length||(n=[i.prop("name")||"files[]"])),n},_initFormSettings:function(t){t.form&&t.form.length||(t.form=e(t.fileInput.prop("form")),t.form.length||(t.form=e(this.options.fileInput.prop("form")))),t.paramName=this._getParamName(t),t.url||(t.url=t.form.prop("action")||location.href),t.type=(t.type||"string"===e.type(t.form.prop("method"))&&t.form.prop("method")||"").toUpperCase(),"POST"!==t.type&&"PUT"!==t.type&&"PATCH"!==t.type&&(t.type="POST"),t.formAcceptCharset||(t.formAcceptCharset=t.form.attr("accept-charset"))},_getAJAXSettings:function(t){var i=e.extend({},this.options,t);return this._initFormSettings(i),this._initDataSettings(i),i},_getDeferredState:function(e){return e.state?e.state():e.isResolved()?"resolved":e.isRejected()?"rejected":"pending"},_enhancePromise:function(e){return e.success=e.done,e.error=e.fail,e.complete=e.always,e},_getXHRPromise:function(t,i,n){var a=e.Deferred(),o=a.promise();return i=i||this.options.context||o,!0===t?a.resolveWith(i,n):!1===t&&a.rejectWith(i,n),o.abort=a.promise,this._enhancePromise(o)},_addConvenienceMethods:function(t,i){var n=this,a=function(t){return e.Deferred().resolveWith(n,t).promise()};i.process=function(t,o){return(t||o)&&(i._processQueue=this._processQueue=(this._processQueue||a([this]))[n._promisePipe]((function(){return i.errorThrown?e.Deferred().rejectWith(n,[i]).promise():a(arguments)}))[n._promisePipe](t,o)),this._processQueue||a([this])},i.submit=function(){return"pending"!==this.state()&&(i.jqXHR=this.jqXHR=!1!==n._trigger("submit",e.Event("submit",{delegatedEvent:t}),this)&&n._onSend(t,this)),this.jqXHR||n._getXHRPromise()},i.abort=function(){return this.jqXHR?this.jqXHR.abort():(this.errorThrown="abort",n._trigger("fail",null,this),n._getXHRPromise(!1))},i.state=function(){return this.jqXHR?n._getDeferredState(this.jqXHR):this._processQueue?n._getDeferredState(this._processQueue):void 0},i.processing=function(){return!this.jqXHR&&this._processQueue&&"pending"===n._getDeferredState(this._processQueue)},i.progress=function(){return this._progress},i.response=function(){return this._response}},_getUploadedBytes:function(e){var t=e.getResponseHeader("Range"),i=t&&t.split("-"),n=i&&i.length>1&&parseInt(i[1],10);return n&&n+1},_chunkedUpload:function(t,i){t.uploadedBytes=t.uploadedBytes||0;var n,a,o=this,r=t.files[0],s=r.size,l=t.uploadedBytes,d=t.maxChunkSize||s,c=this._blobSlice,u=e.Deferred(),m=u.promise();return!(!(this._isXHRUpload(t)&&c&&(l||("function"===e.type(d)?d(t):d)=s?(r.error=t.i18n("uploadedBytes"),this._getXHRPromise(!1,t.context,[null,"error",r.error])):(a=function(){var i=e.extend({},t),m=i._progress.loaded;i.blob=c.call(r,l,l+("function"===e.type(d)?d(i):d),r.type),i.chunkSize=i.blob.size,i.contentRange="bytes "+l+"-"+(l+i.chunkSize-1)+"/"+s,o._trigger("chunkbeforesend",null,i),o._initXHRData(i),o._initProgressListener(i),n=(!1!==o._trigger("chunksend",null,i)&&e.ajax(i)||o._getXHRPromise(!1,i.context)).done((function(n,r,d){l=o._getUploadedBytes(d)||l+i.chunkSize,m+i.chunkSize-i._progress.loaded&&o._onProgress(e.Event("progress",{lengthComputable:!0,loaded:l-i.uploadedBytes,total:l-i.uploadedBytes}),i),t.uploadedBytes=i.uploadedBytes=l,i.result=n,i.textStatus=r,i.jqXHR=d,o._trigger("chunkdone",null,i),o._trigger("chunkalways",null,i),ls._sending)for(var n=s._slots.shift();n;){if("pending"===s._getDeferredState(n)){n.resolve();break}n=s._slots.shift()}0===s._active&&s._trigger("stop")}))};return this._beforeSend(t,l),this.options.sequentialUploads||this.options.limitConcurrentUploads&&this.options.limitConcurrentUploads<=this._sending?(this.options.limitConcurrentUploads>1?(o=e.Deferred(),this._slots.push(o),r=o[s._promisePipe](d)):(this._sequence=this._sequence[s._promisePipe](d,d),r=this._sequence),r.abort=function(){return a=[void 0,"abort","abort"],n?n.abort():(o&&o.rejectWith(l.context,a),d())},this._enhancePromise(r)):d()},_onAdd:function(t,i){var n,a,o,r,s=this,l=!0,d=e.extend({},this.options,i),c=i.files,u=c.length,m=d.limitMultiFileUploads,p=d.limitMultiFileUploadSize,f=d.limitMultiFileUploadSizeOverhead,h=0,g=this._getParamName(d),v=0;if(!u)return!1;if(p&&void 0===c[0].size&&(p=void 0),(d.singleFileUploads||m||p)&&this._isXHRUpload(d))if(d.singleFileUploads||p||!m)if(!d.singleFileUploads&&p)for(o=[],n=[],r=0;rp||m&&r+1-v>=m)&&(o.push(c.slice(v,r+1)),(a=g.slice(v,r+1)).length||(a=g),n.push(a),v=r+1,h=0);else n=g;else for(o=[],n=[],r=0;r").append(n)[0].reset(),i.after(n).detach(),a&&n.trigger("focus"),e.cleanData(i.off("remove")),this.options.fileInput=this.options.fileInput.map((function(e,t){return t===i[0]?n[0]:t})),i[0]===this.element[0]&&(this.element=n)},_handleFileTreeEntry:function(t,i){var n,a=this,o=e.Deferred(),r=[],s=function(e){e&&!e.entry&&(e.entry=t),o.resolve([e])};return i=i||"",t.isFile?t._file?(t._file.relativePath=i,o.resolve(t._file)):t.file((function(e){e.relativePath=i,o.resolve(e)}),s):t.isDirectory?(n=t.createReader(),function e(){n.readEntries((function(n){n.length?(r=r.concat(n),e()):function(e){a._handleFileTreeEntries(e,i+t.name+"/").done((function(e){o.resolve(e)})).fail(s)}(r)}),s)}()):o.resolve([]),o.promise()},_handleFileTreeEntries:function(t,i){var n=this;return e.when.apply(e,e.map(t,(function(e){return n._handleFileTreeEntry(e,i)})))[this._promisePipe]((function(){return Array.prototype.concat.apply([],arguments)}))},_getDroppedFiles:function(t){var i=(t=t||{}).items;return i&&i.length&&(i[0].webkitGetAsEntry||i[0].getAsEntry)?this._handleFileTreeEntries(e.map(i,(function(e){var t;return e.webkitGetAsEntry?((t=e.webkitGetAsEntry())&&(t._file=e.getAsFile()),t):e.getAsEntry()}))):e.Deferred().resolve(e.makeArray(t.files)).promise()},_getSingleFileInputFiles:function(t){var i,n,a=(t=e(t)).prop("entries");if(a&&a.length)return this._handleFileTreeEntries(a);if((i=e.makeArray(t.prop("files"))).length)void 0===i[0].name&&i[0].fileName&&e.each(i,(function(e,t){t.name=t.fileName,t.size=t.fileSize}));else{if(!(n=t.prop("value")))return e.Deferred().resolve([]).promise();i=[{name:n.replace(/^.*\\/,"")}]}return e.Deferred().resolve(i).promise()},_getFileInputFiles:function(t){return t instanceof e&&1!==t.length?e.when.apply(e,e.map(t,this._getSingleFileInputFiles))[this._promisePipe]((function(){return Array.prototype.concat.apply([],arguments)})):this._getSingleFileInputFiles(t)},_onChange:function(t){var i=this,n={fileInput:e(t.target),form:e(t.target.form)};this._getFileInputFiles(n.fileInput).always((function(a){n.files=a,i.options.replaceFileInput&&i._replaceFileInput(n),!1!==i._trigger("change",e.Event("change",{delegatedEvent:t}),n)&&i._onAdd(t,n)}))},_onPaste:function(t){var i=t.originalEvent&&t.originalEvent.clipboardData&&t.originalEvent.clipboardData.items,n={files:[]};i&&i.length&&(e.each(i,(function(e,t){var i=t.getAsFile&&t.getAsFile();i&&n.files.push(i)})),!1!==this._trigger("paste",e.Event("paste",{delegatedEvent:t}),n)&&this._onAdd(t,n))},_onDrop:function(t){t.dataTransfer=t.originalEvent&&t.originalEvent.dataTransfer;var i=this,n=t.dataTransfer,a={};n&&n.files&&n.files.length&&(t.preventDefault(),this._getDroppedFiles(n).always((function(n){a.files=n,!1!==i._trigger("drop",e.Event("drop",{delegatedEvent:t}),a)&&i._onAdd(t,a)})))},_onDragOver:t("dragover"),_onDragEnter:t("dragenter"),_onDragLeave:t("dragleave"),_initEventHandlers:function(){this._isXHRUpload(this.options)&&(this._on(this.options.dropZone,{dragover:this._onDragOver,drop:this._onDrop,dragenter:this._onDragEnter,dragleave:this._onDragLeave}),this._on(this.options.pasteZone,{paste:this._onPaste})),e.support.fileInput&&this._on(this.options.fileInput,{change:this._onChange})},_destroyEventHandlers:function(){this._off(this.options.dropZone,"dragenter dragleave dragover drop"),this._off(this.options.pasteZone,"paste"),this._off(this.options.fileInput,"change")},_destroy:function(){this._destroyEventHandlers()},_setOption:function(t,i){var n=-1!==e.inArray(t,this._specialOptions);n&&this._destroyEventHandlers(),this._super(t,i),n&&(this._initSpecialOptions(),this._initEventHandlers())},_initSpecialOptions:function(){var t=this.options;void 0===t.fileInput?t.fileInput=this.element.is('input[type="file"]')?this.element:this.element.find('input[type="file"]'):t.fileInput instanceof e||(t.fileInput=e(t.fileInput)),t.dropZone instanceof e||(t.dropZone=e(t.dropZone)),t.pasteZone instanceof e||(t.pasteZone=e(t.pasteZone))},_getRegExp:function(e){var t=e.split("/"),i=t.pop();return t.shift(),new RegExp(t.join("/"),i)},_isRegExpOption:function(t,i){return"url"!==t&&"string"===e.type(i)&&/^\/.*\/[igm]{0,3}$/.test(i)},_initDataAttributes:function(){var t=this,i=this.options,n=this.element.data();e.each(this.element[0].attributes,(function(e,a){var o,r=a.name.toLowerCase();/^data-/.test(r)&&(r=r.slice(5).replace(/-[a-z]/g,(function(e){return e.charAt(1).toUpperCase()})),o=n[r],t._isRegExpOption(r,o)&&(o=t._getRegExp(o)),i[r]=o)}))},_create:function(){this._initDataAttributes(),this._initSpecialOptions(),this._slots=[],this._sequence=this._getXHRPromise(!0),this._sending=this._active=0,this._initProgressObject(this),this._initEventHandlers()},active:function(){return this._active},progress:function(){return this._progress},add:function(t){var i=this;t&&!this.options.disabled&&(t.fileInput&&!t.files?this._getFileInputFiles(t.fileInput).always((function(e){t.files=e,i._onAdd(null,t)})):(t.files=e.makeArray(t.files),this._onAdd(null,t)))},send:function(t){if(t&&!this.options.disabled){if(t.fileInput&&!t.files){var i,n,a=this,o=e.Deferred(),r=o.promise();return r.abort=function(){return n=!0,i?i.abort():(o.reject(null,"abort","abort"),r)},this._getFileInputFiles(t.fileInput).always((function(e){n||(e.length?(t.files=e,(i=a._onSend(null,t)).then((function(e,t,i){o.resolve(e,t,i)}),(function(e,t,i){o.reject(e,t,i)}))):o.reject())})),this._enhancePromise(r)}if(t.files=e.makeArray(t.files),t.files.length)return this._onSend(null,t)}return this._getXHRPromise(!1,t&&t.context)}})})),function(e){"use strict";"function"==typeof define&&define.amd?define(["jquery"],e):"object"===("undefined"==typeof exports?"undefined":_typeof(exports))?e(require("jquery")):e(window.jQuery)}((function(e){"use strict";var t=0,i=e,n="parseJSON";"JSON"in window&&"parse"in JSON&&(i=JSON,n="parse"),e.ajaxTransport("iframe",(function(i){if(i.async){var n,a,o,r=i.initialIframeSrc||"javascript:false;";return{send:function(s,l){(n=e('
')).attr("accept-charset",i.formAcceptCharset),o=/\?/.test(i.url)?"&":"?","DELETE"===i.type?(i.url=i.url+o+"_method=DELETE",i.type="POST"):"PUT"===i.type?(i.url=i.url+o+"_method=PUT",i.type="POST"):"PATCH"===i.type&&(i.url=i.url+o+"_method=PATCH",i.type="POST"),a=e('').on("load",(function(){var t,o=e.isArray(i.paramName)?i.paramName:[i.paramName];a.off("load").on("load",(function(){var t;try{if(!(t=a.contents()).length||!t[0].firstChild)throw new Error}catch(e){t=void 0}l(200,"success",{iframe:t}),e('').appendTo(n),window.setTimeout((function(){n.remove()}),0)})),n.prop("target",a.prop("name")).prop("action",i.url).prop("method",i.type),i.formData&&e.each(i.formData,(function(t,i){e('').prop("name",i.name).val(i.value).appendTo(n)})),i.fileInput&&i.fileInput.length&&"POST"===i.type&&(t=i.fileInput.clone(),i.fileInput.after((function(e){return t[e]})),i.paramName&&i.fileInput.each((function(t){e(this).prop("name",o[t]||i.paramName)})),n.append(i.fileInput).prop("enctype","multipart/form-data").prop("encoding","multipart/form-data"),i.fileInput.removeAttr("form")),window.setTimeout((function(){n.submit(),t&&t.length&&i.fileInput.each((function(i,n){var a=e(t[i]);e(n).prop("name",a.prop("name")).attr("form",a.attr("form")),a.replaceWith(n)}))}),0)})),n.append(a).appendTo(document.body)},abort:function(){a&&a.off("load").prop("src",r),n&&n.remove()}}}})),e.ajaxSetup({converters:{"iframe text":function(t){return t&&e(t[0].body).text()},"iframe json":function(t){return t&&i[n](e(t[0].body).text())},"iframe html":function(t){return t&&e(t[0].body).html()},"iframe xml":function(t){var i=t&&t[0];return i&&e.isXMLDoc(i)?i:e.parseXML(i.XMLDocument&&i.XMLDocument.xml||e(i.body).html())},"iframe script":function(t){return t&&e.globalEval(e(t[0].body).text())}}})}));var bus=new Vue;function initializeMediaApplication(e,t,i){initialized||(initialized=!0,t||console.error("mediaApplicationUrl variable is not defined"),$.ajax({url:t,method:"GET",success:function(t){$(".ta-content").append(t),$(document).trigger("mediaapplication:ready");var n={name:$("#t-mediaLibrary").text(),path:"",folder:"",isDirectory:!0};mediaApp=new Vue({el:"#mediaApp",data:{selectedFolder:{},mediaItems:[],selectedMedias:[],errors:[],dragDropThumbnail:new Image,smallThumbs:!1,gridView:!1,mediaFilter:"",sortBy:"",sortAsc:!0,itemsInPage:[]},created:function(){var e=this;e.dragDropThumbnail.src=(i||"")+"/OrchardCore.Media/Images/drag-thumbnail.png",bus.$on("folderSelected",(function(t){e.selectedFolder=t})),bus.$on("folderDeleted",(function(){e.selectRoot()})),bus.$on("folderAdded",(function(t){e.selectedFolder=t,t.selected=!0})),bus.$on("mediaListMoved",(function(t){e.loadFolder(e.selectedFolder),t&&e.errors.push(t)})),bus.$on("mediaRenamed",(function(t,i,n){var a=e.mediaItems.filter((function(e){return e.mediaPath===n}))[0];a.mediaPath=i,a.name=t})),bus.$on("createFolderRequested",(function(t){e.createFolder()})),bus.$on("deleteFolderRequested",(function(t){e.deleteFolder()})),bus.$on("sortChangeRequested",(function(t){e.changeSort(t)})),bus.$on("mediaToggleRequested",(function(t){e.toggleSelectionOfMedia(t)})),bus.$on("renameMediaRequested",(function(t){e.renameMedia(t)})),bus.$on("deleteMediaRequested",(function(t){e.deleteMediaItem(t)})),bus.$on("mediaDragStartRequested",(function(t,i){e.handleDragStart(t,i)})),bus.$on("pagerEvent",(function(t){e.itemsInPage=t,e.selectedMedias=[]})),localStorage.getItem("mediaApplicationPrefs")?e.currentPrefs=JSON.parse(localStorage.getItem("mediaApplicationPrefs")):e.selectedFolder=n},computed:{isHome:function(){return this.selectedFolder==n},parents:function(){var e=[];for(parentFolder=this.selectedFolder;parentFolder&&""!=parentFolder.path;)e.unshift(parentFolder),parentFolder=parentFolder.parent;return e},root:function(){return n},filteredMediaItems:function(){var e=this;e.selectedMedias=[];var t=e.mediaItems.filter((function(t){return t.name.toLowerCase().indexOf(e.mediaFilter.toLowerCase())>-1}));switch(e.sortBy){case"size":t.sort((function(t,i){return e.sortAsc?t.size-i.size:i.size-t.size}));break;case"mime":t.sort((function(t,i){return e.sortAsc?t.mime.toLowerCase().localeCompare(i.mime.toLowerCase()):i.mime.toLowerCase().localeCompare(t.mime.toLowerCase())}));break;case"lastModify":t.sort((function(t,i){return e.sortAsc?t.lastModify-i.lastModify:i.lastModify-t.lastModify}));break;default:t.sort((function(t,i){return e.sortAsc?t.name.toLowerCase().localeCompare(i.name.toLowerCase()):i.name.toLowerCase().localeCompare(t.name.toLowerCase())}))}return t},hiddenCount:function(){return this.mediaItems.length-this.filteredMediaItems.length},thumbSize:function(){return this.smallThumbs?100:240},currentPrefs:{get:function(){return{smallThumbs:this.smallThumbs,selectedFolder:this.selectedFolder,gridView:this.gridView}},set:function(e){e&&(this.smallThumbs=e.smallThumbs,this.selectedFolder=e.selectedFolder,this.gridView=e.gridView)}}},watch:{currentPrefs:function(e){localStorage.setItem("mediaApplicationPrefs",JSON.stringify(e))},selectedFolder:function(e){this.mediaFilter="",this.selectedFolder=e,this.loadFolder(e)}},mounted:function(){this.$refs.rootFolder.toggle()},methods:{uploadUrl:function(){if(!this.selectedFolder)return null;var e=$("#uploadFiles").val();return e+(-1==e.indexOf("?")?"?":"&")+"path="+encodeURIComponent(this.selectedFolder.path)},selectRoot:function(){this.selectedFolder=this.root},loadFolder:function(e){this.errors=[],this.selectedMedias=[];var t=this,i=$("#getMediaItemsUrl").val();console.log(e.path),$.ajax({url:i+(-1==i.indexOf("?")?"?":"&")+"path="+encodeURIComponent(e.path),method:"GET",success:function(e){e.forEach((function(e){e.open=!1})),t.mediaItems=e,t.selectedMedias=[],t.sortBy="",t.sortAsc=!0},error:function(i){console.log("error loading folder:"+e.path),t.selectRoot()}})},selectAll:function(){this.selectedMedias=[];for(var e=0;e-1&&(t.mediaItems.splice(n,1),bus.$emit("mediaDeleted",t.selectedMedias[i]))}t.selectedMedias=[]},error:function(e){console.error(e.responseText)}})}}}))},deleteMediaItem:function(e){var t=this;e&&confirmDialog(_objectSpread(_objectSpread({},$("#deleteMedia").data()),{},{callback:function(i){i&&$.ajax({url:$("#deleteMediaUrl").val()+"?path="+encodeURIComponent(e.mediaPath),method:"POST",data:{__RequestVerificationToken:$("input[name='__RequestVerificationToken']").val()},success:function(i){var n=t.mediaItems&&t.mediaItems.indexOf(e);n>-1&&(t.mediaItems.splice(n,1),bus.$emit("mediaDeleted",e))},error:function(e){console.error(e.responseText)}})}}))},handleDragStart:function(e,t){var i=[];this.selectedMedias.forEach((function(e){i.push(e.name)})),0==this.isMediaSelected(e)&&(i.push(e.name),this.selectedMedias.push(e)),t.dataTransfer.setData("mediaNames",JSON.stringify(i)),t.dataTransfer.setData("sourceFolder",this.selectedFolder.path),t.dataTransfer.setDragImage(this.dragDropThumbnail,10,10),t.dataTransfer.effectAllowed="move"},handleScrollWhileDrag:function(e){e.clientY<150&&window.scrollBy(0,-10),e.clientY>window.innerHeight-100&&window.scrollBy(0,10)},changeSort:function(e){this.sortBy==e?this.sortAsc=!this.sortAsc:(this.sortAsc=!0,this.sortBy=e)}}}),$("#create-folder-name").keypress((function(e){if(13==e.which)return $("#modalFooterOk").click(),!1})),$("#modalFooterOk").on("click",(function(e){var t=$("#create-folder-name").val();""!==t&&$.ajax({url:$("#createFolderUrl").val()+"?path="+encodeURIComponent(mediaApp.selectedFolder.path)+"&name="+encodeURIComponent(t),method:"POST",data:{__RequestVerificationToken:$("input[name='__RequestVerificationToken']").val()},success:function(e){bus.$emit("addFolder",mediaApp.selectedFolder,e),bootstrap.Modal.getOrCreateInstance($("#createFolderModal")).hide()},error:function(e){$("#createFolderModal-errors").empty();var t=JSON.parse(e.responseText).value;$('').text(t).appendTo($("#createFolderModal-errors"))}})})),$("#renameMediaModalFooterOk").on("click",(function(e){var t=$("#new-item-name").val(),i=$("#old-item-name").val();if(""!==t){var n=mediaApp.selectedFolder.path+"/";"/"===n&&(n="");var a=n+t,o=n+i;if(a.toLowerCase()!==o.toLowerCase())$.ajax({url:$("#renameMediaUrl").val()+"?oldPath="+encodeURIComponent(o)+"&newPath="+encodeURIComponent(a),method:"POST",data:{__RequestVerificationToken:$("input[name='__RequestVerificationToken']").val()},success:function(e){bootstrap.Modal.getOrCreateInstance($("#renameMediaModal")).hide(),bus.$emit("mediaRenamed",t,a,o)},error:function(e){$("#renameMediaModal-errors").empty();var t=JSON.parse(e.responseText).value;$('').text(t).appendTo($("#renameMediaModal-errors"))}});else bootstrap.Modal.getOrCreateInstance($("#renameMediaModal")).hide()}})),e&&(document.getElementById("mediaApp").style.display=""),$(document).trigger("mediaApp:ready")},error:function(e){console.error(e.responseText)}}))}function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function ownKeys(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function _objectSpread(e){for(var t=1;t\n \n
    \n \n \n
\n \n '),props:{model:Object,selectedInMediaApp:Object,level:Number},data:function(){return{open:!1,children:null,parent:null,isHovered:!1,padding:0}},computed:{empty:function(){return!this.children||0==this.children.length},isSelected:function(){return this.selectedInMediaApp.name==this.model.name&&this.selectedInMediaApp.path==this.model.path},isRoot:function(){return""===this.model.path}},mounted:function(){0==this.isRoot&&this.isAncestorOfSelectedFolder()&&this.toggle(),this.padding=this.level<3?16:16+8*this.level},created:function(){var e=this;bus.$on("deleteFolder",(function(t){if(e.children){var i=e.children&&e.children.indexOf(t);i>-1&&(e.children.splice(i,1),bus.$emit("folderDeleted"))}})),bus.$on("addFolder",(function(t,i){e.model==t&&(null!==e.children&&e.children.push(i),i.parent=e.model,bus.$emit("folderAdded",i))}))},methods:{isAncestorOfSelectedFolder:function(){for(parentFolder=mediaApp.selectedFolder;parentFolder;){if(parentFolder.path==this.model.path)return!0;parentFolder=parentFolder.parent}return!1},toggle:function(){this.open=!this.open,this.open&&!this.children&&this.loadChildren()},select:function(){bus.$emit("folderSelected",this.model),this.loadChildren()},createFolder:function(){bus.$emit("createFolderRequested")},deleteFolder:function(){bus.$emit("deleteFolderRequested")},loadChildren:function(){var e=this;0==this.open&&(this.open=!0),$.ajax({url:$("#getFoldersUrl").val()+"?path="+encodeURIComponent(e.model.path),method:"GET",success:function(t){e.children=t,e.children.forEach((function(t){t.parent=e.model}))},error:function(e){emtpy=!1,console.error(e.responseText)}})},handleDragOver:function(e){this.isHovered=!0},handleDragLeave:function(e){this.isHovered=!1},moveMediaToFolder:function(e,t){this.isHovered=!1;var i=JSON.parse(t.dataTransfer.getData("mediaNames"));if(!(i.length<1)){var n=t.dataTransfer.getData("sourceFolder"),a=e.path;""===n&&(n="root"),""===a&&(a="root"),n!==a?confirmDialog(_objectSpread(_objectSpread({},$("#moveMedia").data()),{},{callback:function(e){e&&$.ajax({url:$("#moveMediaListUrl").val(),method:"POST",data:{__RequestVerificationToken:$("input[name='__RequestVerificationToken']").val(),mediaNames:i,sourceFolder:n,targetFolder:a},success:function(){bus.$emit("mediaListMoved")},error:function(e){console.error(e.responseText),bus.$emit("mediaListMoved",e.responseText)}})}})):alert($("#sameFolderMessage").val())}}}});var faIcons={image:"fa-regular fa-image",pdf:"fa-regular fa-file-pdf",word:"fa-regular fa-file-word",powerpoint:"fa-regular fa-file-powerpoint",excel:"fa-regular fa-file-excel",csv:"fa-regular fa-file",audio:"fa-regular fa-file-audio",video:"fa-regular fa-file-video",archive:"fa-regular fa-file-zipper",code:"fa-regular fa-file-code",text:"fa-regular fa-file-lines",file:"fa-regular fa-file"},faThumbnails={gif:faIcons.image,jpeg:faIcons.image,jpg:faIcons.image,png:faIcons.image,pdf:faIcons.pdf,doc:faIcons.word,docx:faIcons.word,ppt:faIcons.powerpoint,pptx:faIcons.powerpoint,xls:faIcons.excel,xlsx:faIcons.excel,csv:faIcons.csv,aac:faIcons.audio,mp3:faIcons.audio,ogg:faIcons.audio,avi:faIcons.video,flv:faIcons.video,mkv:faIcons.video,mp4:faIcons.video,webm:faIcons.video,gz:faIcons.archive,zip:faIcons.archive,css:faIcons.code,html:faIcons.code,js:faIcons.code,txt:faIcons.text};function getClassNameForExtension(e){return faThumbnails[e.toLowerCase()]||faIcons.file}function getExtensionForFilename(e){return e.slice(2+(e.lastIndexOf(".")-1>>>0))}function getClassNameForFilename(e){return getClassNameForExtension(getExtensionForFilename(e))}function initializeAttachedMediaField(e,t,i,n,a,o,r,s,l){var d,c=$(document.getElementById($(e).data("for"))).data("init"),u=$(e),m=u.attr("id");mediaFieldApps.push(d=new Vue({el:u.get(0),data:{mediaItems:[],selectedMedia:null,smallThumbs:!1,idPrefix:m,initialized:!1,allowMediaText:o,backupMediaText:"",allowAnchors:r,backupAnchor:null,mediaTextmodal:null,anchoringModal:null},created:function(){this.currentPrefs=JSON.parse(localStorage.getItem("mediaFieldPrefs"))},computed:{paths:{get:function(){var e=[];return this.initialized?(this.mediaItems.forEach((function(t){"not-found"!==t.mediaPath&&e.push({path:t.mediaPath,isRemoved:t.isRemoved,isNew:t.isNew,mediaText:t.mediaText,anchor:t.anchor,attachedFileName:t.attachedFileName})})),JSON.stringify(e)):JSON.stringify(c)},set:function(e){var t=this,i=e||[],a=$.Deferred(),o=[],r=0;i.forEach((function(e,i){o.push({name:" "+e.path,mime:"",mediaPath:"",anchor:e.anchor,attachedFileName:e.attachedFileName}),promise=$.when(a).done((function(){$.ajax({url:n+"?path="+encodeURIComponent(e.path),method:"GET",success:function(n){n.vuekey=n.name+i.toString(),n.mediaText=e.mediaText,n.anchor=e.anchor,n.attachedFileName=e.attachedFileName,o.splice(i,1,n),o.length===++r&&(o.forEach((function(e){t.mediaItems.push(e)})),t.initialized=!0)},error:function(n){console.log(JSON.stringify(n)),o.splice(i,1,{name:e.path,mime:"",mediaPath:"not-found",mediaText:"",anchor:{x:.5,y:.5},attachedFileName:e.attachedFileName}),o.length===++r&&(o.forEach((function(e){t.mediaItems.push(e)})),t.initialized=!0)}})}))})),a.resolve()}},fileSize:function(){return Math.round(this.selectedMedia.size/1024)},canAddMedia:function(){for(var e=[],t=0;t0&&a},thumbSize:function(){return this.smallThumbs?120:240},currentPrefs:{get:function(){return{smallThumbs:this.smallThumbs}},set:function(e){e&&(this.smallThumbs=e.smallThumbs)}}},mounted:function(){var e=this;e.paths=c,e.$on("selectAndDeleteMediaRequested",(function(t){e.selectAndDeleteMedia(t)})),e.$on("selectMediaRequested",(function(t){e.selectMedia(t)}));var n="#"+t,o=u.attr("id"),r=randomUUID();$(n).fileupload({limitConcurrentUploads:20,dropZone:$("#"+o),dataType:"json",url:i,maxChunkSize:l,add:function(t,i){var n,a=i.files.length;for(n=0;n0)for(var o=0;o1&&!1===a?(alert($("#onlyOneItemMessage").val()),d.mediaItems.push(i[0]),d.initialized=!0):(d.mediaItems=d.mediaItems.concat(i),d.initialized=!0)):alert(n)},error:function(e,t,i){console.log("Error on upload."),console.log(e),console.log(t),console.log(i)}}).on("fileuploadchunkbeforesend",(function(e,t){var i=t.files[0];t.blob=new File([t.blob],i.name,{type:i.type,lastModified:i.lastModified})}))},methods:{selectMedia:function(e){this.selectedMedia=e},getUniqueId:function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))},removeSelected:function(e){if(this.selectedMedia){var t=this.mediaItems&&this.mediaItems.indexOf(this.selectedMedia);t>-1&&(this.mediaItems[t].isRemoved=!0,this.mediaItems.splice(t,1))}else 1===this.mediaItems.length&&(this.mediaItems[t].isRemoved=!0,this.mediaItems.splice(0,1));this.selectedMedia=null},showMediaTextModal:function(e){this.mediaTextModal=new bootstrap.Modal(this.$refs.mediaTextModal),this.mediaTextModal.show(),this.backupMediaText=this.selectedMedia.mediaText},cancelMediaTextModal:function(e){this.mediaTextModal.hide(),this.selectedMedia.mediaText=this.backupMediaText},showAnchorModal:function(e){this.anchoringModal=new bootstrap.Modal(this.$refs.anchoringModal),this.anchoringModal.show(),this.selectedMedia.anchor={x:this.selectedMedia.anchor.x,y:this.selectedMedia.anchor.y},this.backupAnchor=this.selectedMedia.anchor},cancelAnchoringModal:function(e){this.anchoringModal.hide(),this.selectedMedia.anchor=this.backupAnchor},resetAnchor:function(e){this.selectedMedia.anchor={x:.5,y:.5}},onAnchorDrop:function(e){var t=this.$refs.anchorImage;this.selectedMedia.anchor={x:e.offsetX/t.clientWidth,y:e.offsetY/t.clientHeight}},anchorLeft:function(){if(this.$refs.anchorImage&&this.$refs.modalBody&&this.selectedMedia){var e=(this.$refs.modalBody.clientWidth-this.$refs.anchorImage.clientWidth)/2,t=this.selectedMedia.anchor.x*this.$refs.anchorImage.clientWidth+e;return t<17?t=17:t-=8,t+"px"}return"0"},anchorTop:function(){if(this.$refs.anchorImage&&this.selectedMedia){var e=this.selectedMedia.anchor.y*this.$refs.anchorImage.clientHeight;return e<15?e=15:e+=5,e+"px"}return"0"},setAnchor:function(e){var t=this.$refs.anchorImage;this.selectedMedia.anchor={x:e.offsetX/t.clientWidth,y:e.offsetY/t.clientHeight}},addMediaFiles:function(e){e.length>1&&!1===a?(alert($("#onlyOneItemMessage").val()),d.mediaItems.push(e[0]),d.initialized=!0):(d.mediaItems=d.mediaItems.concat(e),d.initialized=!0)},selectAndDeleteMedia:function(e){var t=this;t.selectedMedia=e,setTimeout((function(){t.removeSelected()}),100)}},watch:{mediaItems:{deep:!0,handler:function(){setTimeout((function(){$(document).trigger("contentpreview:render")}),100)}},currentPrefs:function(e){localStorage.setItem("mediaFieldPrefs",JSON.stringify(e))}}}))}function initializeMediaField(e,t,i,n,a,o){if(null!==e){var r,s=$(document.getElementById($(e).data("for"))).data("init"),l=$(e),d=l.attr("id");t.addEventListener("hidden.bs.modal",(function(e){$("#mediaApp").appendTo("body"),$("#mediaApp").hide()})),mediaFieldApps.push(r=new Vue({el:l.get(0),data:{mediaItems:[],selectedMedia:null,smallThumbs:!1,idPrefix:d,initialized:!1,allowMediaText:a,backupMediaText:"",allowAnchors:o,backupAnchor:null,mediaTextModal:null,anchoringModal:null},created:function(){this.currentPrefs=JSON.parse(localStorage.getItem("mediaFieldPrefs"))},computed:{paths:{get:function(){var e=[];return this.initialized?(this.mediaItems.forEach((function(t){"not-found"!==t.mediaPath&&e.push({path:t.mediaPath,mediaText:t.mediaText,anchor:t.anchor})})),JSON.stringify(e)):JSON.stringify(s)},set:function(e){var t=this,n=e||[],a=$.Deferred(),o=[],r=0;n.forEach((function(e,n){o.push({name:" "+e.path,mime:"",mediaPath:""}),promise=$.when(a).done((function(){$.ajax({url:i+"?path="+encodeURIComponent(e.path),method:"GET",success:function(i){i.vuekey=i.name+n.toString(),i.mediaText=e.mediaText,i.anchor=e.anchor,o.splice(n,1,i),o.length===++r&&(o.forEach((function(e){t.mediaItems.push(e)})),t.initialized=!0)},error:function(i){console.log(i),o.splice(n,1,{name:e.path,mime:"",mediaPath:"not-found",mediaText:"",anchor:{x:0,y:0}}),o.length===++r&&(o.forEach((function(e){t.mediaItems.push(e)})),t.initialized=!0)}})}))})),a.resolve()}},fileSize:function(){return Math.round(this.selectedMedia.size/1024)},canAddMedia:function(){return 0===this.mediaItems.length||this.mediaItems.length>0&&n},thumbSize:function(){return this.smallThumbs?120:240},currentPrefs:{get:function(){return{smallThumbs:this.smallThumbs}},set:function(e){e&&(this.smallThumbs=e.smallThumbs)}}},mounted:function(){var e=this;e.paths=s,e.$on("selectAndDeleteMediaRequested",(function(t){e.selectAndDeleteMedia(t)})),e.$on("selectMediaRequested",(function(t){e.selectMedia(t)})),e.$on("filesUploaded",(function(t){e.addMediaFiles(t)}))},methods:{selectMedia:function(e){this.selectedMedia=e},showModal:function(e){var i=this;if(i.canAddMedia){$("#mediaApp").appendTo($(t).find(".modal-body")),$("#mediaApp").show();var n=new bootstrap.Modal(t);n.show(),$(t).find(".mediaFieldSelectButton").off("click").on("click",(function(e){return i.addMediaFiles(mediaApp.selectedMedias),mediaApp.selectedMedias=[],n.hide(),!0}))}},showMediaTextModal:function(e){this.mediaTextModal=new bootstrap.Modal(this.$refs.mediaTextModal),this.mediaTextModal.show(),this.backupMediaText=this.selectedMedia.mediaText},cancelMediaTextModal:function(e){this.mediaTextModal.hide(),this.selectedMedia.mediaText=this.backupMediaText},showAnchorModal:function(e){this.anchoringModal=new bootstrap.Modal(this.$refs.anchoringModal),this.anchoringModal.show(),this.selectedMedia.anchor={x:this.selectedMedia.anchor.x,y:this.selectedMedia.anchor.y},this.backupAnchor=this.selectedMedia.anchor},cancelAnchoringModal:function(e){this.anchoringModal.hide(),this.selectedMedia.anchor=this.backupAnchor},resetAnchor:function(e){this.selectedMedia.anchor={x:.5,y:.5}},onAnchorDrop:function(e){var t=this.$refs.anchorImage;this.selectedMedia.anchor={x:e.offsetX/t.clientWidth,y:e.offsetY/t.clientHeight}},anchorLeft:function(){if(this.$refs.anchorImage&&this.$refs.modalBody&&this.selectedMedia){var e=(this.$refs.modalBody.clientWidth-this.$refs.anchorImage.clientWidth)/2,t=this.selectedMedia.anchor.x*this.$refs.anchorImage.clientWidth+e,i=Math.round(this.$refs.modalBody.querySelector(".icon-media-anchor").clientWidth);return Number.isInteger(i)&&(t-=i/2),t+"px"}return"0"},anchorTop:function(){return this.$refs.anchorImage&&this.selectedMedia?this.selectedMedia.anchor.y*this.$refs.anchorImage.clientHeight+"px":"0"},setAnchor:function(e){var t=this.$refs.anchorImage;this.selectedMedia.anchor={x:e.offsetX/t.clientWidth,y:e.offsetY/t.clientHeight}},addMediaFiles:function(e){e.length>1&&!1===n?(alert($("#onlyOneItemMessage").val()),r.mediaItems.push(e[0]),r.initialized=!0):(r.mediaItems=r.mediaItems.concat(e),r.initialized=!0)},removeSelected:function(e){if(this.selectedMedia){var t=this.mediaItems&&this.mediaItems.indexOf(this.selectedMedia);t>-1&&this.mediaItems.splice(t,1)}else 1===this.mediaItems.length&&this.mediaItems.splice(0,1);this.selectedMedia=null},selectAndDeleteMedia:function(e){var t=this;t.selectedMedia=e,setTimeout((function(){t.removeSelected()}),100)}},watch:{mediaItems:{deep:!0,handler:function(){setTimeout((function(){$(document).trigger("contentpreview:render")}),100)}},currentPrefs:function(e){localStorage.setItem("mediaFieldPrefs",JSON.stringify(e))}}}))}}Vue.component("media-items-grid",{template:'\n
    \n
  1. \n
    \n \n \n
    \n
    \n \n \n \n {{ media.name }}\n
    \n
  2. \n
\n ',data:function(){return{T:{}}},props:{filteredMediaItems:Array,selectedMedias:Array,thumbSize:Number},created:function(){this.T.editButton=$("#t-edit-button").val(),this.T.deleteButton=$("#t-delete-button").val()},methods:{isMediaSelected:function(e){return this.selectedMedias.some((function(t,i,n){return t.url.toLowerCase()===e.url.toLowerCase()}))},buildMediaUrl:function(e,t){return e+(-1==e.indexOf("?")?"?":"&")+"width="+t+"&height="+t},toggleSelectionOfMedia:function(e){bus.$emit("mediaToggleRequested",e)},renameMedia:function(e){bus.$emit("renameMediaRequested",e)},deleteMedia:function(e){bus.$emit("deleteMediaRequested",e)},dragStart:function(e,t){bus.$emit("mediaDragStartRequested",e,t)},getfontAwesomeClassNameForFileName:function(e,t){return getClassNameForFilename(e)+" "+t}}}),Vue.component("media-items-table",{template:'\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{ T.imageHeader }}\n {{ T.nameHeader }}\n \n \n {{ T.lastModifyHeader }} \n \n \n \n {{ T.sizeHeader }}\n \n \n \n \n {{ T.typeHeader }}\n \n \n
\n
\n \n \n
\n
\n \n \n
{{ printDateTime(media.lastModify) }}
\n
\n
{{ isNaN(media.size)? 0 : Math.round(media.size / 1024) }} KB
\n
\n
{{ media.mime }}
\n
\n ',data:function(){return{T:{}}},props:{sortBy:String,sortAsc:Boolean,filteredMediaItems:Array,selectedMedias:Array,thumbSize:Number},created:function(){var e=this;e.T.imageHeader=$("#t-image-header").val(),e.T.nameHeader=$("#t-name-header").val(),e.T.lastModifyHeader=$("#t-lastModify-header").val(),e.T.sizeHeader=$("#t-size-header").val(),e.T.typeHeader=$("#t-type-header").val(),e.T.editButton=$("#t-edit-button").val(),e.T.deleteButton=$("#t-delete-button").val(),e.T.viewButton=$("#t-view-button").val()},methods:{isMediaSelected:function(e){return this.selectedMedias.some((function(t,i,n){return t.url.toLowerCase()===e.url.toLowerCase()}))},buildMediaUrl:function(e,t){return e+(-1==e.indexOf("?")?"?":"&")+"width="+t+"&height="+t},changeSort:function(e){bus.$emit("sortChangeRequested",e)},toggleSelectionOfMedia:function(e){bus.$emit("mediaToggleRequested",e)},renameMedia:function(e){bus.$emit("renameMediaRequested",e)},deleteMedia:function(e){bus.$emit("deleteMediaRequested",e)},dragStart:function(e,t){bus.$emit("mediaDragStartRequested",e,t)},printDateTime:function(e){return new Date(e).toLocaleString()},getfontAwesomeClassNameForFileName:function(e,t){return getClassNameForFilename(e)+" "+t}}}),Vue.component("pager",{template:'\n
\n \n \n
\n ',props:{sourceItems:Array},data:function(){return{pageSize:10,pageSizeOptions:[10,30,50,100],current:0,T:{}}},created:function(){var e=this;e.T.pagerFirstButton=$("#t-pager-first-button").val(),e.T.pagerPreviousButton=$("#t-pager-previous-button").val(),e.T.pagerNextButton=$("#t-pager-next-button").val(),e.T.pagerLastButton=$("#t-pager-last-button").val(),e.T.pagerPageSizeLabel=$("#t-pager-page-size-label").val(),e.T.pagerPageLabel=$("#t-pager-page-label").val(),e.T.pagerTotalLabel=$("#t-pager-total-label").val()},methods:{next:function(){this.current=this.current+1},previous:function(){this.current=this.current-1},goFirst:function(){this.current=0},goLast:function(){this.current=this.totalPages-1},goTo:function(e){this.current=e}},computed:{total:function(){return this.sourceItems?this.sourceItems.length:0},totalPages:function(){var e=Math.ceil(this.total/this.pageSize);return e>0?e:1},isLastPage:function(){return this.current+1>=this.totalPages},isFirstPage:function(){return 0===this.current},canDoNext:function(){return!this.isLastPage},canDoPrev:function(){return!this.isFirstPage},canDoFirst:function(){return!this.isFirstPage},canDoLast:function(){return!this.isLastPage},itemsInCurrentPage:function(){var e=this.pageSize*this.current,t=e+this.pageSize,i=this.sourceItems.slice(e,t);return bus.$emit("pagerEvent",i),i},pageLinks:function(){var e=[];e.push(this.current+1);var t=this.current>0?this.current:-1;e.unshift(t);var i=this.current>1?this.current-1:-1;e.unshift(i);var n=this.totalPages-this.current>1?this.current+2:-1;e.push(n);var a=this.totalPages-this.current>2?this.current+3:-1;return e.push(a),e}},watch:{sourceItems:function(){this.current=0},pageSize:function(){this.current=0}}}),Vue.component("sortIndicator",{template:'\n
\n \n \n
\n ',props:{colname:String,selectedcolname:String,asc:Boolean},computed:{isActive:function(){return this.colname.toLowerCase()==this.selectedcolname.toLowerCase()}}});var mediaFieldApps=[];Vue.component("mediaFieldThumbsContainer",{template:'
{{T.noImages}}
  • {{ media.isNew ? media.name.substr(36) : media.name }}
    {{ T.mediaNotFound }} {{ T.discardWarning }}
    {{ media.name }}
  • ',data:function(){return{T:{}}},props:{mediaItems:Array,selectedMedia:Object,thumbSize:Number,idPrefix:String},created:function(){var e=this;e.T.mediaNotFound=$("#t-media-not-found").val(),e.T.discardWarning=$("#t-discard-warning").val(),e.T.noImages=$("#t-no-images").val()},methods:{selectAndDeleteMedia:function(e){this.$parent.$emit("selectAndDeleteMediaRequested",e)},selectMedia:function(e){this.$parent.$emit("selectMediaRequested",e)},buildMediaUrl:function(e,t){return e+(-1==e.indexOf("?")?"?":"&")+"width="+t+"&height="+t},getfontAwesomeClassNameForFileName:function(e,t){return getClassNameForFilename(e)+" "+t}}}),Vue.component("upload",{template:'

    {{ model.name }}

    Error: {{ model.errorMessage }}
    ',props:{model:Object,uploadInputId:String},mounted:function(){var e,t=this,i=document.getElementById(null!==(e=t.uploadInputId)&&void 0!==e?e:"fileupload");$(i).bind("fileuploadprogress",(function(e,i){i.files[0].name===t.model.name&&(t.model.percentage=parseInt(i.loaded/i.total*100,10))})),$(i).bind("fileuploaddone",(function(e,i){i.files[0].name===t.model.name&&(i.result.files[0].error?t.handleFailure(i.files[0].name,i.result.files[0].error):bus.$emit("removalRequest",t.model))})),$(i).bind("fileuploadfail",(function(e,i){i.files[0].name===t.model.name&&t.handleFailure(i.files[0].name,$("#t-error").val())}))},methods:{handleFailure:function(e,t){e===this.model.name&&(this.model.errorMessage=t,bus.$emit("ErrorOnUpload",this.model))},dismissWarning:function(){bus.$emit("removalRequest",this.model)}}}),Vue.component("uploadList",{template:'
    {{ T.uploads }} (Pending: {{ pendingCount }}) ( {{ T.errors }}: {{ errorCount }} / {{ T.clearErrors }} )
    ',data:function(){return{files:[],T:{},expanded:!1,pendingCount:0,errorCount:0}},props:{uploadInputId:String},created:function(){var e=this;e.T.uploads=$("#t-uploads").val(),e.T.errors=$("#t-errors").val(),e.T.clearErrors=$("#t-clear-errors").val()},computed:{fileCount:function(){return this.files.length}},mounted:function(){var e,t=this,i=document.getElementById(null!==(e=t.uploadInputId)&&void 0!==e?e:"fileupload");$(i).bind("fileuploadadd",(function(e,i){i.files&&i.files.forEach((function(e){t.files.some((function(t){return t.name==e.name}))?console.error("A file with the same name is already on the queue:"+e.name):t.files.push({name:e.name,percentage:0,errorMessage:""})}))})),bus.$on("removalRequest",(function(e){t.files.forEach((function(t,i,n){t.name==e.name&&n.splice(i,1)}))})),bus.$on("ErrorOnUpload",(function(e){t.updateCount()}))},methods:{updateCount:function(){this.errorCount=this.files.filter((function(e){return""!=e.errorMessage})).length,this.pendingCount=this.files.length-this.errorCount,this.files.length<1&&(this.expanded=!1)},clearErrors:function(){this.files=this.files.filter((function(e){return""==e.errorMessage}))}},watch:{files:function(){this.updateCount()}}}); +function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function randomUUID(){return"object"===("undefined"==typeof crypto?"undefined":_typeof(crypto))&&"function"==typeof crypto.randomUUID?crypto.randomUUID():([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,(function(e){return(e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>e/4).toString(16)}))}function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function ownKeys(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function _objectSpread(e){for(var t=1;t').prop("disabled")),e.support.xhrFileUpload=!(!window.ProgressEvent||!window.FileReader),e.support.xhrFormDataFileUpload=!!window.FormData,e.support.blobSlice=window.Blob&&(Blob.prototype.slice||Blob.prototype.webkitSlice||Blob.prototype.mozSlice),e.widget("blueimp.fileupload",{options:{dropZone:e(document),pasteZone:void 0,fileInput:void 0,replaceFileInput:!0,paramName:void 0,singleFileUploads:!0,limitMultiFileUploads:void 0,limitMultiFileUploadSize:void 0,limitMultiFileUploadSizeOverhead:512,sequentialUploads:!1,limitConcurrentUploads:void 0,forceIframeTransport:!1,redirect:void 0,redirectParamName:void 0,postMessage:void 0,multipart:!0,maxChunkSize:void 0,uploadedBytes:void 0,recalculateProgress:!0,progressInterval:100,bitrateInterval:500,autoUpload:!0,uniqueFilenames:void 0,messages:{uploadedBytes:"Uploaded bytes exceed file size"},i18n:function(t,i){return t=this.messages[t]||t.toString(),i&&e.each(i,(function(e,i){t=t.replace("{"+e+"}",i)})),t},formData:function(e){return e.serializeArray()},add:function(t,i){if(t.isDefaultPrevented())return!1;(i.autoUpload||!1!==i.autoUpload&&e(this).fileupload("option","autoUpload"))&&i.process().done((function(){i.submit()}))},processData:!1,contentType:!1,cache:!1,timeout:0},_promisePipe:(i=e.fn.jquery.split("."),Number(i[0])>1||Number(i[1])>7?"then":"pipe"),_specialOptions:["fileInput","dropZone","pasteZone","multipart","forceIframeTransport"],_blobSlice:e.support.blobSlice&&function(){return(this.slice||this.webkitSlice||this.mozSlice).apply(this,arguments)},_BitrateTimer:function(){this.timestamp=Date.now?Date.now():(new Date).getTime(),this.loaded=0,this.bitrate=0,this.getBitrate=function(e,t,i){var n=e-this.timestamp;return(!this.bitrate||!i||n>i)&&(this.bitrate=(t-this.loaded)*(1e3/n)*8,this.loaded=t,this.timestamp=e),this.bitrate}},_isXHRUpload:function(t){return!t.forceIframeTransport&&(!t.multipart&&e.support.xhrFileUpload||e.support.xhrFormDataFileUpload)},_getFormData:function(t){var i;return"function"===e.type(t.formData)?t.formData(t.form):e.isArray(t.formData)?t.formData:"object"===e.type(t.formData)?(i=[],e.each(t.formData,(function(e,t){i.push({name:e,value:t})})),i):[]},_getTotal:function(t){var i=0;return e.each(t,(function(e,t){i+=t.size||1})),i},_initProgressObject:function(t){var i={loaded:0,total:0,bitrate:0};t._progress?e.extend(t._progress,i):t._progress=i},_initResponseObject:function(e){var t;if(e._response)for(t in e._response)Object.prototype.hasOwnProperty.call(e._response,t)&&delete e._response[t];else e._response={}},_onProgress:function(t,i){if(t.lengthComputable){var n,a=Date.now?Date.now():(new Date).getTime();if(i._time&&i.progressInterval&&a-i._time").prop("href",t.url).prop("host");t.dataType="iframe "+(t.dataType||""),t.formData=this._getFormData(t),t.redirect&&i&&i!==location.host&&t.formData.push({name:t.redirectParamName||"redirect",value:t.redirect})},_initDataSettings:function(e){this._isXHRUpload(e)?(this._chunkedUpload(e,!0)||(e.data||this._initXHRData(e),this._initProgressListener(e)),e.postMessage&&(e.dataType="postmessage "+(e.dataType||""))):this._initIframeSettings(e)},_getParamName:function(t){var i=e(t.fileInput),n=t.paramName;return n?e.isArray(n)||(n=[n]):(n=[],i.each((function(){for(var t=e(this),i=t.prop("name")||"files[]",a=(t.prop("files")||[1]).length;a;)n.push(i),a-=1})),n.length||(n=[i.prop("name")||"files[]"])),n},_initFormSettings:function(t){t.form&&t.form.length||(t.form=e(t.fileInput.prop("form")),t.form.length||(t.form=e(this.options.fileInput.prop("form")))),t.paramName=this._getParamName(t),t.url||(t.url=t.form.prop("action")||location.href),t.type=(t.type||"string"===e.type(t.form.prop("method"))&&t.form.prop("method")||"").toUpperCase(),"POST"!==t.type&&"PUT"!==t.type&&"PATCH"!==t.type&&(t.type="POST"),t.formAcceptCharset||(t.formAcceptCharset=t.form.attr("accept-charset"))},_getAJAXSettings:function(t){var i=e.extend({},this.options,t);return this._initFormSettings(i),this._initDataSettings(i),i},_getDeferredState:function(e){return e.state?e.state():e.isResolved()?"resolved":e.isRejected()?"rejected":"pending"},_enhancePromise:function(e){return e.success=e.done,e.error=e.fail,e.complete=e.always,e},_getXHRPromise:function(t,i,n){var a=e.Deferred(),o=a.promise();return i=i||this.options.context||o,!0===t?a.resolveWith(i,n):!1===t&&a.rejectWith(i,n),o.abort=a.promise,this._enhancePromise(o)},_addConvenienceMethods:function(t,i){var n=this,a=function(t){return e.Deferred().resolveWith(n,t).promise()};i.process=function(t,o){return(t||o)&&(i._processQueue=this._processQueue=(this._processQueue||a([this]))[n._promisePipe]((function(){return i.errorThrown?e.Deferred().rejectWith(n,[i]).promise():a(arguments)}))[n._promisePipe](t,o)),this._processQueue||a([this])},i.submit=function(){return"pending"!==this.state()&&(i.jqXHR=this.jqXHR=!1!==n._trigger("submit",e.Event("submit",{delegatedEvent:t}),this)&&n._onSend(t,this)),this.jqXHR||n._getXHRPromise()},i.abort=function(){return this.jqXHR?this.jqXHR.abort():(this.errorThrown="abort",n._trigger("fail",null,this),n._getXHRPromise(!1))},i.state=function(){return this.jqXHR?n._getDeferredState(this.jqXHR):this._processQueue?n._getDeferredState(this._processQueue):void 0},i.processing=function(){return!this.jqXHR&&this._processQueue&&"pending"===n._getDeferredState(this._processQueue)},i.progress=function(){return this._progress},i.response=function(){return this._response}},_getUploadedBytes:function(e){var t=e.getResponseHeader("Range"),i=t&&t.split("-"),n=i&&i.length>1&&parseInt(i[1],10);return n&&n+1},_chunkedUpload:function(t,i){t.uploadedBytes=t.uploadedBytes||0;var n,a,o=this,r=t.files[0],s=r.size,l=t.uploadedBytes,d=t.maxChunkSize||s,c=this._blobSlice,u=e.Deferred(),m=u.promise();return!(!(this._isXHRUpload(t)&&c&&(l||("function"===e.type(d)?d(t):d)=s?(r.error=t.i18n("uploadedBytes"),this._getXHRPromise(!1,t.context,[null,"error",r.error])):(a=function(){var i=e.extend({},t),m=i._progress.loaded;i.blob=c.call(r,l,l+("function"===e.type(d)?d(i):d),r.type),i.chunkSize=i.blob.size,i.contentRange="bytes "+l+"-"+(l+i.chunkSize-1)+"/"+s,o._trigger("chunkbeforesend",null,i),o._initXHRData(i),o._initProgressListener(i),n=(!1!==o._trigger("chunksend",null,i)&&e.ajax(i)||o._getXHRPromise(!1,i.context)).done((function(n,r,d){l=o._getUploadedBytes(d)||l+i.chunkSize,m+i.chunkSize-i._progress.loaded&&o._onProgress(e.Event("progress",{lengthComputable:!0,loaded:l-i.uploadedBytes,total:l-i.uploadedBytes}),i),t.uploadedBytes=i.uploadedBytes=l,i.result=n,i.textStatus=r,i.jqXHR=d,o._trigger("chunkdone",null,i),o._trigger("chunkalways",null,i),ls._sending)for(var n=s._slots.shift();n;){if("pending"===s._getDeferredState(n)){n.resolve();break}n=s._slots.shift()}0===s._active&&s._trigger("stop")}))};return this._beforeSend(t,l),this.options.sequentialUploads||this.options.limitConcurrentUploads&&this.options.limitConcurrentUploads<=this._sending?(this.options.limitConcurrentUploads>1?(o=e.Deferred(),this._slots.push(o),r=o[s._promisePipe](d)):(this._sequence=this._sequence[s._promisePipe](d,d),r=this._sequence),r.abort=function(){return a=[void 0,"abort","abort"],n?n.abort():(o&&o.rejectWith(l.context,a),d())},this._enhancePromise(r)):d()},_onAdd:function(t,i){var n,a,o,r,s=this,l=!0,d=e.extend({},this.options,i),c=i.files,u=c.length,m=d.limitMultiFileUploads,p=d.limitMultiFileUploadSize,f=d.limitMultiFileUploadSizeOverhead,h=0,g=this._getParamName(d),v=0;if(!u)return!1;if(p&&void 0===c[0].size&&(p=void 0),(d.singleFileUploads||m||p)&&this._isXHRUpload(d))if(d.singleFileUploads||p||!m)if(!d.singleFileUploads&&p)for(o=[],n=[],r=0;rp||m&&r+1-v>=m)&&(o.push(c.slice(v,r+1)),(a=g.slice(v,r+1)).length||(a=g),n.push(a),v=r+1,h=0);else n=g;else for(o=[],n=[],r=0;r").append(n)[0].reset(),i.after(n).detach(),a&&n.trigger("focus"),e.cleanData(i.off("remove")),this.options.fileInput=this.options.fileInput.map((function(e,t){return t===i[0]?n[0]:t})),i[0]===this.element[0]&&(this.element=n)},_handleFileTreeEntry:function(t,i){var n,a=this,o=e.Deferred(),r=[],s=function(e){e&&!e.entry&&(e.entry=t),o.resolve([e])};return i=i||"",t.isFile?t._file?(t._file.relativePath=i,o.resolve(t._file)):t.file((function(e){e.relativePath=i,o.resolve(e)}),s):t.isDirectory?(n=t.createReader(),function e(){n.readEntries((function(n){n.length?(r=r.concat(n),e()):function(e){a._handleFileTreeEntries(e,i+t.name+"/").done((function(e){o.resolve(e)})).fail(s)}(r)}),s)}()):o.resolve([]),o.promise()},_handleFileTreeEntries:function(t,i){var n=this;return e.when.apply(e,e.map(t,(function(e){return n._handleFileTreeEntry(e,i)})))[this._promisePipe]((function(){return Array.prototype.concat.apply([],arguments)}))},_getDroppedFiles:function(t){var i=(t=t||{}).items;return i&&i.length&&(i[0].webkitGetAsEntry||i[0].getAsEntry)?this._handleFileTreeEntries(e.map(i,(function(e){var t;return e.webkitGetAsEntry?((t=e.webkitGetAsEntry())&&(t._file=e.getAsFile()),t):e.getAsEntry()}))):e.Deferred().resolve(e.makeArray(t.files)).promise()},_getSingleFileInputFiles:function(t){var i,n,a=(t=e(t)).prop("entries");if(a&&a.length)return this._handleFileTreeEntries(a);if((i=e.makeArray(t.prop("files"))).length)void 0===i[0].name&&i[0].fileName&&e.each(i,(function(e,t){t.name=t.fileName,t.size=t.fileSize}));else{if(!(n=t.prop("value")))return e.Deferred().resolve([]).promise();i=[{name:n.replace(/^.*\\/,"")}]}return e.Deferred().resolve(i).promise()},_getFileInputFiles:function(t){return t instanceof e&&1!==t.length?e.when.apply(e,e.map(t,this._getSingleFileInputFiles))[this._promisePipe]((function(){return Array.prototype.concat.apply([],arguments)})):this._getSingleFileInputFiles(t)},_onChange:function(t){var i=this,n={fileInput:e(t.target),form:e(t.target.form)};this._getFileInputFiles(n.fileInput).always((function(a){n.files=a,i.options.replaceFileInput&&i._replaceFileInput(n),!1!==i._trigger("change",e.Event("change",{delegatedEvent:t}),n)&&i._onAdd(t,n)}))},_onPaste:function(t){var i=t.originalEvent&&t.originalEvent.clipboardData&&t.originalEvent.clipboardData.items,n={files:[]};i&&i.length&&(e.each(i,(function(e,t){var i=t.getAsFile&&t.getAsFile();i&&n.files.push(i)})),!1!==this._trigger("paste",e.Event("paste",{delegatedEvent:t}),n)&&this._onAdd(t,n))},_onDrop:function(t){t.dataTransfer=t.originalEvent&&t.originalEvent.dataTransfer;var i=this,n=t.dataTransfer,a={};n&&n.files&&n.files.length&&(t.preventDefault(),this._getDroppedFiles(n).always((function(n){a.files=n,!1!==i._trigger("drop",e.Event("drop",{delegatedEvent:t}),a)&&i._onAdd(t,a)})))},_onDragOver:t("dragover"),_onDragEnter:t("dragenter"),_onDragLeave:t("dragleave"),_initEventHandlers:function(){this._isXHRUpload(this.options)&&(this._on(this.options.dropZone,{dragover:this._onDragOver,drop:this._onDrop,dragenter:this._onDragEnter,dragleave:this._onDragLeave}),this._on(this.options.pasteZone,{paste:this._onPaste})),e.support.fileInput&&this._on(this.options.fileInput,{change:this._onChange})},_destroyEventHandlers:function(){this._off(this.options.dropZone,"dragenter dragleave dragover drop"),this._off(this.options.pasteZone,"paste"),this._off(this.options.fileInput,"change")},_destroy:function(){this._destroyEventHandlers()},_setOption:function(t,i){var n=-1!==e.inArray(t,this._specialOptions);n&&this._destroyEventHandlers(),this._super(t,i),n&&(this._initSpecialOptions(),this._initEventHandlers())},_initSpecialOptions:function(){var t=this.options;void 0===t.fileInput?t.fileInput=this.element.is('input[type="file"]')?this.element:this.element.find('input[type="file"]'):t.fileInput instanceof e||(t.fileInput=e(t.fileInput)),t.dropZone instanceof e||(t.dropZone=e(t.dropZone)),t.pasteZone instanceof e||(t.pasteZone=e(t.pasteZone))},_getRegExp:function(e){var t=e.split("/"),i=t.pop();return t.shift(),new RegExp(t.join("/"),i)},_isRegExpOption:function(t,i){return"url"!==t&&"string"===e.type(i)&&/^\/.*\/[igm]{0,3}$/.test(i)},_initDataAttributes:function(){var t=this,i=this.options,n=this.element.data();e.each(this.element[0].attributes,(function(e,a){var o,r=a.name.toLowerCase();/^data-/.test(r)&&(r=r.slice(5).replace(/-[a-z]/g,(function(e){return e.charAt(1).toUpperCase()})),o=n[r],t._isRegExpOption(r,o)&&(o=t._getRegExp(o)),i[r]=o)}))},_create:function(){this._initDataAttributes(),this._initSpecialOptions(),this._slots=[],this._sequence=this._getXHRPromise(!0),this._sending=this._active=0,this._initProgressObject(this),this._initEventHandlers()},active:function(){return this._active},progress:function(){return this._progress},add:function(t){var i=this;t&&!this.options.disabled&&(t.fileInput&&!t.files?this._getFileInputFiles(t.fileInput).always((function(e){t.files=e,i._onAdd(null,t)})):(t.files=e.makeArray(t.files),this._onAdd(null,t)))},send:function(t){if(t&&!this.options.disabled){if(t.fileInput&&!t.files){var i,n,a=this,o=e.Deferred(),r=o.promise();return r.abort=function(){return n=!0,i?i.abort():(o.reject(null,"abort","abort"),r)},this._getFileInputFiles(t.fileInput).always((function(e){n||(e.length?(t.files=e,(i=a._onSend(null,t)).then((function(e,t,i){o.resolve(e,t,i)}),(function(e,t,i){o.reject(e,t,i)}))):o.reject())})),this._enhancePromise(r)}if(t.files=e.makeArray(t.files),t.files.length)return this._onSend(null,t)}return this._getXHRPromise(!1,t&&t.context)}})})),function(e){"use strict";"function"==typeof define&&define.amd?define(["jquery"],e):"object"===("undefined"==typeof exports?"undefined":_typeof(exports))?e(require("jquery")):e(window.jQuery)}((function(e){"use strict";var t=0,i=e,n="parseJSON";"JSON"in window&&"parse"in JSON&&(i=JSON,n="parse"),e.ajaxTransport("iframe",(function(i){if(i.async){var n,a,o,r=i.initialIframeSrc||"javascript:false;";return{send:function(s,l){(n=e('
    ')).attr("accept-charset",i.formAcceptCharset),o=/\?/.test(i.url)?"&":"?","DELETE"===i.type?(i.url=i.url+o+"_method=DELETE",i.type="POST"):"PUT"===i.type?(i.url=i.url+o+"_method=PUT",i.type="POST"):"PATCH"===i.type&&(i.url=i.url+o+"_method=PATCH",i.type="POST"),a=e('').on("load",(function(){var t,o=e.isArray(i.paramName)?i.paramName:[i.paramName];a.off("load").on("load",(function(){var t;try{if(!(t=a.contents()).length||!t[0].firstChild)throw new Error}catch(e){t=void 0}l(200,"success",{iframe:t}),e('').appendTo(n),window.setTimeout((function(){n.remove()}),0)})),n.prop("target",a.prop("name")).prop("action",i.url).prop("method",i.type),i.formData&&e.each(i.formData,(function(t,i){e('').prop("name",i.name).val(i.value).appendTo(n)})),i.fileInput&&i.fileInput.length&&"POST"===i.type&&(t=i.fileInput.clone(),i.fileInput.after((function(e){return t[e]})),i.paramName&&i.fileInput.each((function(t){e(this).prop("name",o[t]||i.paramName)})),n.append(i.fileInput).prop("enctype","multipart/form-data").prop("encoding","multipart/form-data"),i.fileInput.removeAttr("form")),window.setTimeout((function(){n.submit(),t&&t.length&&i.fileInput.each((function(i,n){var a=e(t[i]);e(n).prop("name",a.prop("name")).attr("form",a.attr("form")),a.replaceWith(n)}))}),0)})),n.append(a).appendTo(document.body)},abort:function(){a&&a.off("load").prop("src",r),n&&n.remove()}}}})),e.ajaxSetup({converters:{"iframe text":function(t){return t&&e(t[0].body).text()},"iframe json":function(t){return t&&i[n](e(t[0].body).text())},"iframe html":function(t){return t&&e(t[0].body).html()},"iframe xml":function(t){var i=t&&t[0];return i&&e.isXMLDoc(i)?i:e.parseXML(i.XMLDocument&&i.XMLDocument.xml||e(i.body).html())},"iframe script":function(t){return t&&e.globalEval(e(t[0].body).text())}}})}));var bus=new Vue;function initializeMediaApplication(e,t,i){initialized||(initialized=!0,t||console.error("mediaApplicationUrl variable is not defined"),$.ajax({url:t,method:"GET",success:function(t){$(".ta-content").append(t),$(document).trigger("mediaapplication:ready");var n={name:$("#t-mediaLibrary").text(),path:"",folder:"",isDirectory:!0};mediaApp=new Vue({el:"#mediaApp",data:{selectedFolder:{},mediaItems:[],selectedMedias:[],errors:[],dragDropThumbnail:new Image,smallThumbs:!1,gridView:!1,mediaFilter:"",sortBy:"",sortAsc:!0,itemsInPage:[]},created:function(){var e=this;e.dragDropThumbnail.src=(i||"")+"/OrchardCore.Media/Images/drag-thumbnail.png",bus.$on("folderSelected",(function(t){e.selectedFolder=t})),bus.$on("folderDeleted",(function(){e.selectRoot()})),bus.$on("folderAdded",(function(t){e.selectedFolder=t,t.selected=!0})),bus.$on("mediaListMoved",(function(t){e.loadFolder(e.selectedFolder),t&&e.errors.push(t)})),bus.$on("mediaRenamed",(function(t,i,n,a){var o=e.mediaItems.filter((function(e){return e.mediaPath===n}))[0];o.mediaPath=i,o.name=t,o.url=a})),bus.$on("createFolderRequested",(function(t){e.createFolder()})),bus.$on("deleteFolderRequested",(function(t){e.deleteFolder()})),bus.$on("sortChangeRequested",(function(t){e.changeSort(t)})),bus.$on("mediaToggleRequested",(function(t){e.toggleSelectionOfMedia(t)})),bus.$on("renameMediaRequested",(function(t){e.renameMedia(t)})),bus.$on("deleteMediaRequested",(function(t){e.deleteMediaItem(t)})),bus.$on("mediaDragStartRequested",(function(t,i){e.handleDragStart(t,i)})),bus.$on("pagerEvent",(function(t){e.itemsInPage=t,e.selectedMedias=[]})),localStorage.getItem("mediaApplicationPrefs")?e.currentPrefs=JSON.parse(localStorage.getItem("mediaApplicationPrefs")):e.selectedFolder=n},computed:{isHome:function(){return this.selectedFolder==n},parents:function(){var e=[];for(parentFolder=this.selectedFolder;parentFolder&&""!=parentFolder.path;)e.unshift(parentFolder),parentFolder=parentFolder.parent;return e},root:function(){return n},filteredMediaItems:function(){var e=this;e.selectedMedias=[];var t=e.mediaItems.filter((function(t){return t.name.toLowerCase().indexOf(e.mediaFilter.toLowerCase())>-1}));switch(e.sortBy){case"size":t.sort((function(t,i){return e.sortAsc?t.size-i.size:i.size-t.size}));break;case"mime":t.sort((function(t,i){return e.sortAsc?t.mime.toLowerCase().localeCompare(i.mime.toLowerCase()):i.mime.toLowerCase().localeCompare(t.mime.toLowerCase())}));break;case"lastModify":t.sort((function(t,i){return e.sortAsc?t.lastModify-i.lastModify:i.lastModify-t.lastModify}));break;default:t.sort((function(t,i){return e.sortAsc?t.name.toLowerCase().localeCompare(i.name.toLowerCase()):i.name.toLowerCase().localeCompare(t.name.toLowerCase())}))}return t},hiddenCount:function(){return this.mediaItems.length-this.filteredMediaItems.length},thumbSize:function(){return this.smallThumbs?100:240},currentPrefs:{get:function(){return{smallThumbs:this.smallThumbs,selectedFolder:this.selectedFolder,gridView:this.gridView}},set:function(e){e&&(this.smallThumbs=e.smallThumbs,this.selectedFolder=e.selectedFolder,this.gridView=e.gridView)}}},watch:{currentPrefs:function(e){localStorage.setItem("mediaApplicationPrefs",JSON.stringify(e))},selectedFolder:function(e){this.mediaFilter="",this.selectedFolder=e,this.loadFolder(e)}},mounted:function(){this.$refs.rootFolder.toggle()},methods:{uploadUrl:function(){if(!this.selectedFolder)return null;var e=$("#uploadFiles").val();return e+(-1==e.indexOf("?")?"?":"&")+"path="+encodeURIComponent(this.selectedFolder.path)},selectRoot:function(){this.selectedFolder=this.root},loadFolder:function(e){this.errors=[],this.selectedMedias=[];var t=this,i=$("#getMediaItemsUrl").val();console.log(e.path),$.ajax({url:i+(-1==i.indexOf("?")?"?":"&")+"path="+encodeURIComponent(e.path),method:"GET",success:function(e){e.forEach((function(e){e.open=!1})),t.mediaItems=e,t.selectedMedias=[],t.sortBy="",t.sortAsc=!0},error:function(i){console.log("error loading folder:"+e.path),t.selectRoot()}})},selectAll:function(){this.selectedMedias=[];for(var e=0;e-1&&(t.mediaItems.splice(n,1),bus.$emit("mediaDeleted",t.selectedMedias[i]))}t.selectedMedias=[]},error:function(e){console.error(e.responseText)}})}}}))},deleteMediaItem:function(e){var t=this;e&&confirmDialog(_objectSpread(_objectSpread({},$("#deleteMedia").data()),{},{callback:function(i){i&&$.ajax({url:$("#deleteMediaUrl").val()+"?path="+encodeURIComponent(e.mediaPath),method:"POST",data:{__RequestVerificationToken:$("input[name='__RequestVerificationToken']").val()},success:function(i){var n=t.mediaItems&&t.mediaItems.indexOf(e);n>-1&&(t.mediaItems.splice(n,1),bus.$emit("mediaDeleted",e))},error:function(e){console.error(e.responseText)}})}}))},handleDragStart:function(e,t){var i=[];this.selectedMedias.forEach((function(e){i.push(e.name)})),0==this.isMediaSelected(e)&&(i.push(e.name),this.selectedMedias.push(e)),t.dataTransfer.setData("mediaNames",JSON.stringify(i)),t.dataTransfer.setData("sourceFolder",this.selectedFolder.path),t.dataTransfer.setDragImage(this.dragDropThumbnail,10,10),t.dataTransfer.effectAllowed="move"},handleScrollWhileDrag:function(e){e.clientY<150&&window.scrollBy(0,-10),e.clientY>window.innerHeight-100&&window.scrollBy(0,10)},changeSort:function(e){this.sortBy==e?this.sortAsc=!this.sortAsc:(this.sortAsc=!0,this.sortBy=e)}}}),$("#create-folder-name").keypress((function(e){if(13==e.which)return $("#modalFooterOk").click(),!1})),$("#modalFooterOk").on("click",(function(e){var t=$("#create-folder-name").val();""!==t&&$.ajax({url:$("#createFolderUrl").val()+"?path="+encodeURIComponent(mediaApp.selectedFolder.path)+"&name="+encodeURIComponent(t),method:"POST",data:{__RequestVerificationToken:$("input[name='__RequestVerificationToken']").val()},success:function(e){bus.$emit("addFolder",mediaApp.selectedFolder,e),bootstrap.Modal.getOrCreateInstance($("#createFolderModal")).hide()},error:function(e){$("#createFolderModal-errors").empty();var t=JSON.parse(e.responseText).value;$('').text(t).appendTo($("#createFolderModal-errors"))}})})),$("#renameMediaModalFooterOk").on("click",(function(e){var t=$("#new-item-name").val(),i=$("#old-item-name").val();if(""!==t){var n=mediaApp.selectedFolder.path+"/";"/"===n&&(n="");var a=n+t,o=n+i;if(a.toLowerCase()!==o.toLowerCase())$.ajax({url:$("#renameMediaUrl").val()+"?oldPath="+encodeURIComponent(o)+"&newPath="+encodeURIComponent(a),method:"POST",data:{__RequestVerificationToken:$("input[name='__RequestVerificationToken']").val()},success:function(e){bootstrap.Modal.getOrCreateInstance($("#renameMediaModal")).hide(),bus.$emit("mediaRenamed",t,a,o,e.newUrl)},error:function(e){$("#renameMediaModal-errors").empty();var t=JSON.parse(e.responseText).value;$('').text(t).appendTo($("#renameMediaModal-errors"))}});else bootstrap.Modal.getOrCreateInstance($("#renameMediaModal")).hide()}})),e&&(document.getElementById("mediaApp").style.display=""),$(document).trigger("mediaApp:ready")},error:function(e){console.error(e.responseText)}}))}function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function ownKeys(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function _objectSpread(e){for(var t=1;t\n \n
      \n \n \n
    \n \n '),props:{model:Object,selectedInMediaApp:Object,level:Number},data:function(){return{open:!1,children:null,parent:null,isHovered:!1,padding:0}},computed:{empty:function(){return!this.children||0==this.children.length},isSelected:function(){return this.selectedInMediaApp.name==this.model.name&&this.selectedInMediaApp.path==this.model.path},isRoot:function(){return""===this.model.path}},mounted:function(){0==this.isRoot&&this.isAncestorOfSelectedFolder()&&this.toggle(),this.padding=this.level<3?16:16+8*this.level},created:function(){var e=this;bus.$on("deleteFolder",(function(t){if(e.children){var i=e.children&&e.children.indexOf(t);i>-1&&(e.children.splice(i,1),bus.$emit("folderDeleted"))}})),bus.$on("addFolder",(function(t,i){e.model==t&&(null!==e.children&&e.children.push(i),i.parent=e.model,bus.$emit("folderAdded",i))}))},methods:{isAncestorOfSelectedFolder:function(){for(parentFolder=mediaApp.selectedFolder;parentFolder;){if(parentFolder.path==this.model.path)return!0;parentFolder=parentFolder.parent}return!1},toggle:function(){this.open=!this.open,this.open&&!this.children&&this.loadChildren()},select:function(){bus.$emit("folderSelected",this.model),this.loadChildren()},createFolder:function(){bus.$emit("createFolderRequested")},deleteFolder:function(){bus.$emit("deleteFolderRequested")},loadChildren:function(){var e=this;0==this.open&&(this.open=!0),$.ajax({url:$("#getFoldersUrl").val()+"?path="+encodeURIComponent(e.model.path),method:"GET",success:function(t){e.children=t,e.children.forEach((function(t){t.parent=e.model}))},error:function(e){emtpy=!1,console.error(e.responseText)}})},handleDragOver:function(e){this.isHovered=!0},handleDragLeave:function(e){this.isHovered=!1},moveMediaToFolder:function(e,t){this.isHovered=!1;var i=JSON.parse(t.dataTransfer.getData("mediaNames"));if(!(i.length<1)){var n=t.dataTransfer.getData("sourceFolder"),a=e.path;""===n&&(n="root"),""===a&&(a="root"),n!==a?confirmDialog(_objectSpread(_objectSpread({},$("#moveMedia").data()),{},{callback:function(e){e&&$.ajax({url:$("#moveMediaListUrl").val(),method:"POST",data:{__RequestVerificationToken:$("input[name='__RequestVerificationToken']").val(),mediaNames:i,sourceFolder:n,targetFolder:a},success:function(){bus.$emit("mediaListMoved")},error:function(e){console.error(e.responseText),bus.$emit("mediaListMoved",e.responseText)}})}})):alert($("#sameFolderMessage").val())}}}});var faIcons={image:"fa-regular fa-image",pdf:"fa-regular fa-file-pdf",word:"fa-regular fa-file-word",powerpoint:"fa-regular fa-file-powerpoint",excel:"fa-regular fa-file-excel",csv:"fa-regular fa-file",audio:"fa-regular fa-file-audio",video:"fa-regular fa-file-video",archive:"fa-regular fa-file-zipper",code:"fa-regular fa-file-code",text:"fa-regular fa-file-lines",file:"fa-regular fa-file"},faThumbnails={gif:faIcons.image,jpeg:faIcons.image,jpg:faIcons.image,png:faIcons.image,pdf:faIcons.pdf,doc:faIcons.word,docx:faIcons.word,ppt:faIcons.powerpoint,pptx:faIcons.powerpoint,xls:faIcons.excel,xlsx:faIcons.excel,csv:faIcons.csv,aac:faIcons.audio,mp3:faIcons.audio,ogg:faIcons.audio,avi:faIcons.video,flv:faIcons.video,mkv:faIcons.video,mp4:faIcons.video,webm:faIcons.video,gz:faIcons.archive,zip:faIcons.archive,css:faIcons.code,html:faIcons.code,js:faIcons.code,txt:faIcons.text};function getClassNameForExtension(e){return faThumbnails[e.toLowerCase()]||faIcons.file}function getExtensionForFilename(e){return e.slice(2+(e.lastIndexOf(".")-1>>>0))}function getClassNameForFilename(e){return getClassNameForExtension(getExtensionForFilename(e))}function initializeAttachedMediaField(e,t,i,n,a,o,r,s,l){var d,c=$(document.getElementById($(e).data("for"))).data("init"),u=$(e),m=u.attr("id");mediaFieldApps.push(d=new Vue({el:u.get(0),data:{mediaItems:[],selectedMedia:null,smallThumbs:!1,idPrefix:m,initialized:!1,allowMediaText:o,backupMediaText:"",allowAnchors:r,backupAnchor:null,mediaTextmodal:null,anchoringModal:null},created:function(){this.currentPrefs=JSON.parse(localStorage.getItem("mediaFieldPrefs"))},computed:{paths:{get:function(){var e=[];return this.initialized?(this.mediaItems.forEach((function(t){"not-found"!==t.mediaPath&&e.push({path:t.mediaPath,isRemoved:t.isRemoved,isNew:t.isNew,mediaText:t.mediaText,anchor:t.anchor,attachedFileName:t.attachedFileName})})),JSON.stringify(e)):JSON.stringify(c)},set:function(e){var t=this,i=e||[],a=$.Deferred(),o=[],r=0;i.forEach((function(e,i){o.push({name:" "+e.path,mime:"",mediaPath:"",anchor:e.anchor,attachedFileName:e.attachedFileName}),promise=$.when(a).done((function(){$.ajax({url:n+"?path="+encodeURIComponent(e.path),method:"GET",success:function(n){n.vuekey=n.name+i.toString(),n.mediaText=e.mediaText,n.anchor=e.anchor,n.attachedFileName=e.attachedFileName,o.splice(i,1,n),o.length===++r&&(o.forEach((function(e){t.mediaItems.push(e)})),t.initialized=!0)},error:function(n){console.log(JSON.stringify(n)),o.splice(i,1,{name:e.path,mime:"",mediaPath:"not-found",mediaText:"",anchor:{x:.5,y:.5},attachedFileName:e.attachedFileName}),o.length===++r&&(o.forEach((function(e){t.mediaItems.push(e)})),t.initialized=!0)}})}))})),a.resolve()}},fileSize:function(){return Math.round(this.selectedMedia.size/1024)},canAddMedia:function(){for(var e=[],t=0;t0&&a},thumbSize:function(){return this.smallThumbs?120:240},currentPrefs:{get:function(){return{smallThumbs:this.smallThumbs}},set:function(e){e&&(this.smallThumbs=e.smallThumbs)}}},mounted:function(){var e=this;e.paths=c,e.$on("selectAndDeleteMediaRequested",(function(t){e.selectAndDeleteMedia(t)})),e.$on("selectMediaRequested",(function(t){e.selectMedia(t)}));var n="#"+t,o=u.attr("id"),r=randomUUID();$(n).fileupload({limitConcurrentUploads:20,dropZone:$("#"+o),dataType:"json",url:i,maxChunkSize:l,add:function(t,i){var n,a=i.files.length;for(n=0;n0)for(var o=0;o1&&!1===a?(alert($("#onlyOneItemMessage").val()),d.mediaItems.push(i[0]),d.initialized=!0):(d.mediaItems=d.mediaItems.concat(i),d.initialized=!0)):alert(n)},error:function(e,t,i){console.log("Error on upload."),console.log(e),console.log(t),console.log(i)}}).on("fileuploadchunkbeforesend",(function(e,t){var i=t.files[0];t.blob=new File([t.blob],i.name,{type:i.type,lastModified:i.lastModified})}))},methods:{selectMedia:function(e){this.selectedMedia=e},getUniqueId:function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))},removeSelected:function(e){if(this.selectedMedia){var t=this.mediaItems&&this.mediaItems.indexOf(this.selectedMedia);t>-1&&(this.mediaItems[t].isRemoved=!0,this.mediaItems.splice(t,1))}else 1===this.mediaItems.length&&(this.mediaItems[t].isRemoved=!0,this.mediaItems.splice(0,1));this.selectedMedia=null},showMediaTextModal:function(e){this.mediaTextModal=new bootstrap.Modal(this.$refs.mediaTextModal),this.mediaTextModal.show(),this.backupMediaText=this.selectedMedia.mediaText},cancelMediaTextModal:function(e){this.mediaTextModal.hide(),this.selectedMedia.mediaText=this.backupMediaText},showAnchorModal:function(e){this.anchoringModal=new bootstrap.Modal(this.$refs.anchoringModal),this.anchoringModal.show(),this.selectedMedia.anchor={x:this.selectedMedia.anchor.x,y:this.selectedMedia.anchor.y},this.backupAnchor=this.selectedMedia.anchor},cancelAnchoringModal:function(e){this.anchoringModal.hide(),this.selectedMedia.anchor=this.backupAnchor},resetAnchor:function(e){this.selectedMedia.anchor={x:.5,y:.5}},onAnchorDrop:function(e){var t=this.$refs.anchorImage;this.selectedMedia.anchor={x:e.offsetX/t.clientWidth,y:e.offsetY/t.clientHeight}},anchorLeft:function(){if(this.$refs.anchorImage&&this.$refs.modalBody&&this.selectedMedia){var e=(this.$refs.modalBody.clientWidth-this.$refs.anchorImage.clientWidth)/2,t=this.selectedMedia.anchor.x*this.$refs.anchorImage.clientWidth+e;return t<17?t=17:t-=8,t+"px"}return"0"},anchorTop:function(){if(this.$refs.anchorImage&&this.selectedMedia){var e=this.selectedMedia.anchor.y*this.$refs.anchorImage.clientHeight;return e<15?e=15:e+=5,e+"px"}return"0"},setAnchor:function(e){var t=this.$refs.anchorImage;this.selectedMedia.anchor={x:e.offsetX/t.clientWidth,y:e.offsetY/t.clientHeight}},addMediaFiles:function(e){e.length>1&&!1===a?(alert($("#onlyOneItemMessage").val()),d.mediaItems.push(e[0]),d.initialized=!0):(d.mediaItems=d.mediaItems.concat(e),d.initialized=!0)},selectAndDeleteMedia:function(e){var t=this;t.selectedMedia=e,setTimeout((function(){t.removeSelected()}),100)}},watch:{mediaItems:{deep:!0,handler:function(){setTimeout((function(){$(document).trigger("contentpreview:render")}),100)}},currentPrefs:function(e){localStorage.setItem("mediaFieldPrefs",JSON.stringify(e))}}}))}function initializeMediaField(e,t,i,n,a,o){if(null!==e){var r,s=$(document.getElementById($(e).data("for"))).data("init"),l=$(e),d=l.attr("id");t.addEventListener("hidden.bs.modal",(function(e){$("#mediaApp").appendTo("body"),$("#mediaApp").hide()})),mediaFieldApps.push(r=new Vue({el:l.get(0),data:{mediaItems:[],selectedMedia:null,smallThumbs:!1,idPrefix:d,initialized:!1,allowMediaText:a,backupMediaText:"",allowAnchors:o,backupAnchor:null,mediaTextModal:null,anchoringModal:null},created:function(){this.currentPrefs=JSON.parse(localStorage.getItem("mediaFieldPrefs"))},computed:{paths:{get:function(){var e=[];return this.initialized?(this.mediaItems.forEach((function(t){"not-found"!==t.mediaPath&&e.push({path:t.mediaPath,mediaText:t.mediaText,anchor:t.anchor})})),JSON.stringify(e)):JSON.stringify(s)},set:function(e){var t=this,n=e||[],a=$.Deferred(),o=[],r=0;n.forEach((function(e,n){o.push({name:" "+e.path,mime:"",mediaPath:""}),promise=$.when(a).done((function(){$.ajax({url:i+"?path="+encodeURIComponent(e.path),method:"GET",success:function(i){i.vuekey=i.name+n.toString(),i.mediaText=e.mediaText,i.anchor=e.anchor,o.splice(n,1,i),o.length===++r&&(o.forEach((function(e){t.mediaItems.push(e)})),t.initialized=!0)},error:function(i){console.log(i),o.splice(n,1,{name:e.path,mime:"",mediaPath:"not-found",mediaText:"",anchor:{x:0,y:0}}),o.length===++r&&(o.forEach((function(e){t.mediaItems.push(e)})),t.initialized=!0)}})}))})),a.resolve()}},fileSize:function(){return Math.round(this.selectedMedia.size/1024)},canAddMedia:function(){return 0===this.mediaItems.length||this.mediaItems.length>0&&n},thumbSize:function(){return this.smallThumbs?120:240},currentPrefs:{get:function(){return{smallThumbs:this.smallThumbs}},set:function(e){e&&(this.smallThumbs=e.smallThumbs)}}},mounted:function(){var e=this;e.paths=s,e.$on("selectAndDeleteMediaRequested",(function(t){e.selectAndDeleteMedia(t)})),e.$on("selectMediaRequested",(function(t){e.selectMedia(t)})),e.$on("filesUploaded",(function(t){e.addMediaFiles(t)}))},methods:{selectMedia:function(e){this.selectedMedia=e},showModal:function(e){var i=this;if(i.canAddMedia){$("#mediaApp").appendTo($(t).find(".modal-body")),$("#mediaApp").show();var n=new bootstrap.Modal(t);n.show(),$(t).find(".mediaFieldSelectButton").off("click").on("click",(function(e){return i.addMediaFiles(mediaApp.selectedMedias),mediaApp.selectedMedias=[],n.hide(),!0}))}},showMediaTextModal:function(e){this.mediaTextModal=new bootstrap.Modal(this.$refs.mediaTextModal),this.mediaTextModal.show(),this.backupMediaText=this.selectedMedia.mediaText},cancelMediaTextModal:function(e){this.mediaTextModal.hide(),this.selectedMedia.mediaText=this.backupMediaText},showAnchorModal:function(e){this.anchoringModal=new bootstrap.Modal(this.$refs.anchoringModal),this.anchoringModal.show(),this.selectedMedia.anchor={x:this.selectedMedia.anchor.x,y:this.selectedMedia.anchor.y},this.backupAnchor=this.selectedMedia.anchor},cancelAnchoringModal:function(e){this.anchoringModal.hide(),this.selectedMedia.anchor=this.backupAnchor},resetAnchor:function(e){this.selectedMedia.anchor={x:.5,y:.5}},onAnchorDrop:function(e){var t=this.$refs.anchorImage;this.selectedMedia.anchor={x:e.offsetX/t.clientWidth,y:e.offsetY/t.clientHeight}},anchorLeft:function(){if(this.$refs.anchorImage&&this.$refs.modalBody&&this.selectedMedia){var e=(this.$refs.modalBody.clientWidth-this.$refs.anchorImage.clientWidth)/2,t=this.selectedMedia.anchor.x*this.$refs.anchorImage.clientWidth+e,i=Math.round(this.$refs.modalBody.querySelector(".icon-media-anchor").clientWidth);return Number.isInteger(i)&&(t-=i/2),t+"px"}return"0"},anchorTop:function(){return this.$refs.anchorImage&&this.selectedMedia?this.selectedMedia.anchor.y*this.$refs.anchorImage.clientHeight+"px":"0"},setAnchor:function(e){var t=this.$refs.anchorImage;this.selectedMedia.anchor={x:e.offsetX/t.clientWidth,y:e.offsetY/t.clientHeight}},addMediaFiles:function(e){e.length>1&&!1===n?(alert($("#onlyOneItemMessage").val()),r.mediaItems.push(e[0]),r.initialized=!0):(r.mediaItems=r.mediaItems.concat(e),r.initialized=!0)},removeSelected:function(e){if(this.selectedMedia){var t=this.mediaItems&&this.mediaItems.indexOf(this.selectedMedia);t>-1&&this.mediaItems.splice(t,1)}else 1===this.mediaItems.length&&this.mediaItems.splice(0,1);this.selectedMedia=null},selectAndDeleteMedia:function(e){var t=this;t.selectedMedia=e,setTimeout((function(){t.removeSelected()}),100)}},watch:{mediaItems:{deep:!0,handler:function(){setTimeout((function(){$(document).trigger("contentpreview:render")}),100)}},currentPrefs:function(e){localStorage.setItem("mediaFieldPrefs",JSON.stringify(e))}}}))}}Vue.component("media-items-grid",{template:'\n
      \n
    1. \n
      \n \n \n
      \n
      \n \n \n \n {{ media.name }}\n
      \n
    2. \n
    \n ',data:function(){return{T:{}}},props:{filteredMediaItems:Array,selectedMedias:Array,thumbSize:Number},created:function(){this.T.editButton=$("#t-edit-button").val(),this.T.deleteButton=$("#t-delete-button").val()},methods:{isMediaSelected:function(e){return this.selectedMedias.some((function(t,i,n){return t.url.toLowerCase()===e.url.toLowerCase()}))},buildMediaUrl:function(e,t){return e+(-1==e.indexOf("?")?"?":"&")+"width="+t+"&height="+t},toggleSelectionOfMedia:function(e){bus.$emit("mediaToggleRequested",e)},renameMedia:function(e){bus.$emit("renameMediaRequested",e)},deleteMedia:function(e){bus.$emit("deleteMediaRequested",e)},dragStart:function(e,t){bus.$emit("mediaDragStartRequested",e,t)},getfontAwesomeClassNameForFileName:function(e,t){return getClassNameForFilename(e)+" "+t}}}),Vue.component("media-items-table",{template:'\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
    {{ T.imageHeader }}\n {{ T.nameHeader }}\n \n \n {{ T.lastModifyHeader }} \n \n \n \n {{ T.sizeHeader }}\n \n \n \n \n {{ T.typeHeader }}\n \n \n
    \n
    \n \n \n
    \n
    \n \n \n
    {{ printDateTime(media.lastModify) }}
    \n
    \n
    {{ isNaN(media.size)? 0 : Math.round(media.size / 1024) }} KB
    \n
    \n
    {{ media.mime }}
    \n
    \n ',data:function(){return{T:{}}},props:{sortBy:String,sortAsc:Boolean,filteredMediaItems:Array,selectedMedias:Array,thumbSize:Number},created:function(){var e=this;e.T.imageHeader=$("#t-image-header").val(),e.T.nameHeader=$("#t-name-header").val(),e.T.lastModifyHeader=$("#t-lastModify-header").val(),e.T.sizeHeader=$("#t-size-header").val(),e.T.typeHeader=$("#t-type-header").val(),e.T.editButton=$("#t-edit-button").val(),e.T.deleteButton=$("#t-delete-button").val(),e.T.viewButton=$("#t-view-button").val()},methods:{isMediaSelected:function(e){return this.selectedMedias.some((function(t,i,n){return t.url.toLowerCase()===e.url.toLowerCase()}))},buildMediaUrl:function(e,t){return e+(-1==e.indexOf("?")?"?":"&")+"width="+t+"&height="+t},changeSort:function(e){bus.$emit("sortChangeRequested",e)},toggleSelectionOfMedia:function(e){bus.$emit("mediaToggleRequested",e)},renameMedia:function(e){bus.$emit("renameMediaRequested",e)},deleteMedia:function(e){bus.$emit("deleteMediaRequested",e)},dragStart:function(e,t){bus.$emit("mediaDragStartRequested",e,t)},printDateTime:function(e){return new Date(e).toLocaleString()},getfontAwesomeClassNameForFileName:function(e,t){return getClassNameForFilename(e)+" "+t}}}),Vue.component("pager",{template:'\n
    \n \n \n
    \n ',props:{sourceItems:Array},data:function(){return{pageSize:10,pageSizeOptions:[10,30,50,100],current:0,T:{}}},created:function(){var e=this;e.T.pagerFirstButton=$("#t-pager-first-button").val(),e.T.pagerPreviousButton=$("#t-pager-previous-button").val(),e.T.pagerNextButton=$("#t-pager-next-button").val(),e.T.pagerLastButton=$("#t-pager-last-button").val(),e.T.pagerPageSizeLabel=$("#t-pager-page-size-label").val(),e.T.pagerPageLabel=$("#t-pager-page-label").val(),e.T.pagerTotalLabel=$("#t-pager-total-label").val()},methods:{next:function(){this.current=this.current+1},previous:function(){this.current=this.current-1},goFirst:function(){this.current=0},goLast:function(){this.current=this.totalPages-1},goTo:function(e){this.current=e}},computed:{total:function(){return this.sourceItems?this.sourceItems.length:0},totalPages:function(){var e=Math.ceil(this.total/this.pageSize);return e>0?e:1},isLastPage:function(){return this.current+1>=this.totalPages},isFirstPage:function(){return 0===this.current},canDoNext:function(){return!this.isLastPage},canDoPrev:function(){return!this.isFirstPage},canDoFirst:function(){return!this.isFirstPage},canDoLast:function(){return!this.isLastPage},itemsInCurrentPage:function(){var e=this.pageSize*this.current,t=e+this.pageSize,i=this.sourceItems.slice(e,t);return bus.$emit("pagerEvent",i),i},pageLinks:function(){var e=[];e.push(this.current+1);var t=this.current>0?this.current:-1;e.unshift(t);var i=this.current>1?this.current-1:-1;e.unshift(i);var n=this.totalPages-this.current>1?this.current+2:-1;e.push(n);var a=this.totalPages-this.current>2?this.current+3:-1;return e.push(a),e}},watch:{sourceItems:function(){this.current=0},pageSize:function(){this.current=0}}}),Vue.component("sortIndicator",{template:'\n
    \n \n \n
    \n ',props:{colname:String,selectedcolname:String,asc:Boolean},computed:{isActive:function(){return this.colname.toLowerCase()==this.selectedcolname.toLowerCase()}}});var mediaFieldApps=[];Vue.component("mediaFieldThumbsContainer",{template:'
    {{T.noImages}}
  • {{ media.isNew ? media.name.substr(36) : media.name }}
    {{ T.mediaNotFound }} {{ T.discardWarning }}
    {{ media.name }}
  • ',data:function(){return{T:{}}},props:{mediaItems:Array,selectedMedia:Object,thumbSize:Number,idPrefix:String},created:function(){var e=this;e.T.mediaNotFound=$("#t-media-not-found").val(),e.T.discardWarning=$("#t-discard-warning").val(),e.T.noImages=$("#t-no-images").val()},methods:{selectAndDeleteMedia:function(e){this.$parent.$emit("selectAndDeleteMediaRequested",e)},selectMedia:function(e){this.$parent.$emit("selectMediaRequested",e)},buildMediaUrl:function(e,t){return e+(-1==e.indexOf("?")?"?":"&")+"width="+t+"&height="+t},getfontAwesomeClassNameForFileName:function(e,t){return getClassNameForFilename(e)+" "+t}}}),Vue.component("upload",{template:'

    {{ model.name }}

    Error: {{ model.errorMessage }}
    ',props:{model:Object,uploadInputId:String},mounted:function(){var e,t=this,i=document.getElementById(null!==(e=t.uploadInputId)&&void 0!==e?e:"fileupload");$(i).bind("fileuploadprogress",(function(e,i){i.files[0].name===t.model.name&&(t.model.percentage=parseInt(i.loaded/i.total*100,10))})),$(i).bind("fileuploaddone",(function(e,i){i.files[0].name===t.model.name&&(i.result.files[0].error?t.handleFailure(i.files[0].name,i.result.files[0].error):bus.$emit("removalRequest",t.model))})),$(i).bind("fileuploadfail",(function(e,i){i.files[0].name===t.model.name&&t.handleFailure(i.files[0].name,$("#t-error").val())}))},methods:{handleFailure:function(e,t){e===this.model.name&&(this.model.errorMessage=t,bus.$emit("ErrorOnUpload",this.model))},dismissWarning:function(){bus.$emit("removalRequest",this.model)}}}),Vue.component("uploadList",{template:'
    {{ T.uploads }} (Pending: {{ pendingCount }}) ( {{ T.errors }}: {{ errorCount }} / {{ T.clearErrors }} )
    ',data:function(){return{files:[],T:{},expanded:!1,pendingCount:0,errorCount:0}},props:{uploadInputId:String},created:function(){var e=this;e.T.uploads=$("#t-uploads").val(),e.T.errors=$("#t-errors").val(),e.T.clearErrors=$("#t-clear-errors").val()},computed:{fileCount:function(){return this.files.length}},mounted:function(){var e,t=this,i=document.getElementById(null!==(e=t.uploadInputId)&&void 0!==e?e:"fileupload");$(i).bind("fileuploadadd",(function(e,i){i.files&&i.files.forEach((function(e){t.files.some((function(t){return t.name==e.name}))?console.error("A file with the same name is already on the queue:"+e.name):t.files.push({name:e.name,percentage:0,errorMessage:""})}))})),bus.$on("removalRequest",(function(e){t.files.forEach((function(t,i,n){t.name==e.name&&n.splice(i,1)}))})),bus.$on("ErrorOnUpload",(function(e){t.updateCount()}))},methods:{updateCount:function(){this.errorCount=this.files.filter((function(e){return""!=e.errorMessage})).length,this.pendingCount=this.files.length-this.errorCount,this.files.length<1&&(this.expanded=!1)},clearErrors:function(){this.files=this.files.filter((function(e){return""==e.errorMessage}))}},watch:{files:function(){this.updateCount()}}}); diff --git a/src/OrchardCore.Modules/OrchardCore.Microsoft.Authentication/Views/MicrosoftAccountSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Microsoft.Authentication/Views/MicrosoftAccountSettings.Edit.cshtml index 20febe3b977..898bf0d7003 100644 --- a/src/OrchardCore.Modules/OrchardCore.Microsoft.Authentication/Views/MicrosoftAccountSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.Microsoft.Authentication/Views/MicrosoftAccountSettings.Edit.cshtml @@ -1,8 +1,8 @@ @using OrchardCore.Microsoft.Authentication.ViewModels @model MicrosoftAccountSettingsViewModel -

    - @T["The current tenant will be reloaded when the settings are saved."] +

    diff --git a/src/OrchardCore.Modules/OrchardCore.Microsoft.Authentication/Views/MicrosoftEntraIDSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.Microsoft.Authentication/Views/MicrosoftEntraIDSettings.Edit.cshtml index d120ae5ded6..971b64c9629 100644 --- a/src/OrchardCore.Modules/OrchardCore.Microsoft.Authentication/Views/MicrosoftEntraIDSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.Microsoft.Authentication/Views/MicrosoftEntraIDSettings.Edit.cshtml @@ -1,8 +1,8 @@ @using OrchardCore.Microsoft.Authentication.ViewModels @model AzureADSettingsViewModel -

    - @T["The current tenant will be reloaded when the settings are saved."] +

    diff --git a/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdClientSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdClientSettingsDisplayDriver.cs index 7dbfeab782d..acc02e34764 100644 --- a/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdClientSettingsDisplayDriver.cs +++ b/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdClientSettingsDisplayDriver.cs @@ -12,6 +12,7 @@ using OrchardCore.DisplayManagement.Handlers; using OrchardCore.DisplayManagement.Views; using OrchardCore.Environment.Shell; +using OrchardCore.Modules; using OrchardCore.OpenId.Configuration; using OrchardCore.OpenId.Services; using OrchardCore.OpenId.Settings; @@ -53,12 +54,19 @@ public OpenIdClientSettingsDisplayDriver( public override async Task EditAsync(OpenIdClientSettings settings, BuildEditorContext context) { + if (!context.GroupId.EqualsOrdinalIgnoreCase(SettingsGroupId)) + { + return null; + } + var user = _httpContextAccessor.HttpContext?.User; if (!await _authorizationService.AuthorizeAsync(user, Permissions.ManageClientSettings)) { return null; } + context.Shape.Metadata.Wrappers.Add("Settings_Wrapper__Reload"); + return Initialize("OpenIdClientSettings_Edit", model => { model.DisplayName = settings.DisplayName; @@ -109,7 +117,7 @@ public override async Task UpdateAsync(OpenIdClientSettings sett return null; } - if (context.GroupId == SettingsGroupId) + if (context.GroupId.Equals(SettingsGroupId, StringComparison.OrdinalIgnoreCase)) { var previousClientSecret = settings.ClientSecret; var model = new OpenIdClientSettingsViewModel(); diff --git a/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdServerSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdServerSettingsDisplayDriver.cs index 1d58af902c8..69e3ed27e56 100644 --- a/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdServerSettingsDisplayDriver.cs +++ b/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdServerSettingsDisplayDriver.cs @@ -18,7 +18,10 @@ public OpenIdServerSettingsDisplayDriver(IOpenIdServerService serverService) => _serverService = serverService; public override Task EditAsync(OpenIdServerSettings settings, BuildEditorContext context) - => Task.FromResult(Initialize("OpenIdServerSettings_Edit", async model => + { + context.Shape.Metadata.Wrappers.Add("Settings_Wrapper__Reload"); + + return Task.FromResult(Initialize("OpenIdServerSettings_Edit", async model => { model.AccessTokenFormat = settings.AccessTokenFormat; model.Authority = settings.Authority?.AbsoluteUri; @@ -67,6 +70,7 @@ public override Task EditAsync(OpenIdServerSettings settings, Bu }); } }).Location("Content:2")); + } public override async Task UpdateAsync(OpenIdServerSettings settings, UpdateEditorContext context) { diff --git a/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdValidationSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdValidationSettingsDisplayDriver.cs index 1843a661ebb..585f56062ed 100644 --- a/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdValidationSettingsDisplayDriver.cs +++ b/src/OrchardCore.Modules/OrchardCore.OpenId/Drivers/OpenIdValidationSettingsDisplayDriver.cs @@ -20,7 +20,10 @@ public OpenIdValidationSettingsDisplayDriver(IShellHost shellHost) => _shellHost = shellHost; public override Task EditAsync(OpenIdValidationSettings settings, BuildEditorContext context) - => Task.FromResult(Initialize("OpenIdValidationSettings_Edit", async model => + { + context.Shape.Metadata.Wrappers.Add("Settings_Wrapper__Reload"); + + return Task.FromResult(Initialize("OpenIdValidationSettings_Edit", async model => { model.Authority = settings.Authority?.AbsoluteUri; model.MetadataAddress = settings.MetadataAddress?.AbsoluteUri; @@ -47,6 +50,7 @@ await shellScope.UsingAsync(scope => model.AvailableTenants = availableTenants; }).Location("Content:2")); + } public override async Task UpdateAsync(OpenIdValidationSettings settings, UpdateEditorContext context) { diff --git a/src/OrchardCore.Modules/OrchardCore.OpenId/Manifest.cs b/src/OrchardCore.Modules/OrchardCore.OpenId/Manifest.cs index 8a014aedf44..6c1ca2cf19c 100644 --- a/src/OrchardCore.Modules/OrchardCore.OpenId/Manifest.cs +++ b/src/OrchardCore.Modules/OrchardCore.OpenId/Manifest.cs @@ -42,7 +42,7 @@ Id = OpenIdConstants.Features.Server, Name = "OpenID Authorization Server", Category = "OpenID Connect", - Description = "Enables authentication of external applications using the OpenID Connect/OAuth 2.0 standards.", + Description = "Enables authentication of external applications using the OpenID Connect/OAuth 2.0 standards. In order to reach the ApiController endpoints within OrchardCore, it is necessary to activate the 'OpenID Token Validation' feature for authentication validation.", Dependencies = [ OpenIdConstants.Features.Core, diff --git a/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdClientSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdClientSettings.Edit.cshtml index 6cb5a42a2d4..632341ea4cf 100644 --- a/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdClientSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdClientSettings.Edit.cshtml @@ -2,9 +2,6 @@ @using Microsoft.IdentityModel.Protocols.OpenIdConnect @model OpenIdClientSettingsViewModel -

    @T["The current tenant will be reloaded when the settings are saved."]

    - - @@ -224,7 +221,7 @@
    diff --git a/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdServerSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdServerSettings.Edit.cshtml index a27208da67c..2ce255e389e 100644 --- a/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdServerSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdServerSettings.Edit.cshtml @@ -3,9 +3,8 @@ @using System.Security.Cryptography.X509Certificates @model OpenIdServerSettingsViewModel -

    @T["The current tenant will be reloaded when the settings are saved."]

    -

    @T["Endpoints"]

    +
    diff --git a/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdValidationSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdValidationSettings.Edit.cshtml index a27025d3100..d1bf40d588d 100644 --- a/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdValidationSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.OpenId/Views/OpenIdValidationSettings.Edit.cshtml @@ -1,8 +1,6 @@ @using OrchardCore.OpenId.ViewModels @model OpenIdValidationSettingsViewModel -

    @T["The current tenant will be reloaded when the settings are saved."]

    -

    @T["To be able to validate tokens issued by a separate tenant, " + "you must register a custom scope in the server options " + diff --git a/src/OrchardCore.Modules/OrchardCore.Placements/Deployment/PlacementsDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.Placements/Deployment/PlacementsDeploymentSource.cs index be178f4910b..426f0cf1dc7 100644 --- a/src/OrchardCore.Modules/OrchardCore.Placements/Deployment/PlacementsDeploymentSource.cs +++ b/src/OrchardCore.Modules/OrchardCore.Placements/Deployment/PlacementsDeploymentSource.cs @@ -3,6 +3,7 @@ using System.Threading.Tasks; using Microsoft.Extensions.Options; using OrchardCore.Deployment; +using OrchardCore.Json; using OrchardCore.Placements.Services; namespace OrchardCore.Placements.Deployment @@ -14,10 +15,10 @@ public class PlacementsDeploymentSource : IDeploymentSource public PlacementsDeploymentSource( PlacementsManager placementsManager, - IOptions jsonSerializerOptions) + IOptions jsonSerializerOptions) { _placementsManager = placementsManager; - _jsonSerializerOptions = jsonSerializerOptions.Value; + _jsonSerializerOptions = jsonSerializerOptions.Value.SerializerOptions; } public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result) diff --git a/src/OrchardCore.Modules/OrchardCore.Queries/Deployment/AllQueriesDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.Queries/Deployment/AllQueriesDeploymentSource.cs index 7ecdc9e65a8..ab56875db17 100644 --- a/src/OrchardCore.Modules/OrchardCore.Queries/Deployment/AllQueriesDeploymentSource.cs +++ b/src/OrchardCore.Modules/OrchardCore.Queries/Deployment/AllQueriesDeploymentSource.cs @@ -3,6 +3,7 @@ using System.Threading.Tasks; using Microsoft.Extensions.Options; using OrchardCore.Deployment; +using OrchardCore.Json; namespace OrchardCore.Queries.Deployment { @@ -13,10 +14,10 @@ public class AllQueriesDeploymentSource : IDeploymentSource public AllQueriesDeploymentSource( IQueryManager queryManager, - IOptions jsonSerializerOptions) + IOptions jsonSerializerOptions) { _queryManager = queryManager; - _jsonSerializerOptions = jsonSerializerOptions.Value; + _jsonSerializerOptions = jsonSerializerOptions.Value.SerializerOptions; } public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result) diff --git a/src/OrchardCore.Modules/OrchardCore.Queries/Recipes/QueryStep.cs b/src/OrchardCore.Modules/OrchardCore.Queries/Recipes/QueryStep.cs index e46b2baaf17..026f9a88bbd 100644 --- a/src/OrchardCore.Modules/OrchardCore.Queries/Recipes/QueryStep.cs +++ b/src/OrchardCore.Modules/OrchardCore.Queries/Recipes/QueryStep.cs @@ -6,6 +6,7 @@ using System.Threading.Tasks; using Microsoft.Extensions.Logging; using Microsoft.Extensions.Options; +using OrchardCore.Json; using OrchardCore.Recipes.Models; using OrchardCore.Recipes.Services; @@ -24,12 +25,12 @@ public class QueryStep : IRecipeStepHandler public QueryStep( IQueryManager queryManager, IEnumerable querySources, - IOptions jsonSerializerOptions, + IOptions jsonSerializerOptions, ILogger logger) { _queryManager = queryManager; _querySources = querySources; - _jsonSerializerOptions = jsonSerializerOptions.Value; + _jsonSerializerOptions = jsonSerializerOptions.Value.SerializerOptions; _logger = logger; } diff --git a/src/OrchardCore.Modules/OrchardCore.Queries/Sql/SqlQuerySource.cs b/src/OrchardCore.Modules/OrchardCore.Queries/Sql/SqlQuerySource.cs index dac4c8d7120..741b2cdc392 100644 --- a/src/OrchardCore.Modules/OrchardCore.Queries/Sql/SqlQuerySource.cs +++ b/src/OrchardCore.Modules/OrchardCore.Queries/Sql/SqlQuerySource.cs @@ -10,6 +10,7 @@ using Microsoft.Extensions.Options; using OrchardCore.ContentManagement; using OrchardCore.Data; +using OrchardCore.Json; using OrchardCore.Liquid; using YesSql; @@ -27,13 +28,13 @@ public SqlQuerySource( ILiquidTemplateManager liquidTemplateManager, IDbConnectionAccessor dbConnectionAccessor, ISession session, - IOptions jsonSerializerOptions, + IOptions jsonSerializerOptions, IOptions templateOptions) { _liquidTemplateManager = liquidTemplateManager; _dbConnectionAccessor = dbConnectionAccessor; _session = session; - _jsonSerializerOptions = jsonSerializerOptions.Value; + _jsonSerializerOptions = jsonSerializerOptions.Value.SerializerOptions; _templateOptions = templateOptions.Value; } diff --git a/src/OrchardCore.Modules/OrchardCore.ReCaptcha/Drivers/ReCaptchaSettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.ReCaptcha/Drivers/ReCaptchaSettingsDisplayDriver.cs index 25fb57581d4..c4d1dbb0338 100644 --- a/src/OrchardCore.Modules/OrchardCore.ReCaptcha/Drivers/ReCaptchaSettingsDisplayDriver.cs +++ b/src/OrchardCore.Modules/OrchardCore.ReCaptcha/Drivers/ReCaptchaSettingsDisplayDriver.cs @@ -6,6 +6,7 @@ using OrchardCore.DisplayManagement.Handlers; using OrchardCore.DisplayManagement.Views; using OrchardCore.Environment.Shell; +using OrchardCore.Modules; using OrchardCore.ReCaptcha.Configuration; using OrchardCore.ReCaptcha.ViewModels; using OrchardCore.Settings; @@ -34,6 +35,11 @@ public ReCaptchaSettingsDisplayDriver( public override async Task EditAsync(ReCaptchaSettings settings, BuildEditorContext context) { + if (!context.GroupId.Equals(GroupId, StringComparison.OrdinalIgnoreCase)) + { + return null; + } + var user = _httpContextAccessor.HttpContext?.User; if (!await _authorizationService.AuthorizeAsync(user, Permissions.ManageReCaptchaSettings)) @@ -41,6 +47,8 @@ public override async Task EditAsync(ReCaptchaSettings settings, return null; } + context.Shape.Metadata.Wrappers.Add("Settings_Wrapper__Reload"); + return Initialize("ReCaptchaSettings_Edit", model => { model.SiteKey = settings.SiteKey; @@ -59,7 +67,7 @@ public override async Task UpdateAsync(ReCaptchaSettings section return null; } - if (context.GroupId.Equals(GroupId, StringComparison.OrdinalIgnoreCase)) + if (context.GroupId.EqualsOrdinalIgnoreCase(GroupId)) { var model = new ReCaptchaSettingsViewModel(); diff --git a/src/OrchardCore.Modules/OrchardCore.ReCaptcha/Views/ReCaptchaSettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.ReCaptcha/Views/ReCaptchaSettings.Edit.cshtml index 4af732e87d4..de9860a3971 100644 --- a/src/OrchardCore.Modules/OrchardCore.ReCaptcha/Views/ReCaptchaSettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.ReCaptcha/Views/ReCaptchaSettings.Edit.cshtml @@ -1,7 +1,5 @@ @model ReCaptchaSettingsViewModel -

    @T["The current tenant will be reloaded when the settings are saved."]

    -
    diff --git a/src/OrchardCore.Modules/OrchardCore.ReverseProxy/Drivers/ReverseProxySettingsDisplayDriver.cs b/src/OrchardCore.Modules/OrchardCore.ReverseProxy/Drivers/ReverseProxySettingsDisplayDriver.cs index ee440e581c3..a63d7c01859 100644 --- a/src/OrchardCore.Modules/OrchardCore.ReverseProxy/Drivers/ReverseProxySettingsDisplayDriver.cs +++ b/src/OrchardCore.Modules/OrchardCore.ReverseProxy/Drivers/ReverseProxySettingsDisplayDriver.cs @@ -1,3 +1,4 @@ +using System; using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Http; @@ -6,6 +7,7 @@ using OrchardCore.DisplayManagement.Handlers; using OrchardCore.DisplayManagement.Views; using OrchardCore.Environment.Shell; +using OrchardCore.Modules; using OrchardCore.ReverseProxy.Settings; using OrchardCore.ReverseProxy.ViewModels; using OrchardCore.Settings; @@ -35,6 +37,11 @@ public ReverseProxySettingsDisplayDriver( public override async Task EditAsync(ReverseProxySettings settings, BuildEditorContext context) { + if (!context.GroupId.Equals(GroupId, StringComparison.OrdinalIgnoreCase)) + { + return null; + } + var user = _httpContextAccessor.HttpContext?.User; if (!await _authorizationService.AuthorizeAsync(user, Permissions.ManageReverseProxySettings)) @@ -42,12 +49,15 @@ public override async Task EditAsync(ReverseProxySettings settin return null; } + context.Shape.Metadata.Wrappers.Add("Settings_Wrapper__Reload"); + return Initialize("ReverseProxySettings_Edit", model => { model.EnableXForwardedFor = settings.ForwardedHeaders.HasFlag(ForwardedHeaders.XForwardedFor); model.EnableXForwardedHost = settings.ForwardedHeaders.HasFlag(ForwardedHeaders.XForwardedHost); model.EnableXForwardedProto = settings.ForwardedHeaders.HasFlag(ForwardedHeaders.XForwardedProto); - }).Location("Content:2").OnGroup(GroupId); + }).Location("Content:2") + .OnGroup(GroupId); } public override async Task UpdateAsync(ReverseProxySettings section, BuildEditorContext context) @@ -59,7 +69,7 @@ public override async Task UpdateAsync(ReverseProxySettings sect return null; } - if (context.GroupId == GroupId) + if (context.GroupId.EqualsOrdinalIgnoreCase(GroupId)) { var model = new ReverseProxySettingsViewModel(); diff --git a/src/OrchardCore.Modules/OrchardCore.ReverseProxy/Views/ReverseProxySettings.Edit.cshtml b/src/OrchardCore.Modules/OrchardCore.ReverseProxy/Views/ReverseProxySettings.Edit.cshtml index 43cc396d590..481381ce2d0 100644 --- a/src/OrchardCore.Modules/OrchardCore.ReverseProxy/Views/ReverseProxySettings.Edit.cshtml +++ b/src/OrchardCore.Modules/OrchardCore.ReverseProxy/Views/ReverseProxySettings.Edit.cshtml @@ -4,10 +4,6 @@ @inject IClientIPAddressAccessor ClientIPAddressAccessor -

    - @T["The current tenant will be reloaded when the settings are saved."] -

    -