xiaomianao666

小程序:模板·Q

Sep 7th, 2023
143
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 海阔视界规则分享,当前分享的是:小程序¥home_rule_v2¥base64://@模板·Q@eyJsYXN0X2NoYXB0ZXJfcnVsZSI6IiIsInRpdGxlIjoi5qih5p2/wrdRIiwiYXV0aG9yIjoi5Y+R57Kq5raC5aKZIiwidXJsIjoiaGlrZXI6Ly9lbXB0eSMjZnlwYWdlIiwidmVyc2lvbiI6MjMwNjE1MDAsImNvbF90eXBlIjoidGV4dF9jZW50ZXJfMSIsImNsYXNzX25hbWUiOiIiLCJ0eXBlIjoidG9vbCIsImNsYXNzX3VybCI6IiIsImFyZWFfbmFtZSI6IiIsImFyZWFfdXJsIjoiIiwic29ydF9uYW1lIjoiIiwieWVhcl9uYW1lIjoiIiwic29ydF91cmwiOiIiLCJ5ZWFyX3VybCI6IiIsImZpbmRfcnVsZSI6ImpzOlxuaWYgKGdldEl0ZW0oXCJzdGFydFwiLCBcIlwiKSA9PSBcIlwiKSB7XG4gICAgc2V0SXRlbShcInN0YXJ0XCIsIFwiMVwiKVxuICAgIGNvbmZpcm0oe1xuICAgICAgICB0aXRsZTogJ+a4qemmqOaPkOekuicsXG4gICAgICAgIGNvbnRlbnQ6ICfor7fli7/liKDpmaTmiJbmlLnlkI3mraTmqKHmnb/vvIzku6XlhY3kvp3otZbmraTmqKHmnb/nmoTlsI/nqIvluo/ml6Dms5Xkvb/nlKjvvIHvvIFcXG7lubbnibnliKvmhJ/osKIgUmVib3JuIExveURnSWvlpKfkvaznmoTmioDmnK/mlK/mjIEhISEnLFxuICAgICAgICBjb25maXJtOiAnJyxcbiAgICAgICAgY2FuY2VsOiAncmVmcmVzaFBhZ2UoKSdcbiAgICB9KVxufVxuYWRkTGlzdGVuZXIoXCJvbkNsb3NlXCIsICQudG9TdHJpbmcoKCkgPT4ge1xuICAgIGNsZWFyVmFyKFwidGVtcGxhdGUtdXJsXCIpXG4gICAgY2xlYXJW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TogXCLmtYvor5XmkJzntKJcIixcbn0sIHtcbiAgICB0aXRsZTogXCLnlJ/miJDop4TliJlcIixcbiAgICBjb2xfdHlwZTogXCJ0ZXh0X2NlbnRlcl8xXCIsXG4gICAgdXJsOiBcImlucHV0Oi8vLy8vL+ivt+i+k+WFpeinhOWImeWQjS5qczpcIiArICQudG9TdHJpbmcoKCkgPT4ge1xuICAgICAgICB2YXIgdXJsID0gZ2V0VmFyKCd0ZW1wbGF0ZS11cmwnLCBcIlwiKTtcbiAgICAgICAgaWYgKHVybC5sZW5ndGggPD0gMCB8fCBpbnB1dC5sZW5ndGggPD0gMCkge1xuICAgICAgICAgICAgcmV0dXJuIFwidG9hc3Q6Ly/or7flhYjovpPlhaXpk77mjqXlkozop4TliJnlkI1cIlxuICAgICAgICB9XG4gICAgICAgIHZhciBydWxlID0ge1xuICAgICAgICAgICAgXCJsYXN0X2NoYXB0ZXJfcnVsZVwiOiBcIlwiLFxuICAgICAgICAgICAgXCJ0aXRsZVwiOiBpbnB1dCxcbiAgICAgICAgICAgIFwiYXV0aG9yXCI6IFwiXCIsXG4gICAgICAgICAgICBcInVybFwiOiB1cmwsXG4gICAgICAgICAgICBcInZlcnNpb25cIjogMCxcbiAgICAgICAgICAgIFwiY29sX3R5cGVcIjogXCJtb3ZpZV8zXCIsXG4gICAgICAgICAgICBcImNsYXNzX25hbWVcIjogXCJcIixcbiAgICAgICAgICAgIFwiY2xhc3NfdXJsXCI6IFwiXCIsXG4gICAgICAgICAgICBcImFyZWFfbmFtZVwiOiBcIlwiLFxuICAgICAgICAgICAgXCJhcmVhX3VybFwiOiBcIlwiLFxuICAgICAgICAgICAgXCJzb3J0X25hbWVcIjogXCJcIixcbiAgICAgICAgICAgIFwieWVhcl9uYW1lXCI6IFwiXCIsXG4gICAgICAgICAgICBcInNvcnRfdXJsXCI6IFwiXCIsXG4gICAgICAgICAgICBcInllYXJfdXJsXCI6IFwiXCIsXG4gICAgICAgICAgICBcImZpbmRfcnVsZVwiOi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O1xcbiAgICAgICAgICAgIH1cXG4gICAgICAgICAgICBpZiAoL20zdTh8bXA0Ly50ZXN0KHVybCkpIHtcXG4gICAgICAgICAgICAgICAgcmV0dXJuIHVybFxcbiAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgIHJldHVybiAndmlkZW86Ly8nICsgaW5wdXRcXG4gICAgICAgICAgICB9XFxuICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgIHJldHVybiAndmlkZW86Ly8nICsgaW5wdXRcXG4gICAgfVxcbn0pXFxuXFxuY29uc3Qge1xcbiAgICBhdXRvUGFnZVxcbn0gPSAkLnJlcXVpcmUoXFxcImhpa2VyOi8vcGFnZS9hdXRvP3J1bGU95qih5p2/wrdRXFxcIik7XFxuYXV0b1BhZ2UoZ2V0UmVzQ29kZSgpKVwiLFxuICAgICAgICAgICAgXCJzZGV0YWlsX2NvbF90eXBlXCI6IFwibW92aWVfMVwiLFxuICAgICAgICAgICAgXCJzZGV0YWlsX2ZpbmRfcnVsZVwiOiBcIipcIixcbiAgICAgICAgICAgIFwidWFcIjogXCJtb2JpbGVcIixcbiAgICAgICAgICAgIFwicHJlUnVsZVwiOiBcImlmIChyZXF1ZXN0KCdoaWtlcjovL2hvbWVA5qih5p2/wrdRJykgPT0gJ251bGwnKSB7XFxuICAgIGNvbmZpcm0oe1xcbiAgICAgICAgdGl0bGU6ICfkvp3otZbmo4DmtYsnLFxcbiAgICAgICAgY29udGVudDogJ+ajgOa1i+WIsOe8uuWwkeaooeadv+S+nei1lizor7flr7zlhaUhJyxcXG4gICAgICAgIGNvbmZpcm06ICgpID0+IHtcXG4gICAgICAgICAgICByZXR1cm4gXFxcIua1t+mYlOinhueVjOmmlumhtemikemBk+inhOWImeOAkOaooeadv8K3UeOAke+/pWhvbWVfcnVsZV91cmzvv6VodHRwOi8vaGlrZXIubm9raWEucHJlc3MvaGlrZXJ1bGUvcnVsZWxpc3QuanNvbj9pZD0zMDU1XFxcIlxcbiAgIC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ICAgICAgIHVwZGF0ZUl0ZW0oe1xcbiAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgIGlkOiBNWV9VUkwgKyBcXFwiX+aOkuW6j1xcXCIsXFxuICAgICAgICAgICAgICAgIGxvbmdDbGljazogW3tcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOiBcXFwiVFZib3jmjqjpgIFcXFwiLFxcbiAgICAgICAgICAgICAgICAgICAganM6ICQudG9TdHJpbmcoKHRhYnMsIGxpc3RzLCBkKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIOaOqOmAgSA9IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcIm5hbWVcXFwiOiBnZXRQYWdlVGl0bGUoKSxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcImNvbnRlbnRcXFwiOiBkLmRlc2MsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJwaWNcXFwiOiBkLmltZyB8fCBkLnBpY191cmwsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJmcm9tXFxcIjogdGFicy5qb2luKCckJCQnKSxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcInVybFxcXCI6IHN0b3JhZ2UwLmdldE15VmFyKFxcXCJsaXN0c1xcXCIpLm1hcChsaSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gbGkubWFwKGxpMSA9PiBwZGZoKGxpMSwgJ1RleHQnKSArICckJyArIHBkKGxpMSwgJ2EmJmhyZWYnKSkuam9pbignIycpXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pLmpvaW4oJyQkJCcpXFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9wYWdlL3B1c2g/cnVsZT1YWVHmjqjpgIEmcHVzaHVybD1cXFwiICsgZW5jb2RlVVJJQ29tcG9uZW50KEpTT04uc3RyaW5naWZ5KOaOqOmAgSkpXFxuICAgICAgICAgICAgICAgICAgICB9LCB0YWJzLCBsaXN0cywgZClcXG4gICAgICAgICAgICAgICAgfV1cXG4gICAgICAgICAgICB9LFxcbiAgICAgICAgICAgIHRpdGxlOiDmjpLluo/lkI0ucmVwbGFjZSgn5o6S5bqPJywg5o+Q56S6KVxcbiAgICAgICAgfSlcXG4gICAgICAgIGlmICjmjpLluo8gPT0gJyMxYWFkMTlcXFwiPuato+W6jycpIHtcXG4gICAgICAgICAgICDnq6DoioIucmV2ZXJzZSgpXFxuICAgICAgICB9XFxuICAgICAgICBsZXQgY3AgPSDnq6DoioIubWFwKChkYXRhLCBzc2lkKSA9PiB7XFxuICAgICAgICAgICAgcmV0dXJuIHtcXG4gICAgICAgICAgICAgICAgdGl0bGU6IHBkZmgoZGF0YSwgJ2EmJlRleHQnKSxcXG4gICAgICAgICAgICAgICAgdXJsOiBwZChkYXRhLCAnYSYmaHJlZicpICsgbGF6eSxcXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6IOeroOiKgi5sZW5ndGggPiAzID8gJ3RleHRfNCcgOiAndGV4dF8yJyxcXG4gICAgICAgICAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgICAgICAgICAgIGNsczogTVlfVVJMICsgXFxcIl/pgInpm4ZcXFwiLFxcbiAgICAgICAgICAgICAgICAgICAgaWQ6IHBkKGRhdGEsICdhJiZocmVmJylcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIH07XFxuICAgICAgICB9KTtcXG4gICAgICAgIGRlbGV0ZUl0ZW1CeUNscyhNWV9VUkwgKyBcXFwiX+mAiembhlxcXCIpO1xcbiAgICAgICAgYWRkSXRlbUJlZm9yZShNWV9VUkwgKyBcXFwiZm9vdGVyXFxcIiwgY3ApO1xcbiAgICAgICAgcHV0TXlWYXIoTVlfVVJMICsgXFxcIueroOiKguaOkuW6j1xcXCIsIOaPkOekuilcXG4gICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9lbXB0eVxcXCJcXG4gICAgfSwgdGFicywg5o6S5bqP5ZCNLCBsYXp5LCBkWzBdKSxcXG4gICAgY29sX3R5cGU6ICdmbGV4X2J1dHRvbicsXFxuICAgIGV4dHJhOiB7XFxuICAgICAgICBpZDogTVlfVVJMICsgXFxcIl/mjpLluo9cXFwiLFxcbiAgICAgICAgbG9uZ0NsaWNrOiBbe1xcbiAgICAgICAgICAgIHRpdGxlOiBcXFwiVFZib3jmjqjpgIFcXFwiLFxcbiAgICAgICAgICAgIGpzOiAkLnRvU3RyaW5nKCh0YWJzLCBsaXN0cywgZCkgPT4ge1xcbiAgICAgICAgICAgICAgICB2YXIg5o6o6YCBID0ge1xcbiAgICAgICAgICAgICAgICAgICAgXFxcIm5hbWVcXFwiOiBnZXRQYWdlVGl0bGUoKSxcXG4gICAgICAgICAgICAgICAgICAgIFxcXCJjb250ZW50XFxcIjogZC5kZXNjLFxcbiAgICAgICAgICAgICAgICAgICAgXFxcInBpY1xcXCI6IGQuaW1nIHx8IGQucGljX3VybCxcXG4gICAgICAgICAgICAgICAgICAgIFxcXCJmcm9tXFxcIjogdGFicy5qb2luKCckJCQnKSxcXG4gICAgICAgICAgICAgICAgICAgIFxcXCJ1cmxcXFwiOiBzdG9yYWdlMC5nZXRNeVZhcihcXFwibGlzdHNcXFwiKS5tYXAobGkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBsaS5tYXAobGkxID0+IHBkZmgobGkxLCAnVGV4dCcpICsgJyQnICsgcGQobGkxLCAnYSYmaHJlZicpKS5qb2luKCcjJylcXG4gICAgICAgICAgICAgICAgICAgIH0pLmpvaW4oJyQkJCcpXFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgcmV0dXJuIFxcXCJoaWtlcjovL3BhZ2UvcHVzaD9ydWxlPVhZUeaOqOmAgSZwdXNodXJsPVxcXCIgKyBlbmNvZGVVUklDb21wb25lbnQoSlNPTi5zdHJpbmdpZnko5o6o6YCBKSlcXG4gICAgICAgICAgICB9LCB0YWJzLCBsaXN0cywgZFswXSlcXG4gICAgICAgIH1dXFxuICAgIH1cXG59KVxcblxcbnRhYnMuZm9yRWFjaCgoZGF0YSwgaWQpID0+IHtcXG4gICAgZC5wdXNoKHtcXG4gICAgICAgIHRpdGxlOiBnZXRNeVZhcihNWV9VUkwsICcwJykgPT0gaWQgPyAn4oCc4oCcJyArIGRhdGEgKyAn4oCd4oCdJyA6IGRhdGEsXFxuICAgICAgICB1cmw6ICQoXFxcIiNub0xvYWRpbmcjXFxcIikubGF6eVJ1bGUoKOe6v+i3rywgbGF6eSwgaWQpID0+IHtcXG4gICAgICAgICAgICB2YXIgbGlzdHMgPSBzdG9yYWdlMC5nZXRNeVZhcihcXFwibGlzdHNcXFwiKTtcXG4gICAgICAgICAgICB2YXIg5o6S5bqPID0gZ2V0TXlWYXIoTVlfVVJMICsgXFxcIueroOiKguaOkuW6j1xcXCIsICcjMWFhZDE5XFxcIj7mraPluo8nKTtcXG4gICAgICAgICAgICB2YXIg5o+Q56S6ID0g5o6S5bqPID09ICcjRkYwMDAwXFxcIj7lgJLluo8nID8gJyMxYWFkMTlcXFwiPuato+W6jycgOiAnI0ZGMDAwMFxcXCI+5YCS5bqPJztcXG4gICAgICAgICAgICDnur/ot68uZm9yRWFjaCgoZGF0YSwgeGxpZCkgPT4ge1xcbiAgICAgICAgICAgICAgICB1cGRhdGVJdGVtKHtcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOiBpZCA9PSB4bGlkID8gJ+KAnOKAnCcgKyBkYXRhICsgJ+KAneKAnScgOiBkYXRhLFxcbiAgICAgICAgICAgICAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZDogTVlfVVJMICsgXFxcIl/nur/ot69cXFwiICsgeGxpZFxcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIHB1dE15VmFyKE1ZX1VSTCwgaWQpXFxuICAgICAgICAgICAgdmFyIOeroOiKgiA9IGxpc3RzW2dldE15VmFyKE1ZX1VSTCwgJzAnKV07XFxuICAgICAgICAgICAgaWYgKOaOkuW6jyA9PSAnI0ZGMDAwMFxcXCI+5YCS5bqPJykge1xcbiAgICAgICAgICAgICAgICDnq6DoioIucmV2ZXJzZSgpXFxuICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIGxldCBjcCA9IOeroOiKgi5tYXAoKGRhdGEsIHNzaWQpID0+IHtcXG4gICAgICAgICAgICAgICAgcmV0dXJuIHtcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOiBwZGZoKGRhdGEsICdhJiZUZXh0JyksXFxuICAgICAgICAgICAgICAgICAgICB1cmw6IHBkKGRhdGEsICdhJiZocmVmJykgKyBsYXp5LFxcbiAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6IOeroOiKgi5sZW5ndGggPiAzID8gJ3RleHRfNCcgOiAndGV4dF8yJyxcXG4gICAgICAgICAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgY2xzOiBNWV9VUkwgKyBcXFwiX+mAiembhlxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgaWQ6IHBkKGRhdGEsICdhJiZocmVmJylcXG4gICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgfTtcXG4gICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICBkZWxldGVJdGVtQnlDbHMoTVlfVVJMICsgXFxcIl/pgInpm4ZcXFwiKTtcXG4gICAgICAgICAgICBhZGRJdGVtQmVmb3JlKE1ZX1VSTCArIFxcXCJmb290ZXJcXFwiLCBjcCk7XFxuICAgICAgICAgICAgcmV0dXJuIFxcXCJoaWtlcjovL2VtcHR5XFxcIlxcbiAgICAgICAgfSwgdGFicywgbGF6eSwgaWQpLFxcbiAgICAgICAgY29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lzOiBbXFxcIm5hdi10YWJzXFxcIl0sXFxuICAgICAgICAgICAgdXJsOiBcXFwibmF2LXRhYnNcXFwiLFxcbiAgICAgICAgfSxcXG4gICAgICAgIHtcXG4gICAgICAgICAgICBrZXlzOiBbXFxcIm15dWktY29udGVudF9fbGlzdFxcXCJdLFxcbiAgICAgICAgICAgIHVybDogXFxcIm15dWktY29udGVudF9fbGlzdFxcXCIsXFxuICAgICAgICB9LFxcbiAgICAgICAge1xcbiAgICAgICAgICAgIGtleXM6IFtcXFwibmF2LXRhYnNcXFwiLCBcXFwic3R1aS1jb250ZW50X19wbGF5bGlzdFxcXCJdLFxcbiAgICAgICAgICAgIHVybDogXFxcIm5hdi10YWJzMVxcXCIsXFxuICAgICAgICAgICAgYWxsS2V5OiB0cnVlLFxcbiAgICAgICAgfSxcXG4gICAgICAgIHtcXG4gICAgICAgICAgICBrZXlzOiBbXFxcImgzXFxcIiwgXFxcInN0dWktY29udGVudF9fcGxheWxpc3RcXFwiXSxcXG4gICAgICAgICAgICB1cmw6IFxcXCJoM1xcXCIsXFxuICAgICAgICAgICAgYWxsS2V5OiB0cnVlLFxcbiAgICAgICAgfSxcXG4gICAgICAgIHtcXG4gICAgICAgICAgICBrZXlzOiBbXFxcIm15dWktdm9kbGlzdCBcXFwiXSxcXG4gICAgICAgICAgICB1cmw6IFxcXCJteXVpLXZvZGxpc3RcXFwiLFxcbiAgICAgICAgfSxcXG4gICAgICAgIHtcXG4gICAgICAgICAgICBrZXlzOiBbXFxcIm1vLW1vdnMtaXRlbVxcXCJdLFxcbiAgICAgICAgICAgIHVybDogXFxcIm1vLW1vdnMtaXRlbVxcXCIsXFxuICAgICAgICB9LFxcbiAgICAgICAge1xcbiAgICAgICAgICAgIGtleXM6IFtcXFwibW9kdWxlLXRhYi1pdGVtXFxcIl0sXFxuICAgICAgICAgICAgdXJsOiBcXFwibW9kdWxlLXRhYi1pdGVtXFxcIixcXG4gICAgICAgICAgICAvLyAgICAgYWxsS2V5OiB0cnVlLFxcbiAgICAgICAgfSx7XFxuICAgICAgICAgICAga2V5czogW1xcXCJ5LXBsYXlMaXN0XFxcIl0sXFxuICAgICAgICAgICAgdXJsOiBcXFwieS1wbGF5TGlzdFxcXCIsXFxuICAgICAgICB9LFxcbiAgICAgICAge1xcbiAgICAgICAgICAgIGtleXM6IFtcXFwic3R1aS12b2RsaXN0IFxcXCJdLFxcbiAgICAgICAgICAgIHVybDogXFxcInN0dWktdm9kbGlzdFxcXCIsXFxuICAgICAgICAgICAgLy8gICAgIGFsbEtleTogdHJ1ZSxcXG4gICAgICAgIH0sXFxuICAgICAgICB7XFxuICAgICAgICAgICAga2V5czogW1xcXCJwbGF5X3NvdXJjZV90YWJcXFwiXSxcXG4gICAgICAgICAgICB1cmw6IFxcXCJwbGF5X3NvdXJjZV90YWJcXFwiLFxcbiAgICAgICAgfSxcXG4gICAgICAgIHtcXG4gICAgICAgICAgICBrZXlzOiBbXFxcImZlZC1wbGF5LWl0ZW1cXFwiXSxcXG4gICAgICAgICAgICB1cmw6IFxcXCJmZWQtcGxheS1pdGVtXFxcIixcXG4gICAgICAgIH0sXFxuICAgICAgICB7XFxuICAgICAgICAgICAga2V5czogW1xcXCJtb2R1bGUtaXRlbVxcXCJdLFxcbiAgICAgICAgICAgIHVybDogXFxcIm1vZHVsZS1pdGVtc1xcXCIsXFxuICAgICAgICB9LFxcbiAgICAgICAge1xcbiAgICAgICAgICAgIGtleXM6IFtcXFwidm9kbGlzdCBcXFwiLCBcXFwibGF6eWxvYWRcXFwiXSxcXG4gICAgICAgICAgICB1cmw6IFxcXCJ2b2RsaXN0XFxcIixcXG4gICAgICAgICAgICBhbGxLZXk6IHRydWUsXFxuICAgICAgICB9LFxcbiAgICAgICAge1xcbiAgICAgICAgICAgIGtleXM6IFtcXFwibW8tcGxheS1sb2FkXFxcIl0sXFxuICAgICAgICAgICAgdXJsOiBcXFwibW8tcGxheS1sb2FkXFxcIixcXG4gICAgICAgIH0sXFxuICAgICAgICB7XFxuICAgICAgICAgICAga2V5czogW1xcXCJmZWQtbGlzdC10aXRsZVxcXCJdLFxcbiAgICAgICAgICAgIHVybDogXFxcImZlZC1saXN0LXRpdGxlXFxcIixcXG4gICAgICAgICAgICAvL2FsbEtleTogdHJ1ZSxcXG4gICAgICAgIH0sXFxuICAgICAgICB7XFxuICAgICAgICAgICAga2V5czogW1xcXCJwYWNrLXlrcGFja1xcXFxcXFwiXFxcIl0sXFxuICAgICAgICAgICAgdXJsOiBcXFwicGFjay15a3BhY2tcXFwiLFxcbiAgICAgICAgfSxcXG4gICAgICAgIC8qXFxuICAgICAgICAgICAgICAgIHtcXG4gICAgICAgICAgICAgICAgICAgIGtleXM6IFtcXFwiaXRlbVxcXCJdLFxcbiAgICAgICAgICAgICAgICAgICAgdXJsOiBcXFwiaXRlbVxcXCIsXFxuICAgICAgICAgICAgICAgIH0sKi9cXG4gICAgICAgIHtcXG4gICAgICAgICAgICBrZXlzOiBbXFxcImRhdGFfbGlzdFxcXCJdLFxcbiAgICAgICAgICAgIHVybDogXFxcImRhdGFfbGlzdFxcXCIsXFxuICAgICAgICB9LFxcbiAgICBdLFxcbiAgICBcXFwic2VhcmNoXFxcIjogW3tcXG4gICAgICAgICAgICBrZXlzOiBbXFxcInN0dWktdm9kbGlzdF9fbWVkaWFcXFwiXSxcXG4gICAgICAgICAgICB1cmw6IFxcXCJzdHVpLXZvZGxpc3RfX21lZGlhXFxcIixcXG4gICAgICAgIH0sXFxuICAgICAgICB7XFxuICAgICAgICAgICAga2V5czogW1xcXCJteXVpLXZvZGxpc3RfX21lZGlhXFxcIl0sXFxuICAgICAgICAgICAgdXJsOiBcXFwibXl1aS12b2RsaXN0X19tZWRpYVxcXCIsXFxuICAgICAgICB9LFxcbiAgICAgICAge1xcbiAgICAgICAgICAgIGtleXM6IFtcXFwibW9kdWxlLXNlYXJjaC1pdGVtXFxcIl0sXFxuICAgICAgICAgICAgdXJsOiBcXFwibW9kdWxlLXNlYXJjaC1pdGVtXFxcIixcX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gICAgICAgICAgICByZXR1cm4gXFxcImhpa2VyOi8vZW1wdHlcXFwiXFxuICAgICAgICB9LCBmb2xkKSxcXG4gICAgICAgIGNvbF90eXBlOiAnc2Nyb2xsX2J1dHRvbicsXFxuICAgIH0pXFxuICAgIGNhdGVnb3JpZXMuZm9yRWFjaCgoY2F0ZWdvcnksIGluZGV4KSA9PiB7XFxuICAgICAgICBsZXQgc3ViX2NhdGVnb3JpZXMgPSBwZGZhKGNhdGVnb3J5LCDlsI/nsbvlrprkvY0pO1xcbiAgICAgICAgaWYgKGluZGV4ID09PSAwKSB7XFxuICAgICAgICAgICAgc3ViX2NhdGVnb3JpZXMuZm9yRWFjaCgoaXRlbSwga2V5KSA9PiB7XFxuICAgICAgICAgICAgICAgIGxldCB0aXRsZSA9IHBkZmgoaXRlbSwg5YiG57G75qCH6aKYKVxcbiAgICAgICAgICAgICAgICBpZiAodHlwZW9mKOaOkumZpCkgIT0gJ3VuZGVmaW5lZCcgJiYg5o6S6ZmkICE9ICcnKSB7XFxuICAgICAgICAgICAgICAgICAgICB0aXRsZSA9IHRpdGxlLnJlcGxhY2UobmV3IFJlZ0V4cCjmjpLpmaQsIFxcXCJnXFxcIiksIFxcXCJcXFwiKVxcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgICAgICB0aXRsZToga2V5LnRvU3RyaW5nKCkgPT09IGNhdGVfdGVtcFtpbmRleF0gPyBcXFwi4oCc4oCc4oCd4oCdXFxcIiArIHRpdGxlLmZvbnRjb2xvcijliIbnsbvpopzoibIpIDogdGl0bGUsXFxuICAgICAgICAgICAgICAgICAgICB1cmw6ICQocGQoaXRlbSwg5YiG57G76ZO+5o6lKSArICcjbm9Mb2FkaW5nIycpLmxhenlSdWxlKChwYXJhbXMpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBsZXQgbmV3X2NhdGUgPSBbXVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHBhcmFtcy5jYXRlX3RlbXAuZm9yRWFjaCgoY2F0ZSwgaW5kZXgpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbmV3X2NhdGUucHVzaChpbmRleCA9PT0gMCA/IHBhcmFtcy5rZXkudG9TdHJpbmcoKSA6IFxcXCIwXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHB1dFZhcihNWV9SVUxFLnRpdGxlLCBKU09OLnN0cmluZ2lmeShuZXdfY2F0ZSkpXFxuICAgICAgICAgICAgICAgICAgICAgICAgcHV0VmFyKE1ZX1JVTEUudXJsLCBpbnB1dClcXG4gICAgICAgICAgICAgICAgICAgICAgICByZWZyZXNoUGFnZSh0cnVlKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9lbXB0eVxcXCJcXG4gICAgICAgICAgICAgICAgICAgIH0sIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBjYXRlX3RlbXA6IGNhdGVfdGVtcCxcXG4gICAgICAgICAgICAgICAgICAgICAgICBrZXk6IGtleSxcXG4gICAgICAgICAgICAgICAgICAgICAgICBwYWdlOiBwYWdlLFxcbiAgICAgICAgICAgICAgICAgICAgfSksXFxuICAgICAgICAgICAgICAgICAgICBjb2xfdHlwZTogJ3Njcm9sbF9idXR0b24nLFxcbiAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6IFxcXCJibGFua19ibG9ja1xcXCJcXG4gICAgICAgICAgICB9KTtcXG4gICAgICAgIH0gZWxzZSBpZiAoZm9sZCA9PT0gJzEnKSB7XFxuICAgICAgICAgICAgc3ViX2NhdGVnb3JpZXMuZm9yRWFjaCgoaXRlbSwga2V5KSA9PiB7XFxuICAgICAgICAgICAgICAgIGxldCB0aXRsZSA9IHBkZmgoaXRlbSwg5YiG57G75qCH6aKYKVxcbiAgICAgICAgICAgICAgICBpZiAodHlwZW9mKOaOkumZpCkgIT0gJ3VuZGVmaW5lZCcgJiYg5o6S6ZmkICE9ICcnKSB7XFxuICAgICAgICAgICAgICAgICAgICB0aXRsZSA9IHRpdGxlLnJlcGxhY2UobmV3IFJlZ0V4cCjmjpLpmaQsIFxcXCJnXFxcIiksIFxcXCJcXFwiKVxcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgICAgICB0aXRsZToga2V5LnRvU3RyaW5nKCkgPT09IGNhdGVfdGVtcFtpbmRleF0gPyBcXFwi4oCc4oCc4oCd4oCdXFxcIiArIHRpdGxlLmZvbnRjb2xvcijliIbnsbvpopzoibIpIDogdGl0bGUsXFxuICAgICAgICAgICAgICAgICAgICB1cmw6ICQocGQoaXRlbSwg5YiG57G76ZO+5o6lKSArICcjbm9Mb2FkaW5nIycpLmxhenlSdWxlKChwYXJhbXMpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBwYXJhbXMuY2F0ZV90ZW1wW3BhcmFtcy5pbmRleF0gPSBwYXJhbXMua2V5LnRvU3RyaW5nKClcXG5cXG4gICAgICAgICAgICAgICAgICAgICAgICBwdXRWYXIoTVlfUlVMRS50aXRsZSwgSlNPTi5zdHJpbmdpZnkocGFyYW1zLmNhdGVfdGVtcCkpXFxuICAgICAgICAgICAgICAgICAgICAgICAgcHV0VmFyKE1ZX1JVTEUudXJsLCBpbnB1dClcXG4gICAgICAgICAgICAgICAgICAgICAgICByZWZyZXNoUGFnZSh0cnVlKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9lbXB0eVxcXCJcXG4gICAgICAgICAgICAgICAgICAgIH0sIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBjYXRlX3RlbXA6IGNhdGVfdGVtcCxcXG4gICAgICAgICAgICAgICAgICAgICAgICBpbmRleDogaW5kZXgsXFxuICAgICAgICAgICAgICAgICAgICAgICAga2V5OiBrZXksXFxuICAgICAgICAgICAgICAgICAgICAgICAgcGFnZTogcGFnZSxcXG4gICAgICAgICAgICAgICAgICAgIH0pLFxcbiAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6ICdzY3JvbGxfYnV0dG9uJyxcXG4gICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiBcXFwiYmxhbmtfYmxvY2tcXFwiXFxuICAgICAgICAgICAgfSk7XFxuICAgICAgICB9XFxuICAgIH0pXFxufVwifSx7XCJjb2xfdHlwZVwiOlwibW92aWVfM1wiLFwibmFtZVwiOlwi5LiA57qn5YWs5YWx5qih5p2/XCIsXCJwYXRoXCI6XCJ5aWppXCIsXCJydWxlXCI6XCJmdW5jdGlvbiDkuIDnuqcoKSB7fTtcXG5PYmplY3QuYXNzaWduKOS4gOe6py5wcm90b3R5cGUsIHtcXG4gICAgY29uc3RydWN0b3I6IOS4gOe6pyxcXG4gICAgdGVzdCgpIHt9LFxcbiAgICDojrflj5bmupDnoIEodXJsLCBoZWFkZXIpIHtcXG4gICAgICAgIHJldHVybiBmZXRjaCh0cnVlX3VybCwge1xcbiAgICAgICAgICAgIGhlYWRlcnM6IGhlYWRlciB8fCB7XFxuICAgICAgICAgICAgICAgICdVc2VyLUFnZW50JzogJ01vemlsbGEvNS4wIChXaW5kb3dzIE5UIDEwLjApJ1xcbiAgICAgICAgICAgIH1cXG4gICAgICAgIH0pIC8vIOm7mOiupOe7n+S4gOS9v+eUqFBDIFVBXFxuICAgIH0sXFxuICAgIOiOt+WPluato+ehrumTvuaOpShwYWdlLCByZWdleCkge1xcbiAgICAgICAgbGV0IHRydWVfdXJsID0gZ2V0TXlWYXIoJ2hlYWRlci51cmwnLCBNWV9VUkwpO1xcbiAgICAgICAgbGV0IOmTvuaOpeWkhOeQhuW3peW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ICAgLumhteeggShwYWdlKVxcbiAgICAgICAgICAgIC7mt7vliqDliIbnsbvlrprkvY0ocnVsZUxpc3QpXFxuICAgICAgICAgICAgLuW8gOWQr+WGhee9ruaKmOWPoOWKn+iDvSgpIC8vIOW/hemhu1xcbiAgICAgICAgICAgIC7mipjlj6Ao5b2T5YmN5oqY5Y+g54q25oCBKSAvLyDlv4XpobtcXG4gICAgICAgICAgICAu6YCJ5Lit55qE5YiG57G76aKc6ImyKGdldFJhbmdlQ29sb3JzKCkpXFxuICAgICAgICAgLy8gICAu6YCJ5Lit55qE5YiG57G76aKc6ImyKCcjMDk4QUMxJylcXG4gICAgICAgICAgICAu5byA5aeL5omT6YCg5YiG57G7KCk7XFxuICAgIH0sXFxuICAgIOeUn+aIkOeJh+WNlShkLCBodG1sKSB7XFxuICAgICAgICBsZXQgbGlzdCA9IHBkZmEoaHRtbCwg5YiX6KGoKTtcXG4gICAgICAgIGZvciAobGV0IGogaW4gbGlzdCkge1xcbiAgICAgICAgICAgIGxldCBpbWcgPSBwZChsaXN0W2pdLCDlm77niYcpO1xcbiAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiBwZGZoKGxpc3Rbal0sIOagh+mimCksXFxuICAgICAgICAgICAgICAgIGRlc2M6IHBkZmgobGlzdFtqXSwg5o+P6L+wKSxcXG4gICAgICAgICAgICAgICAgaW1nOiBpbWcgKyAnQFJlZmVyZXI9JyArIGltZyxcXG4gICAgICAgICAgICAgICAgdXJsOiBwZChsaXN0W2pdLCDpk77mjqUpLnJlcGxhY2UoJ3ZvZHBsYXknLCd2b2RkZXRhaWwnKSArIFxcXCIjaW1tZXJzaXZlVGhlbWUjXFxcIlxcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgfVxcbiAgICB9XFxufSlcXG5cXG4kLmV4cG9ydHMgPSBuZXcg5LiA57qnKCk7XFxuJC5leHBvcnRzXCJ9LHtcImNvbF90eXBlXCI6XCJtb3ZpZV8zXCIs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ICAgICDkvovvvJp7IHRpdGxlOlxcXCLmoIfpopgxXFxcIiwgdXJsOlxcXCJ4eHhcXFwiLCBjb2xfdHlwZTpcXFwic2Nyb2xsX2J1dHRvblxcXCIgfTtcXG4gICAgICogICAgICAgIOWPguaVsOmHh+eUqOWPr+mAieimhuebluaooeW8j++8jOS4jeWGmeeahOWPguaVsOWImeS9v+eUqOm7mOiupDtcXG4gICAgICogICAgICAgIOavlOWmguS8oOWFpSB7IGNvbF90eXBlOlxcXCJ0ZXh0XzFcXFwiIH3vvIzpgqPmnIDnu4jnu5PmnpzlsLHmmK8geyB0aXRsZTpcXFwi5qCH6aKYMVxcXCIsIHVybDpcXFwieHh4XFxcIiwgY29sX3R5cGU6XFxcInRleHRfMVxcXCIgfVxcbiAgICAgKiBAcmV0dXJucyB7Q2F0ZWdvcmllc0hlYWRlcn1cXG4gICAgICovXFxuICAgIGZvbGRMYXlvdXQobGF5b3V0KSB7XFxuICAgICAgICBpZiAodHlwZW9mIGxheW91dCA9PT0gJ29iamVjdCcpIHtcXG4gICAgICAgICAgICBsZXQga2V5cyA9IE9iamVjdC5rZXlzKGxheW91dClcXG4gICAgICAgICAgICBsZXQgaW5qZWN0SW5kZXggPSBsYXlvdXQuaW5qZWN0SW5kZXggfHwgbGF5b3V0Wyfmipjlj6DmjInpkq7mj5LlhaXooYwnXVxcbiAgICAgICAgICAgIGlmIChsYXlvdXQudGl0bGUgfHwgbGF5b3V0LnVybCB8fCBsYXlvdXQuY29sX3R5cGUgfHwgaW5qZWN0SW5kZXgpIHtcXG4gICAgICAgICAgICAgICAgZm9yIChsZXQgaSA9IDA7IGkgPCBrZXlzLmxlbmd0aDsgaSsrKSB7XFxuICAgICAgICAgICAgICAgICAgICBjb25zdCBrZXkgPSBrZXlzW2ldXFxuICAgICAgICAgICAgICAgICAgICB0aGlzW3N5bWJvbE1hcC5tRm9sZExheW91dF1ba2V5XSA9IGxheW91dFtrZXldO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgdGhyb3cgbmV3IEVycm9yKFxcXCLor7fkvKDlhaXmraPnoa7nmoTmipjlj6DnlYzpnaLlhYPntKDvvIFcXFwiKVxcbiAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAvLyBpbmplY3RJbmRleCDmipjlj6DmjInpkq7mj5LlhaXnrKwgaW5qZWN0SW5kZXgg6KGMXFxuICAgICAgICAgICAgaWYgKGluamVjdEluZGV4KSB7XFxuICAgICAgICAgICAgICAgIGlmICghKHR5cGVvZiAoaW5qZWN0SW5kZXgpID09PSAnbnVtYmVyJykpIHtcXG4gICAgICAgICAgICAgICAgICAgIHRocm93IG5ldyBFcnJvcihcXFwi5oqY5Y+g5oyJ6ZKu5o+S5YWl6KGM6K+35Lyg5YWl5pWw5a2X77yBXFxcIilcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICBpZiAoaW5qZWN0SW5kZXggPCAxKSB7XFxuICAgICAgICAgICAgICAgICAgICB0aHJvdyBuZXcgRXJyb3IoXFxcIuaKmOWPoOaMiemSruaPkuWFpeihjOivt+S8oOWFpeWkp+S6jiAwIOeahOaVtOaVsO+8gVxcXCIpXFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgaWYgKGluamVjdEluZGV4ID4gdGhpc1tzeW1ib2xNYXAubUZvbGRJbmRleF0pIHtcXG4gICAgICAgICAgICAgICAgICAgIHRocm93IG5ldyBFcnJvcihcXFwi5oqY5Y+g5oyJ6ZKu5o+S5YWl6KGM5LiN5b6X5aSn5LqO5pi+56S65oqY5Y+g6KGM5pWw77yB6K+36LCD55SoIC5mb2xkSW5kZXgoaW5kZXgpIOaIliAu56ys5Yeg6KGM5byA5aeL5oqY5Y+gKGluZGV4KSDkvKDlhaXmraPnoa7nmoTmmL7npLrmipjlj6DooYzmlbBcXFwiKVxcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIHRoaXNbc3ltYm9sTWFwLm1Gb2xkTGF5b3V0XS5pbmplY3RJbmRleCA9IGluamVjdEluZGV4IHx8IDE7XFxuICAgICAgICAgICAgfVxcbiAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICB0aHJvdyBuZXcgRXJyb3IoXFxcIuivt+S8oOWFpeato+ehrueahOaKmOWPoOeVjOmdouWFg+e0oO+8gVxcXCIpXFxuICAgICAgICB9XFxuICAgICAgICByZXR1cm4gdGhpcztcXG4gICAgfSxcXG4gICAgLy8g5b2T5YmN5piv5ZCm5oqY5Y+gXFxuICAgIGZvbGQoaXNGb2xkKSB7XFxuICAgICAgICBpZiAodHlwZW9mIChpc0ZvbGQpID09PSAnc3RyaW5nJykge1xcbiAgICAgICAgICAgIGlzRm9sZCA9IGlzRm9sZCA9PT0gJzEnXFxuICAgICAgICB9XFxuICAgICAgICBpZiAoaXNGb2xkKSB7XFxuICAgICAgICAgICAgdGhpc1tzeW1ib2xNYXAubUZvbGRdID0gJzEnO1xcbiAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICB0aGlzW3N5bWJvbE1hcC5tRm9sZF0gPSAnMCc7XFxuICAgICAgICB9XFxuICAgICAgICByZXR1cm4gdGhpc1xcbiAgICB9LFxcbiAgICBjb2xvcihtQ29sb3IpIHtcXG4gICAgICAgIHRoaXNbc3ltYm9sTWFwLm1Db2xvcl0gPSBtQ29sb3JcXG4gICAgICAgIHJldHVybiB0aGlzXFxuICAgIH0sXFxuICAgIHRhZyhtVGFnKSB7XFxuICAgICAgICB0aGlzW3N5bWJvbE1hcC5tVGFnXSA9IG1UYWdcXG4gICAgICAgIHJldHVybiB0aGlzXFxuICAgIH0sXFxuICAgIGFkZChydWxlT2JqKSB7XFxuICAgICAgICAvLyBsb2coJC5zdHJpbmdpZnkocnVsZU9iaikpXFxuICAgICAgICBpZiAocnVsZU9iai5jb25zdHJ1Y3RvciA9PT0gQXJyYXkpIHtcXG4gICAgICAgICAgICB0aGlzW3N5bWJvbE1hcC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XCJwZFxcXCI6XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBhcnNlID0gcGFyc2VEb207XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGNhc2UgXFxcInBhcnNlRG9tRm9ySHRtbFxcXCI6XFxuICAgICAgICAgICAgICAgICAgICAgICAgY2FzZSBcXFwicGRmaFxcXCI6XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBhcnNlID0gcGFyc2VEb21Gb3JIdG1sO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcXG4gICAgICAgICAgICAgICAgICAgICAgICBkZWZhdWx0OlxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYXJzZSA9IHBhcnNlRG9tO1xcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKHVybFJ1bGVbXFxcIuino+aekOaWueazlVxcXCJdKSB7XFxuICAgICAgICAgICAgICAgICAgICBzd2l0Y2ggKHVybFJ1bGVbXFxcIuino+aekOaWueazlVxcXCJdKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgY2FzZSBcXFwicGFyc2VEb21cXFwiOlxcbiAgICAgICAgICAgICAgICAgICAgICAgIGNhc2UgXFxcInBkXFxcIjpcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcGFyc2UgPSBwYXJzZURvbTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XFxuICAgICAgICAgICAgICAgICAgICAgICAgY2FzZSBcXFwicGFyc2VEb21Gb3JIdG1sXFxcIjpcXG4gICAgICAgICAgICAgICAgICAgICAgICBjYXNlIFxcXCJwZGZoXFxcIjpcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcGFyc2UgPSBwYXJzZURvbUZvckh0bWw7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGRlZmF1bHQ6XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBhcnNlID0gcGFyc2VEb207XFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgdXJsID0gcGFyc2Uoc3JjLCBtVXJsUnVsZSk7XFxuICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIGlmICh1cmxSdWxlLmRlYWxVcmwpIHtcXG4gICAgICAgICAgICAgICAgdXJsID0gdXJsUnVsZS5kZWFsVXJsKHVybClcXG4gICAgICAgICAgICB9IGVsc2UgaWYgKHVybFJ1bGVbJ+S6jOasoeWkhOeQhiddKSB7XFxuICAgICAgICAgICAgICAgIHVybCA9IHVybFJ1bGVbJ+S6jOasoeWkhOeQhiddKHVybClcXG4gICAgICAgICAgICB9XFxuICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgIGlmICh1cmxSdWxlLnN0YXJ0c1dpdGgoXFxcIkBqczpcXFwiKSkge1xcbiAgICAgICAgICAgICAgICB1cmwgPSB0aGlzLmV2YWxKU1J1bGUoc3JjLCB1cmxSdWxlKTtcXG4gICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICB1cmwgPSBwYXJzZURvbShzcmMsIHVybFJ1bGUpO1xcbiAgICAgICAgICAgIH1cXG4gICAgICAgIH1cXG4gICAgICAgIHJldHVybiB1cmwgfHwgXFxcIlxcXCI7XFxuICAgIH0sXFxuICAgIGJ1aWxkKCkge1xcbiAgICAgICAgLy8g5qOA5rWL5piv5ZCm5Lyg5YWl6ZyA6KaB55qE5Y+C5pWwXFxuICAgICAgICB0aGlzLmNoZWNrUGFyYW1zKClcXG4gICAgICAgIC8vIOavj+S4gOS4quWIhuexu+eahOWUr+S4gOagh+ivhlxcbiAgICAgICAgbGV0IG1UYWcgPSB0aGlzW3N5bWJvbE1hcC5tVGFnXSB8fCBcXFwiXFxcIlxcbiAgICAgICAgLy/nv7vp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sZXQgZm9sZExheW91dCA9IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogdGhpc1tzeW1ib2xNYXAubUZvbGRMYXlvdXRdLnRpdGxlIHx8ICh0aGlzW3N5bWJvbE1hcC5tRm9sZF0gPT09ICcxJyA/ICfigJzigJzigJ3igJ08Yj48c3BhbiBzdHlsZT1cXFwiY29sb3I6ICNGRjAwMDBcXFwiPuKIqDwvc3Bhbj48L2I+JyA6ICfigJzigJzigJ3igJ08Yj48c3BhbiBzdHlsZT1cXFwiY29sb3I6ICMxYWFkMTlcXFwiPuKIpzwvc3Bhbj48L2I+JyksXFxuICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiB0aGlzW3N5bWJvbE1hcC5tRm9sZExheW91dF0udXJsIHx8ICQoXFxcImhpa2VyOi8vZW1wdHkjbm9IaXN0b3J5I1xcXCIpLmxhenlSdWxlKChwYXJhbXMpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcHV0TXlWYXIocGFyYW1zLm1UYWcgKyBwYXJhbXMuVkFSTUFQLkZPTEQsIGdldE15VmFyKHBhcmFtcy5tVGFnICsgcGFyYW1zLlZBUk1BUC5GT0xELCBwYXJhbXMuaXNGb2xkKSA9PT0gJzEnID8gJzAnIDogJzEnKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZWZyZXNoUGFnZShmYWxzZSk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9lbXB0eVxcXCJcXG4gICAgICAgICAgICAgICAgICAgICAgICB9LCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1UYWc6IG1UYWcsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlzRm9sZDogdGhpc1tzeW1ib2xNYXAubUZvbGRdLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBWQVJNQVA6IHRoaXMuVkFSTUFQXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSksXFxuICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6IHRoaXNbc3ltYm9sTWFwLm1Gb2xkTGF5b3V0XS5jb2xfdHlwZSB8fCBcXFwic2Nyb2xsX2J1dHRvblxcXCIsXFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICB0aGlzW3N5bWJvbE1hcC5tTGF5b3V0XS5wdXNoKGZvbGRMYXlvdXQpXFxuICAgICAgICAgICAgICAgIH1cXG5cXG4gICAgICAgICAgICAgICAgLy/lhbfkvZPliJfooajkuIvnmoTliIbnsbtcXG4gICAgICAgICAgICAgICAgbGV0IHN1Yl9jYXRlZ29yaWVzID0gW107XFxuICAgICAgICAgICAgICAgIGlmIChjYXRlZ29yeS5zdWJMaXN0UnVsZS5zdGFydHNXaXRoKFxcXCJAanM6XFxcIikpIHtcXG4gICAgICAgICAgICAgICAgICAgIHN1Yl9jYXRlZ29yaWVzID0gdGhpcy5ldmFsSlNSdWxlKGNhdGVnb3J5Lmxpc3QsIGNhdGVnb3J5LnN1Ykxpc3RSdWxlKVxcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgc3ViX2NhdGVnb3JpZXMgPSBwYXJzZURvbUZvckFycmF5KGNhdGVnb3J5Lmxpc3QsIGNhdGVnb3J5LnN1Ykxpc3RSdWxlKTtcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICBpZiAoaW5kZXggPCAodGhpc1tzeW1ib2xNYXAubUZvbGRJbmRleF0gfHwgMSkpIHtcXG4gICAgICAgICAgICAgICAgICAgIHN1Yl9jYXRlZ29yaWVzLmZvckVhY2goKGl0ZW0sIGtleSkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGxldCB0aXRsZSA9IHRoaXMuZ2V0VGl0bGUoaXRlbSwgY2F0ZWdvcnkpXFxuICAgICAgICAgICAgICAgICAgICAgICAgbGV0IHVybCA9IHRoaXMuZ2V0VXJsKGl0ZW0sIGNhdGVnb3J5KVxcblxcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXNbc3ltYm9sTWFwLm1MYXlvdXRdLnB1c2goe1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aXRsZToga2V5LnRvU3RyaW5nKCkgPT09IGNhdGVfdGVtcFtpbmRleF0gPyAn4oCc4oCc4oCd4oCdPGI+PGZvbnQgY29sb3I9JyArIHRoaXNbc3ltYm9sTWFwLm1Db2xvcl0gKyAnPicgKyB0aXRsZSArICcgPC9mb250PjwvYj4nIDogdGl0bGUsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJCh1cmwpLmxhenlSdWxlKChwYXJhbXMpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxldCBuZXdfY2F0ZSA9IFtdXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAocGFyYW1zLmluZGV4ID09PSAwKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcGFyYW1zLmNhdGVfdGVtcC5mb3JFYWNoKChjYXRlLCBpbmRleCkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBuZXdfY2F0ZS5wdXNoKGluZGV4ID09PSAwID8gcGFyYW1zLmtleS50b1N0cmluZygpIDogXFxcIjBcXFwiKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYXJhbXMuY2F0ZV90ZW1wW3BhcmFtcy5pbmRleF0gPSBwYXJhbXMua2V5LnRvU3RyaW5nKClcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHB1dE15VmFyKHBhcmFtcy50YWcgKyBwYXJhbXMuVkFSTUFQLkNBVEVHT1JZLCBKU09OLnN0cmluZ2lmeShwYXJhbXMuaW5kZXggPT09IDAgPyBuZXdfY2F0ZSA6IHBhcmFtcy5jYXRlX3RlbXApKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcHV0TXlWYXIocGFyYW1zLnRhZyArIHBhcmFtcy5WQVJNQVAuVVJMLCBpbnB1dClcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJlZnJlc2hQYWdlKHRydWUpXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcImhpa2VyOi8vZW1wdHlcXFwiXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNhdGVfdGVtcDogY2F0ZV90ZW1wLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW5kZXg6IGluZGV4LFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgVkFSTUFQOiB0aGlzLlZBUk1BUCxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRhZzogbVRhZyxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGtleToga2V5LFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcGFnZTogdGhpc1tzeW1ib2xNYXAubVBhZ2VdLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KSxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6ICdzY3JvbGxfYnV0dG9uJyxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgICAgIHRoaXNbc3ltYm9sTWFwLm1MYXlvdXRdLnB1c2goe1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiBcXFwiYmxhbmtfYmxvY2tcXFwiXFxuICAgICAgICAgICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmICh0aGlzW3N5bWJvbE1hcC5tRm9sZF0gPT09ICcwJykge1xcbiAgICAgICAgICAgICAgICAgICAgc3ViX2NhdGVnb3JpZXMuZm9yRWFjaCgoaXRlbSwga2V5KSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgbGV0IHRpdGxlID0gdGhpcy5nZXRUaXRsZShpdGVtLCBjYXRlZ29yeSlcXG4gICAgICAgICAgICAgICAgICAgICAgICBsZXQgdXJsID0gdGhpcy5nZXRVcmwoaXRlbSwgY2F0ZWdvcnkpXFxuXFxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpc1tzeW1ib2xNYXAubUxheW91dF0ucHVzaCh7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiBrZXkudG9TdHJpbmcoKSA9PT0gY2F0ZV90ZW1wW2luZGV4XSA/ICfigJzigJzigJ3igJ08Yj48Zm9udCBjb2xvcj0nICsgdGhpc1tzeW1ib2xNYXAubUNvbG9yXSArICc+JyArIHRpdGxlICsgJyA8L2ZvbnQ+PC9iPicgOiB0aXRsZSxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiAkKHVybCkubGF6eVJ1bGUoKHBhcmFtcykgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcGFyYW1zLmNhdGVfdGVtcFtwYXJhbXMuaW5kZXhdID0gcGFyYW1zLmtleS50b1N0cmluZygpXFxuXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwdXRNeVZhcihwYXJhbXMudGFnICsgcGFyYW1zLlZBUk1BUC5DQVRFR09SWSwgSlNPTi5zdHJpbmdpZnkocGFyYW1zLmNhdGVfdGVtcCkpXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwdXRNeVZhcihwYXJhbXMudGFnICsgcGFyYW1zLlZBUk1BUC5VUkwsIGlucHV0KVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmVmcmVzaFBhZ2UodHJ1ZSlcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9lbXB0eVxcXCJcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSwge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY2F0ZV90ZW1wOiBjYXRlX3RlbXAsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpbmRleDogaW5kZXgsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBWQVJNQVA6IHRoaXMuVkFSTUFQLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdGFnOiBtVGFnLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAga2V5OiBrZXksXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYWdlOiB0aGlzW3N5bWJvbE1hcC5tUGFnZV0sXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb2xfdHlwZTogJ3Njcm9sbF9idXR0b24nLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgdGhpc1tzeW1ib2xNYXAubUxheW91dF0ucHVzaCh7XFxuICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6IFxcXCJibGFua19ibG9ja1xcXCJcXG4gICAgICAgICAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgfSk7XFxuICAgICAgICB9XFxuICAgIH0sXFxuXFxuICAgIOeVjOmdoihsYXlvdXQpIHtcXG4gICAgICAgIHJldHVybiB0aGlzLmxheW91dChsYXlvdXQpXFxuICAgIH0sXFxuICAgIOWIhuexu+mTvuaOpSh0cnVlVXJsKSB7XFxuICAgICAgICByZXR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cXG4gICAgICAgIGxldCB0cnVlX3VybCA9ICcnXFxuICAgICAgICBmb3IgKGxldCBpID0gMDsgaSA8IHRoaXMucmVnZXhNYXAubGVuZ3RoOyBpKyspIHtcXG4gICAgICAgICAgICBsZXQgcmVnT2JqID0gdGhpcy5yZWdleE1hcFtpXTtcXG4gICAgICAgICAgICBsZXQgdXJsRXhwID0gcmVnT2JqLnJlZztcXG4gICAgICAgICAgICBpZiAodHlwZW9mIHVybEV4cCA9PT0gJ3N0cmluZycpIHtcXG4gICAgICAgICAgICAgICAgdXJsRXhwID0gbmV3IFJlZ0V4cCh1cmxFeHApXFxuICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIGlmICh1cmxFeHAudGVzdCh0aGlzLnBhcmFtcy51cmwpKSB7XFxuICAgICAgICAgICAgICAgIGlmICh0aGlzLnBhcmFtcy5kZWJ1Zykge1xcbiAgICAgICAgICAgICAgICAgICAgbG9nKHVybEV4cC50b1N0cmluZygpKVxcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIHRydWVfdXJsID0gcmVnT2JqLmV4ZWMoKTtcXG4gICAgICAgICAgICAgICAgYnJlYWs7XFxuICAgICAgICAgICAgfVxcbiAgICAgICAgfVxcbiAgICAgICAgaWYgKHRydWVfdXJsKSB7XFxuICAgICAgICAgICAgcmV0dXJuIHRydWVfdXJsO1xcbiAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICByZXR1cm4gdGhpcy5wYXJhbXMudXJsXFxuICAgICAgICB9XFxuICAgIH0sXFxuICAgIOiOt+WPluWkhOeQhue7k+aenCgpIHtcXG4gICAgICAgIHJldHVybiB0aGlzLmV4ZWMoKVxcbiAgICB9LFxcbiAgICDpk77mjqUodXJsKSB7XFxuICAgICAgICByZXR1cm4gdGhpcy5iYXNlVXJsKHVybClcXG4gICAgfSxcXG4gICAg6aG156CBKHBhZ2UpIHtcXG4gICAgICAgIHJldHVybiB0aGlzLnBhZ2UocGFnZSlcXG4gICAgfSxc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