Advertisement
xiaomianao666

邀您一起看:MX影视-红丹心

Jul 10th, 2022
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 海阔视界规则分享,当前分享的是:二级页面详情¥page_detail¥MX影视-红丹心@@eyJkYXRhIjoie1wiYXNzb2NpYXRlZE1vZGVsc01hcEZvckpvaW5UYWJsZVwiOnt9LFwiYXNzb2NpYXRlZE1vZGVsc01hcFdpdGhGS1wiOnt9LFwiYXNzb2NpYXRlZE1vZGVsc01hcFdpdGhvdXRGS1wiOnt9LFwiZmllbGRzVG9TZXRUb0RlZmF1bHRcIjpbXSxcImlkXCI6MCxcImxhc3RfY2hhcHRlcl9ydWxlXCI6XCJqczpcXG5ldmFsKEpTT04ucGFyc2UoZmV0Y2goJ2hpa2VyOi8vcGFnZS9jaGFwdGVyJywge30pKS5ydWxlKTtcIixcImxpc3RUb0NsZWFyQXNzb2NpYXRlZEZLXCI6W10sXCJsaXN0VG9DbGVhclNlbGZGS1wiOltdLFwicGFnZUxpc3RcIjpbe1wiY29sX3R5cGVcIjpcIm1vdmllXzNcIixcIm5hbWVcIjpcIuaOpeWPo+aVsOaNrjIwMjIvNC8yNVwiLFwicGF0aFwiOlwiUmVzQ29kZVwiLFwicnVsZVwiOlwi5LyY6LSoQOmSn+eJueW9seinhj1odHRwczovL2FwcC56dGV5cy5jb20vYXBpLnBocC92MS52b2Qj6ZKf54m55b2x6KeGXFxu5LyY6LSoQOW9semYhemYgT1odHRwOi8vMjIxLjIzNi4xOC4xMjo2NjUvYXBpLnBocC92MS52b2Qj5b2x6ZiF6ZiBXFxu5LyY6LSoQOS8mOinhuW9seinhj1odHRwOi8vYXBwLnlzeXMuYXNpYS9sdmRvdV9hcGkucGhwL3YxLnZvZCPkvJjop4blvbHop4ZcXG7kvJjotKhA5b2x6KeG5aSn5YWoPWh0dHBzOi8vYXBwLm9rbWVkY29zLmNvbS9hcGkucGhwL3YxLnZvZCPlvbHop4blpKflhahcXG7kvJjotKhA6Zuo5p6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MuY246OTAvYXBpLnBocC92MS52b2Qj6Zi/6YeM5b2x6KeGXFxu5pmu6YCaQOeIseeUteW9sT1odHRwczovL3d3dy5pZGlhbnlpbmcuY29tLmNuL21vZ2FpX2FwaS5waHAvdjEudm9kI+eIseeUteW9sVxcbuaZrumAmkBVNeW9seinhj1odHRwczovL2FwcHgudXkwNy5jb20vYXBpLnBocC92MS52b2QjVTXlvbHop4ZcXG7mma7pgJpAT0vlvbHop4Y9aHR0cDovLzEyMy5vazAwLnh5ei9hcGkucGhwL3YxLnZvZCNPS+W9seinhlxcbuaZrumAmkBNWOW9seinhj1odHRwOi8vbWtrLmdvdGthLnRvcC9hcGkucGhwL3YxLnZvZCNcXG7mma7pgJpANjnnvo7liac9aHR0cHM6Ly93d3cuNjltai5jb20vYXBpLnBocC92MS52b2QjXFxu5pmu6YCaQDEwODBLSz1odHRwOi8vMTIzLjI1MGlkYy5jb20vbW9nYWlfYXBpLnBocC92MS52b2QjMTA4MEtLXFxu56We6amsQOW9seinhumYgT1odHRwOi8vMjE2Ljk4LjEwLjg1L2FwaS5waHAvaXB0di92b2QvI+W9seinhumYgVxcbuelnumprEDlsI/nhornjKtUVj1odHRwOi8vdHYyLmhldGFveXMudmlwL2FwaS5waHAvaXB0di92b2QvI+Wwj+eGiueMq1RWXFxu56We6amsQOWwj+WNl1RWPWh0dHA6Ly9uMjkzLm5neXMueHl6L212L2FwaS5waHAvQ2hlbmdjaGVuZy92b2QvI+Wwj+WNl1RWXFxu56We6amsQOWkqeepulRWPWh0dHA6Ly90di50a3lzLnR2L2FwaS5waHAvaXB0di92b2QvI+WkqeepulRWXFxu56We6amsQOWxsealguW9seinhj1odHRwOi8vZHk2LmRjZDEuY24vYXBpLnBocC9pcHR2L3ZvZC8j5bGx5qWC5b2x6KeGXFxu56We6amsQOafoOaqrFRWPWh0dHA6Ly8xMDYuMTIuMTEzLjkwOjc1NzUvYXBpLnBocC9pcHR2L3ZvZC8j5p+g5qqsVFZcXG7npZ7pqaxA6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AgICAgICAgICAgICAgIGlmICgvMzdcXFxcLjE2MXwyMTZcXFxcLjk4fHBob2ViZXxoZnlzOHxmZWlmYW4xMnx0dnp5fGhkeWFuZ3R2fHRreXN8dGVnb3V5cy8udGVzdChsaW5rKSkge1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIGhtdXJsID0gbGluayArICc/YWM9bGlzdCZ6bT0nICsga2V5ICsgJyZwYWdlPWZ5cGFnZSc7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICB2YXIgaG11cmwgPSBsaW5rICsgJz9hYz1saXN0JndkPScgKyBrZXkgKyAnJnBhZ2U9ZnlwYWdlJztcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgIGlmICgvZGlqaWF4aWEvLnRlc3QobGluaykpIHtcXG4gICAgICAgICAgICAgICAgICAgIGxpbmsgPSAnaHR0cDovL3d3dy5kaWppYXhpYS5jb20vYXBpLnBocC9hcHAvJ1xcbiAgICAgICAgICAgICAgICB9O1xcbiAgICAgICAgICAgICAgICBpZiAobGluay5pbmRleE9mKCdhcGkucGhwL2FwcC8nKSAhPSAtMSkge1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIGhtdXJsID0gbGluayArICdzZWFyY2g/cGc9ZnlwYWdlJnRleHQ9JyArIGtleSArICcmdG9rZW49JztcXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChsaW5rLmluZGV4T2YoJ3hnYXBwLnBocC92MS8nKSAhPSAtMSkge1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIGhtdXJsID0gbGluayArICdzZWFyY2g/cGc9ZnlwYWdlJnRleHQ9JyArIGtleTtcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgIGlmICgvaW9wZW55dW4vLnRlc3QobGluaykpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgaG11cmwgPSBsaW5rICsgJy9saXN0P3BhZ2U9ZnlwYWdlJmxpbWl0PTEwJndkPScgKyBrZXk7XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnP3BhZ2U9ZnlwYWdlJmxpbWl0PTEwJndkPScgKyBrZXk7XFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgaXRlbXMucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiBsaXN0W2pdLnRpdGxlLFxcbiAgICAgICAgICAgICAgICBpbWc6IGxpc3Rbal0uaW1nLFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoJ2hpa2VyOi8vZW1wdHkjeCMnICsgaG11cmwgKyAnI3gjJyArIGxpbmsgKyAnI3gjJyArIGxpdGl0ICsgJyN4IycgKyBrZXkgKyAnI3gjJykucnVsZSgoKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAkLnJlcXVpcmUoJ2hpa2VyOi8vcGFnZS9zZWFyZXJqJyk7XFxuICAgICAgICAgICAgICAgIH0pLFxcbiAgICAgICAgICAgICAgICBjb2xfdHlwZTogJ2ljb25fcm91bmRfc21hbGxfNCdcXG4gICAgICAgICAgICAgICAgLy9jb2xfdHlwZTogJ3RleHRfMydcXG4gICAgICAgICAgICAgICAgLy9saW5rOmxpbmssXFxuICAgICAgICAgICAgICAgIC8vdHlwZTogaVxcbiAgICAgICAgICAgIH0pO1xcblxcbiAgICAgICAgfSAvL2ZvciBqXFxuXFxuXFxuICAgIH0gLy9mb3IgaVxcblxcbn0gLy9lbmQgbW9kZSAwXFxuXFxuXFxucmVzLmRhdGEgPSBpdGVtcztcXG5zZXRIb21lUmVzdWx0KHJlcyk7XCJ9LHtcImNvbF90eXBlXCI6XCJtb3ZpZV8zXCIsXCJuYW1lXCI6XCJBUFDliIbnsbvliJfooahcI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LzIuMTQgKGRhcnQ6aW8pfSc7XFxuICAgIH0gZWxzZSBpZiAoL2RpamlheGlhLy50ZXN0KG11cmwpKSB7XFxuICAgICAgICB2YXIgbGluayA9ICdodHRwOi8vd3d3LmRpamlheGlhLmNvbS9hcGkucGhwL2FwcC92aWRlb19kZXRhaWw/aWQ9JyArIHVybDtcXG4gICAgfVxcbiAgICBpdGVtcy5wdXNoKHtcXG4gICAgICAgIHRpdGxlOiB0aXRsZSxcXG4gICAgICAgIHBpY191cmw6IGltZyArICdAUmVmZXJlcj0nLFxcbiAgICAgICAgdXJsOiAkKGxpbmspLnJ1bGUoKCkgPT4ge1xcbiAgICAgICAgICAgIHZhciByZXMgPSB7fTtcXG4gICAgICAgICAgICB2YXIgaXRlbXMgPSBbXTtcXG4gICAgICAgICAgICBpdGVtcy5wdXNoKHtcXG4gICAgICAgICAgICAgICAgdGl0bGU6ICcnLFxcbiAgICAgICAgICAgICAgICBkZXNjOiAnMjU1JiZmbG9hdCcsXFxuICAgICAgICAgICAgICAgIHVybDogJycsXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAneDVfd2Vidmlld19zaW5nbGUnXFxuICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgcmVmcmVzaFg1V2ViVmlldygnJyk7XFxuICAgICAgICAgICAgdmFyIGh0bWwgPSBKU09OLnBhcnNlKGdldFJlc0NvZGUoKSk7XFxuICAgICAgICAgICAgdmFyIG15dXJsID0gTVlfVVJMLm1hdGNoKC8oW1xcXFxTXSo/OlxcXFwvXFxcXC9bXFxcXFNdKj8pXFxcXC8vKVsxXTtcXG4gICAgICAgICAgICB0cnkge1xcbiAgICAgICAgICAgICAgICBldmFsKEpTT04ucGFyc2UoZmV0Y2goJ2hpa2VyOi8vcGFnZS9hcHBtb3ZsaXN0Jywge30pKS5ydWxlKTtcXG4gICAgICAgICAgICB9IGNhdGNoIChlKSB7fVxcbiAgICAgICAgICAgIHJlcy5kYXRhID0gaXRlbXM7XFxuICAgICAgIC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GFyc2UgJiYgKGNvbnRzW2dldE15VmFyKHRpdGxlLCAnMCcpXS5wbGF5ZXJfaW5mby5wYXJzZSkuaW5kZXhPZihcXFwiPVxcXCIpICE9IC0xKSB7XFxuICAgICAgICAgICAgICAgIHZhciBqaWVrID0gKGNvbnRzW2dldE15VmFyKHRpdGxlLCAnMCcpXS5wbGF5ZXJfaW5mby5wYXJzZSkucmVwbGFjZSgvXFxcXC5cXFxcLi9nLCBcXFwiLlxcXCIpLnNwbGl0KCcsJylbMF07XFxuICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgdmFyIGppZWsgPSBcXFwiXFxcIjtcXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgLy9zZXRFcnJvcihqaWVrKTsgICAgICAgICAgICAgICAgXFxuICAgICAgICB9XFxuICAgIH0gY2F0Y2ggKGUpIHt9XFxuICAgIC8vamlla+aLvOaOpVxcbiAgICBpZiAoamllayAhPSAnJyAmJiBqaWVrICE9IG51bGwpIHtcXG4gICAgICAgIGlmIChqaWVrLnN1YnN0cmluZygwLCA0KSA9PSAnaHR0cCcpIHtcXG4gICAgICAgICAgICBqaWVrID0gamllaztcXG4gICAgICAgIH0gZWxzZSBpZiAoamllay5zdWJzdHJpbmcoMCwgMikgPT0gJ1xcXFwvXFxcXC8nKSB7XFxuICAgICAgICAgICAgamllayA9ICdodHRwczonICsgamllaztcXG4gICAgICAgIH1cXG4gICAgfSBlbHNlIHtcXG4gICAgICAgIGppZWsgPSBcXFwiXFxcIjtcXG4gICAgfVxcbiAgICAvL+WvueWkseaViOaOpeWPo+i/m+ihjOabv+aNolxcbiAgICBpZiAoL2Nva2Vtdi8udGVzdChteXVybCkgJiYgL2Nva2VxaWV8eGlufDkwbW0vLnRlc3QocHRhYikpIHtcXG4gICAgICAgIGppZWsgPSAnaHR0cHM6Ly9wbGF5ZXIuOTBtbS5tZS9wbGF5LnBocD91cmw9JztcXG4gICAgfSBlbHNlIGlmICgvanNvblxcXFwubT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2h0dHBzOi8vd3d3LmZ1bjRrLmNvbS9hcGxheWVyLz91cmw9JztcXG4gICAgfSBlbHNlIGlmICgvamh5dW5cXFxcLnBocC8udGVzdChqaWVrKSkge1xcbiAgICAgICAgamllayA9IGppZWsucmVwbGFjZSgnaHR0cDovL3N2aXAuamh5dW4uanguY246MTIzNC9qaHl1bi5waHA/dXJsPScsICdodHRwczovL2FwaS5qaGR5dy52aXAvP3VybD0nKTtcXG4gICAgfSBlbHNlIGlmICgvd3d3XFxcXC5haWxlbW9cXFxcLm1lLy50ZXN0KGppZWspKSB7XFxuICAgICAgICBqaWVrID0gamllay5yZXBsYWNlKCdhaWxlbW8nLCAnYWlsZW1vbycpO1xcbiAgICB9O1xcbiAgICAvL+aJk+WNsOaOpeWPo1xcbiAgICB0cnkge1xcbiAgICAgICAgaWYgKGogPT0gJzAnKSB7XFxuICAgICAgICAgICAgaWYgKGh0bWwuZGF0YS52b2RfdXJsX3dpdGhfcGxheWVyKSB7XFxuICAgICAgICAgICAgICAgIGxvZygnXFxcXG7nur/ot6/vvJonICsgcHRhYiArICdcXFxcbuinhumike+8micgKyB2bGluayArICdcXFxcbicgKyAn6Kej5p6Q5o6l5Y+j77yaXFxcXG4nICsgamllayk7XFxuICAgICAgICAgICAgfSBlbHNlIGlmIChodG1sLmRhdGEudm9kX2luZm8gJiYgaHRtbC5kYXRhLnZvZF9pbmZvLnZvZF91cmxfd2l0aF9wbGF5ZXIpIHtcXG4gICAgICAgICAgICAgICAgbG9nKCdcXFxcbue6v+i3r++8micgKyBwdGFiICsgJ1xcXFxu6KeG6aKR77yaJyArIHZsaW5rICsgJ1xcXFxuJyArICfop6PmnpDmjqXlj6PvvJpcXFxcbicgKyBqaWVrKTtcXG4gICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICBpZiAoY29udHNbZ2V0TXlWYXIodGl0bGUsICcwJyldLnBsYXllcl9pbmZvLnBhcnNlMiAmJiAoY29udHNbZ2V0TXlWYXIodGl0bGUsICcwJyldLnBsYXllcl9pbmZvLnBhcnNlMikuaW5kZXhPZihcXFwiPVxcXCIpICE9IC0xKSB7XFxuICAgICAgICAgICAgICAgICAgICBsb2coJ1xcXFxu57q/6Lev77yaJyArIHB0YWIgKyAnXFxcXG7op4bpopHvvJonICsgdmxpbmsgKyAnXFxcXG4nICsgJ+ino+aekOaOpeWPo++8mlxcXFxuJyArIGNvbnRzW2dldE15VmFyKHRpdGxlLCAnMCcpXS5wbGF5ZXJfaW5mby5wYXJzZTIucmVwbGFjZSgvXFxcXC5cXFxcLi9nLCBcXFwiLlxcXCIpLnJlcGxhY2UoL1xcXFwsL2csIFxcXCJcXFxcblxcXFxuXFxcIikpO1xcbiAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKGNvbnRzW2dldE15VmFyKHRpdGxlLCAnMCcpXS5wbGF5ZXJfaW5mby5wYXJzZSAmJiAoY29udHNbZ2V0TXlWYXIodGl0bGUsICcwJyldLnBsYXllcl9pbmZvLnBhcnNlKS5pbmRleE9mKFxcXCI9XFxcIikgIT0gLTEpIHtcXG4gICAgICAgICAgICAgICAgICAgIGxvZygnXFxcXG7nur/ot6/vvJonICsgcHRhYiArICdcXFxcbuinhumike+8micgKyB2bGluayArICdcXFxcbicgKyAn6Kej5p6Q5o6l5Y+j77yaXFxcXG4nICsgY29udHNbZ2V0TXlWYXIodGl0bGUsICcwJyldLnBsYXllcl9pbmZvLnBhcnNlLnJlcGxhY2UoL1xcXFwuXFxcXC4vZywgXFxcIi5cXFwiKS5yZXBsYWNlKC9cXFxcLC9nLCBcXFwiXFxcXG5cXFxcblxcXCIpKTtcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgIGxvZygnXFxcXG7nur/ot6/vvJonICsgcHRhYiArICdcXFxcbuinhumike+8micgKyB2bGluayArICdcXFxcbicgKyAn6Kej5p6Q5o6l5Y+j77yaXFxcXG4nICsgamllayk7XFxuICAgICAgICAgICAgICAgIH1cXG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odG1sfGJpbGliaWxpfGl4aWd1YS8pICE9IC0xKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgLy9odG1s572R6aG16LCD55So5pat5o+S6Kej5p6QXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGVuRG4gPSBKU09OLnBhcnNlKGZldGNoKCdoaWtlcjovL2ZpbGVzL3J1bGVzL3h5cS9hcHBtc2V0Lmpzb24nLCB7fSkpLmVuRG47XFxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGVuRG4gPT0gJzEnKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxvZygn6LCD55So5pat5o+S6Kej5p6QaHRtbCcpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBldmFsKFxcXCJ2YXIgY29uZmlnID1cXFwiICsgZmV0Y2goXFxcImhpa2VyOi8vZmlsZXMvY2FjaGUvTXlQYXJzZVNldC5qc29uXFxcIikpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBldmFsKGZldGNoKGNvbmZpZy5jaikpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gYXl0bVBhcnNlKHJlc3VybCk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJlc3VybFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH07XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9cXFxcLm0zdTh8XFxcXC5tcDR8b2JqXFxcXC90b3N8bmV0ZWFzZVxcXFwuY29tLy50ZXN0KHJlc3VybCkgJiYgL2h0dHAvLnRlc3QocmVzdXJsKSAmJiAhL1xcXFwuaHRtbC8udGVzdChyZXN1cmwpICYmICEvXFxcXD1odHRwLy50ZXN0KHJlc3VybCkgJiYgcHRhYiAhPSAnZHVvZHVvenknKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKC93a2ZpbGUvLnRlc3QocmVzdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVzdXJsICsgJzt7UmVmZXJlckBodHRwczovL2ZhbnR1YW4ud2tmaWxlLmNvbS99J1xcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAvXFxcXD1odC8udGVzdChyZXN1cmwpID8gcmVzdXJsLnN1YnN0cmluZyhyZXN1cmwuaW5kZXhPZignPWh0JykgKyAxKSA6IHJlc3VybCArICcjaXNWaWRlbz10cnVlIyc7XFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAvL+iwg+eUqOaWreaPkumAmueUqOWHveaVsOino+aekFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBlbkRuID0gSlNPTi5wYXJzZShmZXRjaCgnaGlrZXI6Ly9maWxlcy9ydWxlcy94eXEvYXBwbXNldC5qc29uJywge30pKS5lbkRuO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChlbkRuID09ICcxJykge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsb2coJ+iwg+eUqOaWreaPkumAmueUqOWHveaVsOino+aekFxcXFxuJyArIHB0YWIgKyAnKOmAmueUqOWHveaVsCknKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZXZhbChcXFwidmFyIGNvbmZpZyA9XFxcIiArIGZldGNoKFxcXCJoaWtlcjovL2ZpbGVzL2NhY2hlL015UGFyc2VTZXQuanNvblxcXCIpKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZXZhbChmZXRjaChjb25maWcuY2opKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG5hbWUgPSBwdGFiICsgJyjpgJrnlKjlh73mlbApJztcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFBhcnNlU1tuYW1lXShyZXN1cmwsIG15dXJsKTtcXG5cXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKHB0YWIgPT0gJ2R1b2R1b3p5Jykge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBldmFsKGdldENyeXB0b0pTKCkpO1xcblxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBmdW5jdGlvbiBEZSh3b3JkKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgYSA9IENyeXB0b0pTLmVuYy5VdGY4LnBhcnNlKG1kNSgnclhqV3ZYbDYnKSlcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciB0ID0gQ3J5cHRvSlMuZW5jLlV0ZjgucGFyc2UoJ05YYkhvV0picHNFT2luOGInKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIENyeXB0b0pTLkFFUy5kZWNyeXB0KHdvcmQsIGEsIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdjogdCxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtb2RlOiBDcnlwdG9KUy5tb2RlLkNCQyxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYWRkaW5nOiBDcnlwdG9KUy5wYWQuUGtjczdcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pLnRvU3RyaW5nKENyeXB0b0pTLmVuYy5VdGY4KVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9O1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgZGR6eSA9ICdhaEhnUmowa2NlSGRNYzY2TDV5NCcgKyBiYXNlNjRFbmNvZGUocmVzdXJsKS5zbGljZSgxMCkucmVwbGFjZSgvXFxcXD0vZywnTzBPME8nKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy9odHRwczovL2JvLmRkNTIwLmNjL3hwbGF5L2FwaS5waHBcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy9odHRwczovL2JvLmRkNTIwLmNjL3htcGxheWVyL2FwaS5waHAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBkZHd5ID0gZmV0Y2goJ2h0dHBzOi8vYm8uZGQ1MjAuY2MveG1wbGF5ZXIvZHVvZHVvLnBocCcsIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcXFwiVXNlci1BZ2VudFxcXCI6IE1PQklMRV9VQVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJvZHk6ICd1cmw9JyArIGRkenksXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICdQT1NUJ1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy9sb2coZGR3eSk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBEZShKU09OLnBhcnNlKGRkd3kpLnVybCk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmICgvbWlhb3BhcnR5Ly50ZXN0KHB0YWIpKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJlcXVpcmVDYWNoZSgnaHR0cHM6Ly9jb2RlLmFsaXl1bi5jb20vbHprMjM1NTkvUHVibGljUnVsZS9yYXcvbWFzdGVyL3g1cnVsZS5qcycsIDI0KTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHg1cnVsZSgnaHR0cHM6Ly93d3cuZnVuNGsuY29tL2FwbGF5ZXIvP3VybD0nICsgcmVzdXJsKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVzdXJsXFxuICAgICAgICAgICAgICAgICAgICAgICAgfTtcXG4gICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgfTtcXG4gICAgICAgICAgICAgICAgXFxuICAgICAgICAgICAgICAgIHRyeSB7XFxuICAgICAgICAgICAgICAgICAgICB2YXIgZW5EbiA9IEpTT04ucGFyc2UoZmV0Y2goJ2hpa2VyOi8vZmlsZXMvcnVsZXMveHlxL2FwcG1zZXQuanNvbicsIHt9KSkuZW5EbjtcXG4gICAgICAgICAgICAgICAgICAgIGlmIChlbkRuID09ICcxJyAmJiB2bGluay5tYXRjaCgveW91a3V8bWd0dnxpeGlndWF8cXEuY29tfHFpeWl8bWlndXxiaWxpYmlsaXxzb2h1fHBwdHZ8bGV8MTkwNS5jb20vKSAmJiB2bGluay5zZWFyY2goL2h0bWx8YmlsaWJpbGl8aXhpZ3VhLykgIT0gLTEpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBsb2coJ+W3suW8gOWQr+aWreaPku+8jOWwhuiwg+eUqOaWreaPkuino+aekGh0bWwnKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICBldmFsKFxcXCJ2YXIgY29uZmlnID1cXFwiICsgZmV0Y2goXFxcImhpa2VyOi8vZmlsZXMvY2FjaGUvTXlQYXJzZVNldC5qc29uXFxcIikpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoZmV0Y2goY29uZmlnLmNqKSk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGF5dG1QYXJzZSh2bGluayk7XFxuICAgICAgICAgICAgICAgICAgICB9O1xcbiAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7fVxcbiAgICAgICAgICAgICAgICBcXG4gICAgICAgICAgICAgICAgdmFyIHNyY3VybCA9IGxpbms7XFxuICAgICAgICAgICAgICAgIC8vbG9nKHNyY3VybCk7XFxuICAgICAgICAgICAgICAgIC8v5Yqo5oCB6Kej5p6Q5Luj56CB5byA5aeLXFxuICAgICAgICAgICAgICAgIHRyeSB7XFxuICAgICAgICAgICAgICAgICAgICAvL+WkhOeQhuaMh+WumuinhumikeS4jue6v+i3r1xcbiAgICAgICAgICAgICAgICAgICAgaWYgKC9cXFxcLm0zdTh8XFxcXC5tcDR8b2JqXFxcXC90b3N8bmV0ZWFzZVxcXFwuY29tLy50ZXN0KHNyY3VybCkgJiYgL2h0dHAvLnRlc3Qoc3JjdXJsKSAmJiAhL1xcXFwuaHRtbC8udGVzdChzcmN1cmwpICYmICEvXFxcXD1odHRwLy50ZXN0KHNyY3VybCkpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoL3drZmlsZS8udGVzdChzcmN1cmwpKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBzcmN1cmwgKyAnO3tSZWZlcmVyQGh0dHBzOi8vZmFudHVhbi53a2ZpbGUuY29tL30nXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIC9cXFxcPWh0Ly50ZXN0KHNyY3VybCkgPyBzcmN1cmwuc3Vic3RyaW5nKHNyY3VybC5pbmRleE9mKCc9aHQnKSArIDEpIDogc3JjdXJsICsgJyNpc1ZpZGVvPXRydWUjJztcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9oZDhcXFxcLnB3Ly50ZXN0KHZsaW5rKSAmJiAvXFxcXC5tM3U4fFxcXFwubXA0Ly50ZXN0KHZsaW5rKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB2bGluaztcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoc3JjdXJsLmluZGV4T2YoXFxcIi9zaGFyZS9cXFwiKSAhPSAtMSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHRyeSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBsaW5rID0gc3JjdXJsLnNwbGl0KFxcXCIvc2hhcmVcXFwiKVswXTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGZjID0gZmV0Y2goc3JjdXJsLCB7fSkucmVwbGFjZShcXFwidmFyIHB1cmxcXFwiLCBcXFwidmFyIG1haW5cXFwiKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGZjLmluZGV4T2YoXFxcIm1haW5cXFwiKSAhPSAtMSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1hdCA9IGZjLm1hdGNoKC92YXIgbWFpbi4qPzsvKVswXTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwobWF0KTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwbGF5ID0gKG1haW4uaW5kZXhPZihcXFwiaHR0cFxcXCIpICE9IC0xID8gbWFpbiA6IGxpbmsgKyBtYWluKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBtYWluID0gZmMubWF0Y2goL3VybDouKj9bXFxcXCdcXFxcXFxcIl0oLio/KVtcXFxcJ1xcXFxcXFwiXS8pWzFdO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHBsYXkgPSAobWFpbi5pbmRleE9mKFxcXCJodHRwXFxcIikgIT0gLTEgPyBtYWluIDogbGluayArIG1haW4pXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH07XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwbGF5O1xcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICd4NVdlYlZpZXc6Ly8nICsgKHNyY3VybClcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC85ODN2aXAvLnRlc3Qoc3JjdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBKU09OLnBhcnNlKGZldGNoKHNyY3VybCwge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWFkZXJzOiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcXFwiVXNlci1BZ2VudFxcXCI6IE1PQklMRV9VQVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZWRpcmVjdDogZmFsc2UsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHdpdGhIZWFkZXJzOiB0cnVlXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSkpLmhlYWRlcnMubG9jYXRpb25bMF07XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC94XFxcXC1uXFxcXC5jY3xuaGR6NjY2Ly50ZXN0KHNyY3VybCkgJiYgL1xcXFwuaHRtbHxiaWxpYmlsaS8udGVzdChzcmN1cmwpKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9wZW51cmwodmxpbmspO1xcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgLy/lpITnkIbmjIflrprop4bpopHlkoznur/ot6/nu5PmnZ9cXG4gICAgICAgICAgICAgICAgICAgIC8vLS0tLeWIhuWJsue6vy0tLS0vL1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIHNjb2RlID0gSlNPTi5wYXJzZShmZXRjaChzcmN1cmwsIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBoZWFkZXJzOiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJVc2VyLUFnZW50XFxcIjogXFxcIm9raHR0cC80LjEuMFxcXCJcXG4gICAgICAgICAgICAgICAgICAgICAgICB9LFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJlZGlyZWN0OiBmYWxzZSxcXG4gICAgICAgICAgICAgICAgICAgICAgICB3aXRoU3RhdHVzQ29kZTogdHJ1ZVxcbiAgICAgICAgICAgICAgICAgICAgfSkpO1xcbiAgICAgICAgICAgICAgICAgICAgLy9sb2coc2NvZGUpO1xcbiAgICAgICAgICAgICAgICAgICAgaWYgKHNjb2RlLnN0YXR1c0NvZGUgPT0gJzMwMicgfHwgc2NvZGUuc3RhdHVzQ29kZSA9PSAnMzAxJykge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIC8v5omT5byA6Kej5p6Q5pyJMzAy6YeN5a6a5ZCR55qE6ZO+5o6lXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlZHVybCA9IHNjb2RlLmhlYWRlcnMubG9jYXRpb25bMF0ucmVwbGFjZSgvXFxcXFxcXFwvZywgJycpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICgvXFxcXD1odHRwLy50ZXN0KHJlZHVybCkgJiYgL2h0bWx8YmlsaWJpbGl8a2V5XFxcXD0vLnRlc3QocmVkdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gSlNPTi5wYXJzZShmZXRjaChyZWR1cmwsIHt9KSkudXJsO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL1xcXFw9aHR0cC8udGVzdChyZWR1cmwpICYmIC9cXFxcLm0zdTh8XFxcXC5tcDR8XFxcXC5mbHYvLnRlc3QocmVkdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVkdXJsLnN1YnN0cmluZyhyZWR1cmwuaW5kZXhPZignPWh0dHAnKSArIDEpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL2h0dHAvLnRlc3QocmVkdXJsKSAmJiAva2V5XFxcXD18dWlkXFxcXD0vLnRlc3QocmVkdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gSlNPTi5wYXJzZShmZXRjaChyZWR1cmwsIHt9KSkudXJsO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL2h0dHAvLnRlc3QocmVkdXJsKSAmJiAvaHRtbHxiaWxpYmlsaS8udGVzdChyZWR1cmwpKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBvcGVudXJsKHZsaW5rKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVkdXJsXFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAvL3ZhciBodG1sID0gcmVxdWVzdChzcmN1cmwpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBodG1sID0gc2NvZGUuYm9keTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAvL2xvZyhodG1sKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoLzQwNCBOb3QgRm91bmR85aSH5qGI5ZCO5Y+v57un57ut6K6/6ZeuLy50ZXN0KGh0bWwpKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBvcGVudXJsKHZsaW5rKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9cXFxcPGJvZHkvLnRlc3QoaHRtbCkpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbG9nKCflsJ3or5XpnZ5KU09O5o6l5Y+j572R6aG16Kej5p6QJyk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJlcXVpcmVDYWNoZSgnaHR0cHM6Ly9jb2RlLmFsaXl1bi5jb20vbHprMjM1NTkvUHVibGljUnVsZS9yYXcvbWFzdGVyL3g1cnVsZS5qcycsIDI0KTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHg1cnVsZShzcmN1cmwsIHNyY3VybCk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vcmV0dXJuIG9wZW51cmwoc3JjdXJsKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvL2pzb27op6PmnpDnmoTlj5bpk77mjqVcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHB1cmwgPSBodG1sLm1hdGNoKC9bXFxcXCdcXFxcXFxcIl11cmxbXFxcXCdcXFxcXFxcIl06Lio/W1xcXFwnXFxcXFxcXCJdKC4qPylbXFxcXCdcXFxcXFxcIl0vKVsxXS5yZXBsYWNlKC9cXFxcXFxcXC9nLCAnJyk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vbG9nKHB1cmwpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoL2h0dHAvLnRlc3QocHVybCkpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChwdGFiID09ICdiaWxpYmlsaScpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcHVybCArICc7e1JlZmVyZXJAaHR0cHM6Ly93d3cuYmlsaWJpbGkuY29tLyYmVXNlci1BZ2VudEBNb3ppbGxhLzUuMH0nO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChwdGFiID09ICdtZ3R2Jykge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJyNpc1ZpZGVvPXRydWUjJyArICc7e1JlZmVyZXJAd3d3Lm1ndHYuY29tJiZVc2VyLUFnZW50QE1vemlsbGEvNS4wfSc7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9vamJrLy50ZXN0KHB1cmwpKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHB1cmwgKyAnO3tSZWZlcmVyQGh0dHBzOi8vYmFrLm9qYmtqeC5jb20vfSc7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYoL3ZpZGVvX21wNHx0eXBlXFxcXD1tM3U4fHB0XFxcXD1tM3U4fFxcXFwvdmlkZW9cXFxcL3Rvc1xcXFwvLy50ZXN0KHB1cmwpKXtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcHVybCArICcjaXNWaWRlbz10cnVlIyc7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9O1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy/pnZ5odHRw5byA5aS055qE5omT5byA5Y6f6ZO+5o6lICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9wZW51cmwodmxpbmspXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgICAgICAgICAgICAgIC8v5oql6ZSZ5Yik5pat5aSE55CGXFxuICAgICAgICAgICAgICAgICAgICBsb2coJ+aJp+ihjOaKpemUmei3s+i9rOWkhOeQhicpO1xcbiAgICAgICAgICAgICAgICAgICAgLyppZiAoc3JjdXJsLnN1YnN0cmluZygwLCAyKSA9PSAnXFxcXC9cXFxcLycpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gb3BlbnVybCgnaHR0cHM6JyArIHNyY3VybCk7XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9cXFxcPWh0dHAvLnRlc3Qoc3JjdXJsKSAmJiAvXFxcXC5odG1sfGJpbGliaWxpLy50ZXN0KHNyY3VybCkpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAvL3JldHVybiBzcmN1cmwuc3BsaXQoJz0nKVsxXTtcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gb3BlbnVybChzcmN1cmwuc3Vic3RyaW5nKHNyY3VybC5pbmRleE9mKCc9aHR0cCcpICsgMSkpO1xcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHsqL1xcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9wZW51cmwodmxpbmspXFxuICAgICAgICAgICAgICAgICAgICAvL3JldHVybiAneDVXZWJWaWV3Oi8vJytzcmN1cmxcXG4gICAgICAgICAgICAgICAgICAgIC8vfVxcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIC8v5Yqo5oCB6Kej5p6Q5Luj56CB57uT5p2fXFxuICAgICAgICAgICAgfSxcXG4gICAgICAgICAgICBwdGFiLFxcbiAgICAgICAgICAgIGxpbmssXFxuICAgICAgICAgICAgbXl1cmwsXFxuICAgICAgICAgICAgdmxpbmspLFxcbiAgICAgICAgY29sX3R5cGU6IGNsdFxcbiAgICB9KTtcXG59XFxuLy99XCJ9LHtcImNvbF90eXBlXCI6XCJtb3ZpZV8zXCIsXCJuYW1lXCI6XCJUVueugOS7i+S4jumAiembhlwiLFwicGF0aFwiOlwidHZtb3ZsaXN0XCIsXCJydWxlXCI6XCJ2YXIgdGFicyA9IE9iamVj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VNldC5qc29uXFxcIikpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoZmV0Y2goY29uZmlnLmNqKSk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGF5dG1QYXJzZShyZXN1cmwpO1xcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVzdXJsXFxuICAgICAgICAgICAgICAgICAgICB9O1xcbiAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9cXFxcPUxUXFxcXC0vLnRlc3QocmVzdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAgbG9nKCfosIPnlKjmlq3mj5JsdG5i6YCa55So6Kej5p6QJyk7XFxuICAgICAgICAgICAgICAgICAgICBldmFsKFxcXCJ2YXIgY29uZmlnID1cXFwiICsgZmV0Y2goXFxcImhpa2VyOi8vZmlsZXMvY2FjaGUvTXlQYXJzZVNldC5qc29uXFxcIikpO1xcbiAgICAgICAgICAgICAgICAgICAgZXZhbChmZXRjaChjb25maWcuY2opKTtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBuYW1lID0gJ2x0bmIo6YCa55So5Ye95pWwKSc7XFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gUGFyc2VTW25hbWVdKHJlc3VybC5zdWJzdHJpbmcocmVzdXJsLmluZGV4T2YoJz1MVC0nKSArIDEpKTtcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiByZXN1cmxcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIH07XFxuICAgICAgICAgICAgXFxuICAgICAgICAgICAgdHJ5IHtcXG4gICAgICAgICAgICAgICAgdmFyIGVuRG4gPSBKU09OLnBhcnNlKGZldGNoKCdoaWtlcjovL2ZpbGVzL3J1bGVzL3h5cS9hcHBtc2V0Lmpzb24nLCB7fSkpLmVuRG47XFxuICAgICAgICAgICAgICAgIGlmIChlbkRuID09ICcxJyAmJiBzcmN1cmwubWF0Y2goL3lvdWt1fG1ndHZ8aXhpZ3VhfHFxLmNvbXxxaXlpfG1pZ3V8YmlsaWJpbGl8c29odXxwcHR2fGxlfDE5MDUuY29tLykgJiYgc3JjdXJsLnNlYXJjaCgvaHRtbHxiaWxpYmlsaXxpeGlndWEvKSAhPSAtMSkge1xcbiAgICAgICAgICAgICAgICAgICAgbG9nKCflt7LlvIDlkK/mlq3mj5LvvIzlsIbosIPnlKjmlq3mj5Lop6PmnpBodG1sJyk7XFxuICAgICAgICAgICAgICAgICAgICBldmFsKFxcXCJ2YXIgY29uZmlnID1cXFwiICsgZmV0Y2goXFxcImhpa2VyOi8vZmlsZXMvY2FjaGUvTXlQYXJzZVNldC5qc29uXFxcIikpO1xcbiAgICAgICAgICAgICAgICAgICAgZXZhbChmZXRjaChjb25maWcuY2opKTtcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBheXRtUGFyc2Uoc3JjdXJsLnN1YnN0cmluZyhzcmN1cmwuaW5kZXhPZignPWh0dHAnKSArIDEpKTtcXG4gICAgICAgICAgICAgICAgfTtcXG4gICAgICAgICAgICB9IGNhdGNoIChlKSB7fVxcbiAgICAgICAgICAgIFxcbiAgICAgICAgICAgIC8vbG9nKHNyY3VybCk7XFxuICAgICAgICAgICAgLy/liqjmgIHop6PmnpDku6PnoIHlvIDlp4tcXG4gICAgICAgICAgICB0cnkge1xcbiAgICAgICAgICAgICAgICBpZiAoL1xcXFwubTN1OHxcXFxcLm1wNHxvYmpcXFxcL3Rvcy8udGVzdChzcmN1cmwpICYmIC9odHRwLy50ZXN0KHNyY3VybCkpIHtcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiAvXFxcXD0vLnRlc3Qoc3JjdXJsKSA/IHNyY3VybC5zcGxpdCgnPScpWzFdIDogc3JjdXJsICsgJyNpc1ZpZGVvPXRydWUjJztcXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChzcmN1cmwuaW5kZXhPZihcXFwiL3NoYXJlL1xcXCIpICE9IC0xKSB7XFxuICAgICAgICAgICAgICAgICAgICB0cnkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBsaW5rID0gc3JjdXJsLnNwbGl0KFxcXCIvc2hhcmVcXFwiKVswXTtcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgZmMgPSBmZXRjaChzcmN1cmwsIHt9KS5yZXBsYWNlKFxcXCJ2YXIgcHVybFxcXCIsIFxcXCJ2YXIgbWFpblxcXCIpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChmYy5pbmRleE9mKFxcXCJtYWluXFxcIikgIT0gLTEpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1hdCA9IGZjLm1hdGNoKC92YXIgbWFpbi4qPzsvKVswXTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZXZhbChtYXQpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcGxheSA9IChtYWluLmluZGV4T2YoXFxcImh0dHBcXFwiKSAhPSAtMSA/IG1haW4gOiBsaW5rICsgbWFpbik7XFxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1haW4gPSBmYy5tYXRjaCgvdXJsOi4qP1tcXFxcJ1xcXFxcXFwiXSguKj8pW1xcXFwnXFxcXFxcXCJdLylbMV07XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwbGF5ID0gKG1haW4uaW5kZXhPZihcXFwiaHR0cFxcXCIpICE9IC0xID8gbWFpbiA6IGxpbmsgKyBtYWluKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIH07XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHBsYXk7XFxuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICd4NVdlYlZpZXc6Ly8nICsgKHNyY3VybClcXG4gICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChwdGFiID09ICdhbGl6eScpIHtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBwdXJsID0gZmV0Y2goJ2h0dHBzOi8vZm91YmluLmNvbS9qaWV4aS5waHA/dXJsPScgKyBzcmN1cmwsIHt9KS5tYXRjaCgvXFxcXFxcXCJ1cmxcXFxcXFxcIjpcXFxcXFxcIiguKj8pXFxcXFxcXCIvKVsxXTtcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsO1xcbiAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC8xOWp4XFxcXC52aXB8bmZ5aW5nc2hpLy50ZXN0KHNyY3VybCkpIHtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBwdXJsID0gSlNPTi5wYXJzZShmZXRjaChzcmN1cmwucmVwbGFjZSgnaHR0cDovLycsICdodHRwczovLycpLCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBcXFwiVXNlci1BZ2VudFxcXCI6IE1PQklMRV9VQVxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmVkaXJlY3Q6IGZhbHNlLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHdpdGhIZWFkZXJzOiB0cnVlXFxuICAgICAgICAgICAgICAgICAgICB9KSkuaGVhZGVycy5sb2NhdGlvblswXTtcXG4gICAgICAgICAgICAgICAgICAgIGlmICgvdGl0YW4ubWd0di8udGVzdChwdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJyNpc1ZpZGVvPXRydWUjJyArICc7e1JlZmVyZXJAd3d3Lm1ndHYuY29tJiZVc2VyLUFnZW50QE1vemlsbGEvNS4wfSc7XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9vYmpcXFxcL3Rvcy8udGVzdChwdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJyNpc1ZpZGVvPXRydWUjJztcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHB1cmxcXG4gICAgICAgICAgICAgICAgICAgIH07XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgLyplbHNlIGlmICgvemhhaWthbnlzLy50ZXN0KHNyY3VybCkpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcHVybCA9IEpTT04ucGFyc2UoZmV0Y2goc3JjdXJsICsgJyZhcHA9MTAwMDMmYWNjb3VudD0yNzI3NzUwMjgmcGFzc3dvcmQ9cXEyNzI3NzUwMjgnLCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJVc2VyLUFnZW50XFxcIjogTU9CSUxFX1VBXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJlZGlyZWN0OiBmYWxzZSxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgd2l0aEhlYWRlcnM6IHRydWVcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KSkuaGVhZGVycy5sb2NhdGlvblswXTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoL3RpdGFuLm1ndHYvLnRlc3QocHVybCkpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHB1cmwgKyAnI2lzVmlkZW89dHJ1ZSMnICsgJzt7UmVmZXJlckB3d3cubWd0di5jb20mJlVzZXItQWdlbnRATW96aWxsYS81LjB9JztcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9vYmpcXFxcL3Rvcy8udGVzdChwdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcHVybCArICcjaXNWaWRlbz10cnVlIyc7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHB1cmxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9O1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSovXFxuXFxuICAgICAgICAgICAgICAgIC8vLS0tLeWIhuWJsue6vy0tLS0vL1xcbiAgICAgICAgICAgICAgICB2YXIgc2NvZGUgPSBKU09OLnBhcnNlKGZldGNoKHNyY3VybCwge1xcbiAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJVc2VyLUFnZW50XFxcIjogTU9CSUxFX1VBXFxuICAgICAgICAgICAgICAgICAgICB9LFxcbiAgICAgICAgICAgICAgICAgICAgcmVkaXJlY3Q6IGZhbHNlLFxcbiAgICAgICAgICAgICAgICAgICAgd2l0aFN0YXR1c0NvZGU6IHRydWVcXG4gICAgICAgICAgICAgICAgfSkpO1xcbiAgICAgICAgICAgICAgICAvL2xvZyhzY29kZSk7XFxuICAgICAgICAgICAgICAgIGlmIChzY29kZS5zdGF0dXNDb2RlID09ICczMDInIHx8IHNjb2RlLnN0YXR1c0NvZGUgPT0gJzMwMScpIHtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBwdXJsID0gc2NvZGUuaGVhZGVycy5sb2NhdGlvblswXS5yZXBsYWNlKC9cXFxcXFxcXC9nLCAnJyk7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAvL3ZhciBodG1sID0gcmVxdWVzdChzcmN1cmwpO1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIGh0bWwgPSBzY29kZS5ib2R5O1xcbiAgICAgICAgICAgICAgICAgICAgLy9sb2coaHRtbCk7XFxuICAgICAgICAgICAgICAgICAgICBpZiAoLzQwNCBOb3QgRm91bmR85aSH5qGI5ZCO5Y+v57un57ut6K6/6ZeufOS4jeWtmOWcqC8udGVzdChodG1sKSB8fCBodG1sID09ICcnKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9wZW51cmwoc3JjdXJsLnN1YnN0cmluZyhzcmN1cmwuaW5kZXhPZignPWh0dHAnKSArIDEpKTtcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL1xcXFxcXFwidXJsXFxcXFxcXCJcXFxcOlxcXFxcXFwiaHR0cC8udGVzdChodG1sKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwdXJsID0gaHRtbC5tYXRjaCgvXFxcXFxcXCJ1cmxcXFxcXFxcIjpcXFxcXFxcIiguKj8pXFxcXFxcXCIvKVsxXS5yZXBsYWNlKC9cXFxcXFxcXC9nLCAnJyk7XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKGh0bWwuc3RhcnRzV2l0aCgneycpKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHB1cmwgPSBzcmN1cmwuc3Vic3RyaW5nKHNyY3VybC5pbmRleE9mKCc9aHR0cCcpICsgMSk7XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vdmFyIHB1cmwgPSBzcmN1cmxcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXF1aXJlQ2FjaGUoJ2h0dHBzOi8vY29kZS5hbGl5dW4uY29tL2x6azIzNTU5L1B1YmxpY1J1bGUvcmF3L21hc3Rlci94NXJ1bGUuanMnLCAyNCk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHg1cnVsZShzcmN1cmwsIHNyY3VybCk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgLy9yZXR1cm4gJ3g1V2ViVmlldzovLycrKHNyY3VybCkgXFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH07XFxuICAgICAgICAgICAgICAgIC8vbG9nKHB1cmwpO1xcbiAgICAgICAgICAgICAgICBpZiAoL3RpdGFuLm1ndHYvLnRlc3QocHVybCkpIHtcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJyNpc1ZpZGVvPXRydWUjJyArICc7e1JlZmVyZXJAd3d3Lm1ndHYuY29tJiZVc2VyLUFnZW50QE1vemlsbGEvNS4wfSc7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL29ialxcXFwvdG9zLy50ZXN0KHB1cmwpKSB7XFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gcHVybCArICcjaXNWaWRlbz10cnVlIyc7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gcHVybFxcbiAgICAgICAgICAgICAgICB9O1xcblxcbiAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgICAgICAgICAgaWYgKHNyY3VybC5zdWJzdHJpbmcoMCwgMikgPT0gJ1xcXFwvXFxcXC8nKSB7XFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gb3BlbnVybCgnaHR0cHM6JyArIHNyY3VybCk7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL1xcXFw9aHR0cC8udGVzdChzcmN1cmwpICYmIC9cXFxcLmh0bWx8YmlsaWJpbGkvLnRlc3Qoc3JjdXJsKSkge1xcbiAgICAgICAgICAgICAgICAgICAg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RdO1xcblxcbmlmICgvdmlwbXYvLnRlc3QodGRvbWluKSkge1xcbiAgICB2YXIgYmh0bWwgPSByZXF1ZXN0KHNwbFsxXSk7XFxufSBlbHNlIHtcXG4gICAgdmFyIGJodG1sID0gZmV0Y2goc3BsWzFdLCB7XFxuICAgICAgICBoZWFkZXJzOiB7XFxuICAgICAgICAgICAgXFxcIlVzZXItQWdlbnRcXFwiOiB0ZG9taW4uaW5kZXhPZihcXFwibW9nYWlfYXBpXFxcIikgIT0gLTEgPyBcXFwiRGFydC8yLjE0IChkYXJ0OmlvKVxcXCIgOiBcXFwib2todHRwLzQuMS4wXFxcIlxcbiAgICAgICAgfVxcbiAgICB9KTtcXG59XFxudHJ5IHtcXG4gICAgYmh0bWwgPSBiaHRtbC5zdGFydHNXaXRoKCdcXFxcclxcXFxuJykgPyBiaHRtbC5yZXBsYWNlKCdcXFxcclxcXFxuJywgJycpIDogYmh0bWw7XFxufSBjYXRjaCAoZSkge31cXG5pZiAoL2J0d2FmLy50ZXN0KGJodG1sKSkge1xcbiAgICAvKlxcbiAgICAgICAgICAgICAgICBpdGVtcy5wdXNoKHtcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOifmnInlrp3loZTpqozor4HvvIzngrnlh7vorr/pl67ljp/nvZHpobUnLFxcbiAgICAgICAgICAgICAgICAgICAgdXJsOiBzcGxbMV0gKyBgQGxhenlSdWxlPS5qczppbnB1dC5zcGxpdCgnOycpWzBdYCxcXG4gICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiAndGV4dF8xJ1xcbiAgICAgICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICAgICAgKi9cXG5cXG4gICAgYmh0bWwgPSBmZXRjaChzcGxbMV0gKyAnJmJ0d2FmJyArIGJodG1sLm1hdGNoKC9idHdhZiguKj8pXFxcXFxcXCIvKVsxXSwge30pO1xcblxcbn1cXG4vL2xvZyhiaHRtbCk7XFxuaWYgKGJodG1sID09IFxcXCJcXFwiIHx8IGJodG1sID09IG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Izngrnlh7vorr/pl67ljp/nvZHpobUnLFxcbiAgICAgICAgICAgIHVybDogc3BsWzFdICsgYEBsYXp5UnVsZT0uanM6aW5wdXQuc3BsaXQoJzsnKVswXWAsXFxuICAgICAgICAgICAgY29sX3R5cGU6ICd0ZXh0XzEnXFxuICAgICAgICB9KTtcXG4gICAgfSBlbHNlIHtcXG4gICAgICAgIGZvciAodmFyIGkgPSAwOyBpIDwgbGlzdC5sZW5ndGg7IGkrKykge1xcblxcbiAgICAgICAgICAgIGlmICgvXFxcXC92b2RcXFxcLy8udGVzdCh0ZG9taW4pKSB7XFxuICAgICAgICAgICAgICAgIHZhciB0aXRsZSA9IGxpc3RbaV0udGl0bGU7XFxuICAgICAgICAgICAgICAgIHZhciBwaWMgPSBsaXN0W2ldLnBpYztcXG4gICAgICAgICAgICAgICAgLy92YXIgdmlkPXRkb21pbisnL2RldGFpbD92b2RfaWQ9JytsaXN0W2ldLm5leHRsaW5rKycmcmVsX2xpbWl0PTEwJztcXG4gICAgICAgICAgICAgICAgdmFyIHZpZCA9IGxpc3RbaV0ubmV4dGxpbms7XFxuICAgICAgICAgICAgICAgIHZhciByZW0gPSBsaXN0W2ldLnN0YXRlO1xcbiAgICAgICAgICAgICAgICAvL3ZhciBjb249bGlzdFtpXS5zdGF0ZTtcXG4gICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICBpZiAodGRvbWluLmluZGV4T2YoJ2FwaS5waHAvYXBwLycpICE9IC0xKSB7XFxuICAgICAgICAgICAgICAgICAgICB2YXIgdGl0bGUgPSBsaXN0W2ldLnZvZF9uYW1lO1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIHBpYyA9IGxpc3RbaV0udm9kX3BpYztcXG4gICAgICAgICAgICAgICAgICAgIGlmICgvZmFudHVhbi8udGVzdCh0ZG9taW4pKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHZpZCA9ICdodHRwczovL2ZhbnR1YW4ud2tmaWxlLmNvbS9hcGkucGhwL2FwcC92aWRlb19kZXRhaWw/aWQ9JyArIGxpc3RbaV0udm9kX2lkICsgJyZ0b2tlbj0nO1xcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgdmlkID0gdGRvbWluICsgJ3ZpZGVvX2RldGFpbD9pZD0nICsgbGlzdFtpXS52b2RfaWQgKyAnJnRva2VuPSc7XFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICB2YXIgcmVtID0gbGlzdFtpXS52b2RfcmVtYXJrcztcXG4gICAgICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnR5cGUudHlwZV9kZXM7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAodGRvbWluLmluZGV4T2YoJ3hnYXBwLnBocC92MS8nKSAhPSAtMSkge1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIHRpdGxlID0gbGlzdFtpXS52b2RfbmFtZTtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBwaWMgPSBsaXN0W2ldLnZvZF9waWM7XFxuICAgICAgICAgICAgICAgICAgICB2YXIgdmlkID0gdGRvbWluICsgJ3ZpZGVvX2RldGFpbD9pZD0nICsgbGlzdFtpXS52b2RfaWQ7XFxuICAgICAgICAgICAgICAgICAgICB2YXIgcmVtID0gbGlzdFtpXS52b2RfcmVtYXJrcztcXG4gICAgICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnR5cGUudHlwZV9kZXM7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICB2YXIgdGl0bGUgPSBsaXN0W2ldLnZvZF9uYW1lO1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIHBpYyA9IGxpc3RbaV0udm9kX3BpYztcXG4gICAgICAgICAgICAgICAgICAgIGlmICgvaW9wZW55dW4vLnRlc3QodGRvbWluKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciB2aWQgPSB0ZG9taW4gKyAnL2RldGFpbElEP3ZvZF9pZD0nICsgbGlzdFtpXS52b2RfaWQgKyAnJnRva2VuPSc7XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciB2aWQgPSB0ZG9taW4gKyAnL2RldGFpbD9rZXk9JyArIGRhdGVTdHIgKyAnJnZvZF9pZD0nICsgbGlzdFtpXS52b2RfaWQgKyAnJnRva2VuPSc7XFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICB2YXIgcmVtID0gbGlzdFtpXS52b2RfcmVtYXJrcztcXG4gICAgICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnR5cGUudHlwZV9kZXM7XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICB9XFxuXFxuICAgICAgICAgICAgaXRlbXMucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiB0aXRsZS5yZXBsYWNlKGtleSwgJ+KAnOKAnCcgKyBrZXkgKyAn4oCd4oCdJyksXFxuICAgICAgICAgICAgICAgIHBpY191cmw6IHBpYyArICdAUmVmZXJlcj0nLFxcbiAgICAgICAgICAgICAgICB1cmw6ICQodGRvbWluLmluZGV4T2YoXFxcIm1vZ2FpX2FwaVxcXCIpICE9IC0xID8gdmlkICsgJztnZXQ7dXRmLTg7e1VzZXItQWdlbnRARGFydC8yLjE0IChkYXJ0OmlvKX0nIDogdmlkICsgJztnZXQ7dXRmLTg7e1VzZXItQWdlbnRAb2todHRwLzQuMS4wfScpLnJ1bGUoKHRkb21pbikgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIHJlcyA9IHt9O1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIGl0ZW1zID0gW107XFxuICAgICAgICAgICAgICAgICAgICB2YXIgaHRtbCA9IEpTT04ucGFyc2UoZ2V0UmVzQ29kZSgpKTtcXG4gICAgICAgICAgICAgICAgICAgIGl0ZW1zLnB1c2goe1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiAnJyxcXG4gICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiAnMjU1JiZmbG9hdCcsXFxuICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiAnJyxcXG4gICAgICAgICAgICAgICAgICAgICAgICBjb2xfdHlwZTogJ3g1X3dlYnZpZXdfc2luZ2xlJ1xcbiAgICAgICAgICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgICAgICAgICByZWZyZXNoWDVXZWJWaWV3KCcnKTtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBteXVybCA9IE1ZX1VSTC5tYXRjaCgvKFtcXFxcU10qPzpcXFxcL1xcXFwvW1xcXFxTXSo/KVxcXFwvLylbMV07XFxuICAgICAgICAgICAgICAgICAgICBpZiAoL1xcXFwvdm9kXFxcXC8vLnRlc3QodGRvbWluKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoSlNPTi5wYXJzZShmZXRjaCgnaGlrZXI6Ly9wYWdlL3R2bW92bGlzdCcsIHt9KSkucnVsZSk7XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoSlNPTi5wYXJzZShmZXRjaCgnaGlrZXI6Ly9wYWdlL2FwcG1vdmxpc3QnLCB7fSkpLnJ1bGUpO1xcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgcmVzLmRhdGEgPSBpdGVtcztcXG4gICAgICAgICAgICAgICAgICAgIHNldEhvbWVSZXN1bHQocmVzKTtcXG4gICAgICAgICAgICAgICAgfSwgdGRvbWluKSxcXG4gICAgICAgICAgICAgICAgLy9jb250ZW50OnJlbSxcXG4gICAgICAgICAgICAgICAgZGVzYzogcmVtLFxcbiAgICAgICAgICAgICAgICBjb2xfdHlwZTogJ21vdmllXzFfdmVydGljYWxfcG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ICBwaWNfdXJsOiBpbWcgKyAnQFJlZmVyZXI9JyxcXG4gICAgICAgICAgICB1cmw6ICQobGluaykucnVsZSgoKSA9PiB7XFxuICAgICAgICAgICAgICAgIHZhciByZXMgPSB7fTtcXG4gICAgICAgICAgICAgICAgdmFyIGl0ZW1zID0gW107XFxuICAgICAgICAgICAgICAgIGl0ZW1zLnB1c2goe1xcbiAgICAgICAgICAgICAgICAgICAgdGl0bGU6ICcnLFxcbiAgICAgICAgICAgICAgICAgICAgZGVzYzogJzI1NSYmZmxvYXQnLFxcbiAgICAgICAgICAgICAgICAgICAgdXJsOiAnJyxcXG4gICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiAneDVfd2Vidmlld19zaW5nbGUnXFxuICAgICAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgICAgICByZWZyZXNoWDVXZWJWaWV3KCcnKTtcXG4gICAgICAgICAgICAgICAgdmFyIGh0bWwgPSBKU09OLnBhcnNlKGdldFJlc0NvZGUoKSk7XFxuICAgICAgICAgICAgICAgIHZhciBteXVybCA9IE1ZX1VSTC5tYXRjaCgvKFtcXFxcU10qPzpcXFxcL1xcXFwvW1xcXFxTXSo/KVxcXFwvLylbMV07XFxuICAgICAgICAgICAgICAgIHRyeSB7XFxuICAgICAgICAgICAgICAgICAgICBldmFsKEpTT04ucGFyc2UoZmV0Y2goJ2hpa2VyOi8vcGFnZS9hcHBtb3ZsaXN0Jywge30pKS5ydWxlKTtcXG4gICAgICAgICAgICAgICAgfSBjYXRjaCAoZSkge31cXG4gICAgICAgICAgICAgICAgcmVzLmRhdGEgPSBpdGVtcztcXG4gICAgICAgICAgICAgICAgc2V0SG9tZVJlc3VsdChyZXMpO1xcbiAgICAgICAgICAgIH0pLFxcbiAgICAgICAgICAgIGRlc2M6IGRlc2MsXFxuICAgICAgICAgICAgY29sX3R5cGU6ICdtb3ZpZV8zX21hcnF1ZWUnXFxuICAgICAgICB9KTtcXG4gICAgfVxcbn1cIn0se1wiY29sX3R5cG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Lmpzb25cXFwiLCBmaWxlVXJsKTtcXG4gICAgICAgICAgICAgICAgYmFjayh0cnVlKTtcXG4gICAgICAgICAgICAgICAgcmV0dXJuICd0b2FzdDovL+S/neWtmOiuvue9ruaQnOe0oue6v+eoi+WujOaIkO+8gSdcXG4gICAgICAgICAgICB9XFxuICAgICAgICB9KSxcXG4gICAgfSksXFxuICAgIGNvbF90eXBlOiAndGV4dF8yJ1xcbn0pO1xcblxcbmQucHVzaCh7XFxuICAgIHRpdGxlOiAn5pu05paw55u45YWzJyxcXG4gICAgY29sX3R5cGU6ICd0ZXh0X2NlbnRlcl8xJ1xcbn0pO1xcbmQucHVzaCh7XFxuICAgIHRpdGxlOiAn5qOA5rWL5pu05pawJyxcXG4gICAgdXJsOiAkKCcnKS5sYXp5UnVsZSgobG9jdmVyKSA9PiB7XFxuICAgICAgICB0cnkge1xcbiAgICAgICAgICAgIHZhciByZW1mID0gZmV0Y2hDYWNoZSgnaHR0cHM6Ly9jb2RlYmVyZy5vcmcvbHprMjM1NTkvY2xvdWRydWxlL3Jhdy9icmFuY2gvbWFzdGVyL2FwcG1vdmllLnR4dCcsIDI0KTtcXG4gICAgICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgICAgICByZW1mID0gJyc7XFxuICAgICAgICB9XFxuICAgICAgICBpZiAoL++/pWJhc2U2NC8udGVzdChyZW1mKSkge1xcbiAgICAgICAgICAgIHZhciByZW12ID0gSlNPTi5wYXJzZShiYXNlNjREZWNvZGUocmVtZi5zcGxpdCgnQCcpWzJdKSkudmVyc2lvbjtcXG4gICAgICAgIH0gZWxzZSBpZiAoL++/pWhvbWVfcnVsZe+/pS8udGVzdChyZW1mKSkge1xcbiAgICAgICAgICAgIHZhciByZW12ID0gSlNPTi5wYXJzZShyZW1mLnNwbGl0KCfvv6Vob21lX3J1bGXvv6UnKVsxXSkudmVyc2lvbjtcXG4gICAgICAgIH07XFxuICAgICAgICBpZiAoL++/pWhvbWVfcnVsZS8udGVzdChyZW1mKSkge1xcbiAgICAgICAgICAgIGxvZygn6L+c56iL54mI5pys77yaJyArIHJlbXYpO1xcbiAgICAgICAgICAgIGxvZygn5pys5Zyw54mI5pys77yaJyArIGxvY3Zlcik7XFxuICAgICAgICAgICAgaWYgKGxvY3ZlciAhPSByZW12KSB7XFxuICAgICAgICAgICAgICAgIHB1dFZhcignYXBwbnZlcicsIHJlbWYpO1xcbiAgICAgICAgICAgICAgICByZWZyZXNoUGFnZSgpO1xcbiAgICAgICAgICAgICAgICByZXR1cm4gJ3RvYXN0Oi8v5pyJ5paw54mI5pys77yM54K55a+85YWl5pu05paw5Y+v5pu05paw6KeE5YiZ44CCJztcXG4gICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICByZXR1cm4gJ3RvYXN0Oi8v5pqC5peg5paw54mI5pys77yMMjTlsI/ml7blhoXmo4DmtYvml6DmlYjjgIInXFxuICAgICAgICAgICAgfTtcXG4gICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgcmV0dXJuICd0b2FzdDovL+ajgOa1i+abtOaWsOWksei0pe+8jOWPr+iDveS6keerr+aKvemjjuS6huOAgidcXG4gICAgICAgIH1cXG4gICAgfSwgbG9jdmVyKSxcXG4gICAgY29sX3R5cGU6ICd0ZXh0XzInXFxufSk7XFxuaWYgKGdldFZhcignYXBwbnZlcicpKSB7XFxuICAgIGQucHVzaCh7XFxuICAgICAgICB0aXRsZTogJ+WvvOWFpeabtOaWsCcsXFxuICAgICAgICB1cmw6ICQoJycpLmxhenlSdWxlKCgpID0+IHtcXG4gICAgICAgICAgICByZXR1cm4gZ2V0VmFyKCdhcHBudmVyJyk7XFxuICAgICAgICB9KSxcXG4gICAgICAgIGNvbF90eXBlOiAndGV4dF8yJ1xcbiAgICB9KTtcXG59XFxuZC5wdXNoKHtcXG4gICAgdGl0bGU6ICfmjqXlj6Pnm7jlhbMnLFxcbiAgICBjb2xfdHlwZTogJ3RleHRfY2VudGVyXzEnXFxufSk7XFxudmFy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zBdLnZvZF9wbGF5X3VybC5zcGxpdCgnJCQkJyk7XFxuICAgICAgICB9XFxuICAgIH0gZWxzZSB7XFxuICAgICAgICB2YXIgY29udHMgPSBodG1sLmRhdGEudm9kX3BsYXlfbGlzdDtcXG4gICAgICAgIGlmIChjb250cy5sZW5ndGggPCAxKSB7XFxuICAgICAgICAgICAgY29udHMgPSBodG1sLmRhdGEudm9kX3BsYXlfdXJsLnNwbGl0KCckJCQnKTtcXG4gICAgICAgIH1cXG4gICAgfVxcblxcbiAgICBmb3IgKHZhciBpID0gMDsgaSA8IGNvbnRzLmxlbmd0aDsgaSsrKSB7XFxuICAgICAgICBpZiAoaHRtbC52aWRlb2xpc3QpIHtcXG4gICAgICAgICAgICB2YXIgbGlzdCA9IGh0bWwudmlkZW9saXN0W2NvbnRzW2ldXTtcXG4gICAgICAgIH0gZWxzZSBpZiAoY29udHNbaV0udXJscykge1xcbiAgICAgICAgICAgIHZhciBsaXN0ID0gY29udHNbaV0udXJscztcXG4gICAgICAgIH0gZWxzZSBpZiAoY29udHNbaV0udXJsKSB7XFxuICAgICAgICAgICAgdmFyIGxpc3QgPSBjb250c1tpXS51cmwuc3BsaXQoXFxcIiNcXFwiKTtcXG4gICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgdmFyIGxpc3QgPSBjb250c1tpXS5zcGxpdChcXFwiI1xcXCIpO1xcbiAgICAgICAgfVxcbiAgICAgICAgY2hwLnB1c2gobGlzdC5sZW5ndGgpO1xcbiAgICB9XFxufSBjYXRjaCAoZSkge31cXG4vL2xvZyhNYXRoLm1heC5hcHBseShNYXRoLGNocCkpO1xcbnNldFJlc3VsdCgn5pu05paw6IezOicgKyAoTWF0aC5tYXguYXBwbHkoTWF0aCwgY2hwKSkpO1wifSx7XCJjb2xfdHlwZVwiOlwibW92aWVfM1wiLFwibmFtZVwiOlwi5YiG57G75pCc57SiXCIsXCJwYXRoXCI6XCJzczJcIixcInJ1bGVcIjpcImpzOlxcbnZhciBpdGVtc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0W2pdLnVybDtcXG4gICAgICAgICAgICB2YXIgbGl0aXQgPSBsaXN0W2pdLm11cmw7XFxuICAgICAgICAgICAgaWYgKC9cXFxcL3ZvZFxcXFwvL2kudGVzdChsaW5rKSkge1xcbiAgICAgICAgICAgICAgICBpZiAoLzM3XFxcXC4xNjF8MjE2XFxcXC45OHxwaG9lYmV8aGZ5czh8ZmVpZmFuMTJ8dHZ6eXxoZHlhbmd0dnx0a3lzfHRlZ291eXMvLnRlc3QobGluaykpIHtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnP2FjPWxpc3Qmem09JyArIGtleSArICcmcGFnZT0xJztcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnP2FjPWxpc3Qmd2Q9JyArIGtleSArICcmcGFnZT0xJztcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgIGlmICgvZGlqaWF4aWEvLnRlc3QobGluaykpIHtcXG4gICAgICAgICAgICAgICAgICAgIGxpbmsgPSAnaHR0cDovL3d3dy5kaWppYXhpYS5jb20vYXBpLnBocC9hcHAvJ1xcbiAgICAgICAgICAgICAgICB9O1xcbiAgICAgICAgICAgICAgICBpZiAobGluay5pbmRleE9mKCdhcGkucGhwL2FwcC8nKSAhPSAtMSkge1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIGhtdXJsID0gbGluayArICdzZWFyY2g/cGc9MSZ0ZXh0PScgKyBrZXkgKyAnJnRva2VuPSc7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAobGluay5pbmRleE9mKCd4Z2FwcC5waHAvdjEvJykgIT0gLTEpIHtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnc2VhcmNoP3BnPTEmdGV4dD0nICsga2V5O1xcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgaWYgKC9pb3Blbnl1bi8udGVzdChsaW5rKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnL2xpc3Q/cGFnZT1meXBhZ2UmbGltaXQ9MTAmd2Q9JyArIGtleTtcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGhtdXJsID0gbGluayArICc/cGFnZT0xJmxpbWl0PTEwJndkPScgKyBrZXk7XFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgLy9EYXRhLnB1c2goe3VybDogaG11cmwsb3B0aW9uczoge2hlYWRlcnM6IHtcXFwiVXNlci1BZ2VudFxcXCI6IFxcXCJEYXJ0LzIuMTQgKGRhcnQ6aW8pXFxcIn0sdGltZW91dDogdGltZW91fX0pO1xcbiAgICAgICAgICAgIERhdGEucHVzaCh7XFxuICAgICAgICAgICAgICAgIHVybDogaG11cmwsXFxuICAgICAgICAgICAgICAgIG9wdGlvbnM6IHtcXG4gICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBcXFwiVXNlci1BZ2VudFxcXCI6IGxpbmsuaW5kZXhPZihcXFwibW9nYWlfYXBpXFxcIikgIT0gLTEgPyBcXFwiRGFydC8yLjE0IChkYXJ0OmlvKVxcXCIgOiBcXFwib2todHRwLzQuMS4wXFxcIlxcbiAgICAgICAgICAgICAgICAgICAgfSxcXG4gICAgICAgICAgICAgICAgICAgIHRpbWVvdXQ6IHRpbWVvdVxcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgVGl0LnB1c2goe1xcbiAgICAgICAgICAgICAgICB0aXQ6IGxpc3Rbal0udGl0bGUsXFxuICAgICAgICAgICAgICAgIGxpbms6IGxpbmssXFxuICAgICAgICAgICAgICAgIHR5cG5tOiBsaXRpdFxcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgfSAvL2lmXFxuICAgIH0gLy9mb3Igalxcbn0gY2F0Y2ggKGUpIHt9XFxuaWYgKERhdGEubGVuZ3RoIDw9IDApIHtcXG4gICAgc2V0UmVzdWx0KFtdKTtcXG59IGVsc2Uge1xcbiAgICBpdGVtcy5wdXNoKHtcXG4gICAgICAgIHRpdGxlOiBcXFwi5q2j5Zyo5Yqg6L295Lit56ysXFxcIiArIE1ZX1BBR0UgKyBcXFwi6aG177yM6L+b5bqm77yaMS9cXFwiICsgRGF0YS5sZW5ndGgsXFxuICAgICAgICB1cmw6IFxcXCJcXFwiLFxcbiAgICAgICAgY29sX3R5cGU6IFxcXCJ0ZXh0X2NlbnRlcl8xXFxcIixcXG4gICAgICAgIGRlc2M6IFxcXCJcXFwiLFxcbiAgICAgICAgcGljX3VybDogXFxcIlxcXCIsXFxuICAgICAgICBleHRyYToge1xcbiAgICAgICAgICAgIGlkOiBwYWdlaWRcXG4gICAgICAgIH1cXG4gICAgfSk7XFxuICAgIHNldFJlc3VsdChpdGVtcyk7XFxuICAgIGxldCB0YXNrcyA9IFtdO1xcblxcbiAgICBmb3IgKGxldCBrIGluIERhdGEpIHtcXG4gICAgICAgIGxldCBpdCA9IERhdGFba107XFxuICAgICAgICB0YXNrcy5wdXNoKHtcXG4gICAgICAgICAgICBmdW5jOiBmdW5jdGlvbihwYXJhbSkge1xcbiAgICAgICAgICAgICAgICBsZXQgZCA9IFtdO1xcbiAgICAgICAgICAgICAgICBsZXQgaHRtbCA9IGZldGNoKHBhcmFtLml0LnVybCwgcGFyYW0uaXQub3B0aW9ucyk7XFxuICAgICAgICAgICAgICAgIC8vbG9nKGh0bWwpO1xcbiAgICAgICAgICAgICAgICB0cnkge1xcbiAgICAgICAgICAgICAgICAgICAgaHRtbCA9IGh0bWwuc3Vic3RyaW5nKDAsIDIpID09ICdcXFxcclxcXFxuJyA/IGh0bWwucmVwbGFjZSgnXFxcXHJcXFxcbicsICcnKSA6IGh0bWw7XFxuICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHt9XFxuICAgICAgICAgICAgICAgIGlmICgvYnR3YWYvLnRlc3QoaHRtbCkpIHtcXG4gICAgICAgICAgICAgICAgICAgIGh0bWwgPSBmZXRjaChwYXJhbS5pdC51cmwgKyAnJmJ0d2FmJyArIGh0bWwubWF0Y2goL2J0d2FmKC4qPylcXFxcXFxcIi8pWzFdLCB7fSk7XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgaWYgKGh0bWwgPT0gXFxcIlxcXCIgfHwgaHRtbCA9PSBudWxsIHx8IGh0bWwuc3Vic3RyaW5nKDAsIDUpID09ICdlcnJvcicgfHwgIWh0bWwuZW5kc1dpdGgoJ30nKSkge1xcbiAgICAgICAgICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogcGFyYW0udGl0LnRpdCArICcgJyArICfmnKrmkJzntKLliLDvvIzngrnlh7vorr/pl67ljp/nvZHpobUnLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogcGFyYW0uaXQudXJsICsgYEBsYXp5UnVsZT0uanM6aW5wdXQuc3BsaXQoJzsnKVswXWAsXFxuICAgICAgICAgICAgICAgICAgICAgICAgZGVzYzogXFxcIlxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgcGljX3VybDogXFxcIlxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6ICd0ZXh0X2NlbnRlcl8xJ1xcbiAgICAgICAgICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoaHRtbC5sZW5ndGggPCA4MCkge1xcbiAgICAgICAgICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogcGFyYW0udGl0LnRpdCArICcgJyArICfov5Tlm57mlbDmja7kuI3lrozmlbTvvIzngrnlh7vorr/pl67ljp/nvZHpobUnLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogcGFyYW0uaXQudXJsICsgYEBsYXp5UnVsZT0uanM6aW5wdXQuc3BsaXQoJzsnKVswXWAsXFxuICAgICAgICAgICAgICAgICAgICAgICAgZGVzYzogXFxcIlxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgcGljX3VybDogXFxcIlxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6ICd0ZXh0X2NlbnRlcl8xJ1xcbiAgICAgICAgICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICBodG1sID0gSlNPTi5wYXJzZShodG1sKTtcXG4gICAgICAgICAgICAgICAgICAgIC8vbG9nKGh0bWwpO1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIHR5cGV0ID0gcGFyYW0udGl0LnR5cG5tO1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIHRkb21pbiA9IHBhcmFtLnRpdC5saW5rO1xcbiAgICAgICAgICAgICAgICAgICAgaWYgKGh0bWwubGlzdCkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBsaXN0ID0gaHRtbC5saXN0O1xcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChodG1sLmRhdGEubGlzdCkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBsaXN0ID0gaHRtbC5kYXRhLmxpc3Q7XFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKGh0bWwuZGF0YSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBsaXN0ID0gaHRtbC5kYXRhO1xcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgbGlzdCA9IFtdO1xcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgaWYgKGxpc3QubGVuZ3RoIDwgMSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiBwYXJhbS50aXQudGl0ICsgJyAnICsgJ+WIl+ihqOWwj+S6jjHvvIzml6Dms5XlsZXnpLrvvIzngrnlh7vorr/pl67ljp/nvZHpobUnLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IHBhcmFtLml0LnVybCArIGBAbGF6eVJ1bGU9LmpzOmlucHV0LnNwbGl0KCc7JylbMF1gLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiBcXFwiXFxcIixcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcGljX3VybDogXFxcIlxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiAndGV4dF9jZW50ZXJfMSdcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBsaXN0Lmxlbmd0aDsgaSsrKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICgvXFxcXC92b2RcXFxcLy8udGVzdCh0ZG9taW4pKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgdGl0bGUgPSBsaXN0W2ldLnRpdGxlO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHBpYyA9IGxpc3RbaV0ucGljO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHZpZCA9IGxpc3RbaV0ubmV4dGxpbms7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVtID0gbGlzdFtpXS5zdGF0ZTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICh0ZG9taW4uaW5kZXhPZignYXBpLnBocC9hcHAvJykgIT0gLTEpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgdGl0bGUgPSBsaXN0W2ldLnZvZF9uYW1lO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwaWMgPSBsaXN0W2ldLnZvZF9waWM7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKC9mYW50dWFuLy50ZXN0KHRkb21pbikpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHZpZCA9ICdodHRwczovL2ZhbnR1YW4ud2tmaWxlLmNvbS9hcGkucGhwL2FwcC92aWRlb19kZXRhaWw/aWQ9JyArIGxpc3RbaV0udm9kX2lkICsgJyZ0b2tlbj0nO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciB2aWQgPSB0ZG9taW4gKyAndmlkZW9fZGV0YWlsP2lkPScgKyBsaXN0W2ldLnZvZF9pZCArICcmdG9rZW49JztcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlbSA9IGxpc3RbaV0udm9kX3JlbWFya3M7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy92YXIgY29uPWxpc3RbaV0udHlwZS50eXBlX2RlcztcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAodGRvbWluLmluZGV4T2YoJ3hnYXBwLnBocC92MS8nKSAhPSAtMSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciB0aXRsZSA9IGxpc3RbaV0udm9kX25hbWU7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHBpYyA9IGxpc3RbaV0udm9kX3BpYztcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgdmlkID0gdGRvbWluICsgJ3ZpZGVvX2RldGFpbD9pZD0nICsgbGlzdFtpXS52b2RfaWQ7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlbSA9IGxpc3RbaV0udm9kX3JlbWFya3M7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy92YXIgY29uPWxpc3RbaV0udHlwZS50eXBlX2RlcztcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHRpdGxlID0gbGlzdFtpXS52b2RfbmFtZTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcGljID0gbGlzdFtpXS52b2RfcGljO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICgvaW9wZW55dW4vLnRlc3QodGRvbWluKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgdmlkID0gdGRvbWluICsgJy9kZXRhaWxJRD92b2RfaWQ9JyArIGxpc3RbaV0udm9kX2lkICsgJyZ0b2tlbj0nO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciB2aWQgPSB0ZG9taW4gKyAnL2RldGFpbD9rZXk9JyArIGRhdGVTdHIgKyAnJnZvZF9pZD0nICsgbGlzdFtpXS52b2RfaWQgKyAnJnRva2VuPSc7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciByZW0gPSBsaXN0W2ldLnZvZF9yZW1hcmtzO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnR5cGUudHlwZV9kZXM7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxuXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy92YXIgY29uPWxpc3RbaV0uc3RhdGU7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vbG9nKHZpZCk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogTVlfVFlQRSA9PSBcXFwiaG9tZVxcXCIgPyB0aXRsZS5yZXBsYWNlKGtleSwgJ+KAnOKAnCcgKyBrZXkgKyAn4oCd4oCdJykgKyAnXFxcXG4nICsgcmVtIDogdGl0bGUgKyByZW0sXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwaWNfdXJsOiBwaWMgKyAnQFJlZmVyZXI9JyxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJCh0ZG9taW4uaW5kZXhPZihcXFwibW9nYWlfYXBpXFxcIikgIT0gLTEgPyB2aWQgKyAnO2dldDt1dGYtODt7VXNlci1BZ2VudEBEYXJ0LzIuMTQgKGRhcnQ6aW8pfScgOiB2aWQgKyAnO2dldDt1dGYtODt7VXNlci1BZ2VudEBva2h0dHAvNC4xLjB9JykucnVsZSgodGRvbWluLHRrdCxwYXR0KSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlcyA9IHt9O1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBpdGVtcyA9IFtdO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmKHRrdCE9Jycpe3NldFBhZ2VUaXRsZSh0a3QrJy0nK3BhdHQpO31cXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgaHRtbCA9IEpTT04ucGFyc2UoZ2V0UmVzQ29kZSgpKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtcy5wdXNoKHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdGl0bGU6ICcnLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiAnMjU1JiZmbG9hdCcsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJycsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiAneDVfd2Vidmlld19zaW5nbGUnXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG15dXJsID0gTVlfVVJMLm1hdGNoKC8oW1xcXFxTXSo/OlxcXFwvXFxcXC9bXFxcXFNdKj8pXFxcXC8vKVsxXTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoL1xcXFwvdm9kXFxcXC8vLnRlc3QodGRvbWluKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBldmFsKEpTT04ucGFyc2UoZmV0Y2goJ2hpa2VyOi8vcGFnZS90dm1vdmxpc3QnLCB7fSkpLnJ1bGUpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoSlNPTi5wYXJzZShmZXRjaCgnaGlrZXI6Ly9wYWdlL2FwcG1vdmxpc3QnLCB7fSkpLnJ1bGUpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXG5cXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXMuZGF0YSA9IGl0ZW1zO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNldEhvbWVSZXN1bHQocmVzKTtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sIHRkb21pbixwYXJhbS50aXQudGl0LHRpdGxlKSxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vY29udGVudDogcmVtLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGVzYzogdHl0aXQgKyAnID0+ICcgKyBwYXJhbS50aXQudGl0LFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6ICdtb3ZpZV8xX3ZlcnRpY2FsX3BpYydcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgfSAvL2ZvciBpXFxuICAgICAgICAgICAgICAgICAgICB9IC8vaWYgbGlzdC5sZW5ndGhcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICByZXR1cm4gZDtcXG4gICAgICAgICAgICB9LFxcbiAgICAgICAgICAgIHBhcmFtOiB7XFxuICAgICAgICAgICAgICAgIGl0OiBpdCxcXG4gICAgICAgICAgICAgICAgdGl0OiBUaXRba11cXG4gICAgICAgICAgICB9LFxcbiAgICAgICAgICAgIGlkOiBcXFwidGFza1xcXCJcXG4gICAgICAgIH0pXFxuICAgIH1cXG5cXG4gICAgYmF0Y2hFeGVjdXRlKHRhc2tzLCB7XFxuICAgICAgICBmdW5jOiBmdW5jdGlvbihwYXJhbSwgaWQsIGVycm9yLCByZXN1bHQpIHtcXG4gICAgICAgICAgICAvL2xvZyhcXFwibGlzdGVuZXI6IFxcXCIgKyAocmVzdWx0IHx8IFtdKS5sZW5ndGgpXFxuICAgICAgICAgICAgcGFyYW0uaSA9IHBhcmFtLmkgKyAxO1xcbiAgICAgICAgICAgIGlmIChyZXN1bHQpIHtcXG4gICAgICAgICAgICAgICAgZm9yIChsZXQgaXQgb2YgcmVzdWx0KSB7XFxuICAgICAgICAgICAgICAgICAgICBwYXJhbS5qID0gcGFyYW0uaiArIDE7XFxuICAgICAgICAgICAgICAgICAgICBhZGRJdGVtQmVmb3JlKHBhZ2VpZCwge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiBpdC50aXRsZSxcXG4gICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiBpdC5kZXNjLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogaXQudXJsLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHBpY191cmw6IGl0LnBpY191cmwsXFxuICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6IGl0LmNvbF90eXBlLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlkOiBcXFwiX19hcHBcXFwiICsgTVlfUEFHRSArIFxcXCJAXFxcIiArIHBhcmFtLmpcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICB9XFxuXFxuICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIGlmIChwYXJhbS5pID49IHBhcmFtLmFsbCkge1xcbiAgICAgICAgICAgICAgICBkZWxldGVJdGVtKHBhZ2VpZClcXG4gICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICB1cGRhdGVJdGVtKHtcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOiBcXFwi5q2j5Zyo5Yqg6L2956ysXFxcIiArIE1ZX1BBR0UgKyBcXFwi6aG177yM6L+b5bqm77yaXFxcIiArIChwYXJhbS5pICsgMSkgKyBcXFwiL1xcXCIgKyBwYXJhbS5hbGwsXFxuICAgICAgICAgICAgICAgICAgICB1cmw6IFxcXCJcXFwiLFxcbiAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6IFxcXCJ0ZXh0X2NlbnRlcl8xXFxcIixcXG4gICAgICAgICAgICAgICAgICAgIGRlc2M6IFxcXCJcXFwiLFxcbiAgICAgICAgICAgICAgICAgICAgcGljX3VybDogXFxcIlxcXCIsXFxuICAgICAgICAgICAgICAgICAgICBleHRyYToge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGlkOiBwYWdlaWRcXG4gICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICB9XFxuICAgICAgICB9LFxcbiAgICAgICAgcGFyYW06IHtcXG4gICAgICAgICAgICBhbGw6IERhdGEubGVuZ3RoLFxcbiAgICAgICAgICAgIGk6IDAsXFxuICAgICAgICAgICAgajogLTFcXG4gICAgICAgIH1cXG4gICAgfSlcXG59XCJ9LHtcImNvbF90eXBlXCI6XCJtb3ZpZV8zXCIsXCJuYW1lXCI6XCLmlbDmja7ovazmjaJcIixcInBhdGhcIjpcImNvbnZlclwiLFwicnVsZVwiOlwiLy9qczpcXG4vL3JlbShyZXMpO1xcbnZhciDorrDlvZUgPSBbXTtcXG52YXIg6L6T5YWl5p2h55uuID0gcmVtZmlsZS5tYXRjaCgvLis9aHR0cC4rL2cpO1xcbmZvciAodmFyIGogaW4g6L6T5YWl5p2h55uuKSB7XFxuICAgIHZhciB0aXRsZSA9IOi+k+WFpeadoeebrltqXS5zcGxpdCgnQCcpWzFdLnNwbGl0KCc9JylbMF07XFxuICAgIHZhciB1cmwgPSDovpPlhaXmnaHnm65bal0uc3BsaXQoJz0nKVsxXS5zcGxpdCgnIycpWzBdO1xcbiAgICB2YXIgaW1nID0g6L6T5YWl5p2h55uuW2pdLnNwbGl0KCcjJylbMV07XFxuICAgIGlmIChpbWcuaW5kZXhPZihcXFwiaHR0cFxcXCIpICE9IC0xKSB7XFxuICAgICAgICB2YXIgaW1nID0g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rKSkge1xcXFxuICAgICAgICAgICAgICAgIGlmICgvMzdcXFxcXFxcXC4xNjF8MjE2XFxcXFxcXFwuOTh8cGhvZWJlfGhmeXM4fGZlaWZhbjEyfHR2enl8aGR5YW5ndHZ8dGt5c3x0ZWdvdXlzLy50ZXN0KGxpbmspKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnP2FjPWxpc3Qmem09JyArIGtleSArICcmcGFnZT1meXBhZ2UnO1xcXFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnP2FjPWxpc3Qmd2Q9JyArIGtleSArICcmcGFnZT1meXBhZ2UnO1xcXFxuICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgaWYgKC9kaWppYXhpYS8udGVzdChsaW5rKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICBsaW5rID0gJ2h0dHA6Ly93d3cuZGlqaWF4aWEuY29tL2FwaS5waHAvYXBwLydcXFxcbiAgICAgICAgICAgICAgICB9O1xcXFxuICAgICAgICAgICAgICAgIGlmIChsaW5rLmluZGV4T2YoJ2FwaS5waHAvYXBwLycpICE9IC0xKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnc2VhcmNoP3BnPWZ5cGFnZSZ0ZXh0PScgKyBrZXkgKyAnJnRva2VuPSc7XFxcXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChsaW5rLmluZGV4T2YoJ3hnYXBwLnBocC92MS8nKSAhPSAtMSkge1xcXFxuICAgICAgICAgICAgICAgICAgICB2YXIgaG11cmwgPSBsaW5rICsgJ3NlYXJjaD9wZz1meXBhZ2UmdGV4dD0nICsga2V5O1xcXFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIGlmICgvaW9wZW55dW4vLnRlc3QobGluaykpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnL2xpc3Q/cGFnZT1meXBhZ2UmbGltaXQ9MTAmd2Q9JyArIGtleTtcXFxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnP3BhZ2U9ZnlwYWdlJmxpbWl0PTEwJndkPScgKyBrZXk7XFxcXG4gICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICBpdGVtcy5wdXNoKHtcXFxcbiAgICAgICAgICAgICAgICB0aXRsZTogbGlzdFtqXS50aXRsZSxcXFxcbiAgICAgICAgICAgICAgICBpbWc6IGxpc3Rbal0uaW1nLFxcXFxuICAgICAgICAgICAgICAgIHVybDogJCgnaGlrZXI6Ly9lbXB0eSN4IycgKyBobXVybCArICcjeCMnICsgbGluayArICcjeCMnICsgbGl0aXQgKyAnI3gjJyArIGtleSArICcjeCMnKS5ydWxlKCgpID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgJC5yZXF1aXJlKCdoaWtlcjovL3BhZ2Uvc2VhcmVyaicpO1xcXFxuICAgICAgICAgICAgICAgIH0pLFxcXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnaWNvbl9yb3VuZF9zbWFsbF80J1xcXFxuICAgICAgICAgICAgICAgIC8vY29sX3R5cGU6ICd0ZXh0XzMnXFxcXG4gICAgICAgICAgICAgICAgLy9saW5rOmxpbmssXFxcXG4gICAgICAgICAgICAgICAgLy90eXBlOiBpXFxcXG4gICAgICAgICAgICB9KTtcXFxcblxcXFxuICAgICAgICB9IC8vZm9yIGpcXFxcblxcXFxuXFxcXG4gICAgfSAvL2ZvciBpXFxcXG5cXFxcbn0gLy9lbmQgbW9kZSAwXFxcX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RldGFpbCZpZHM9JyArIHVybDtcXFxcbiAgICBpdGVtcy5wdXNoKHtcXFxcbiAgICAgICAgdGl0bGU6IHRpdGxlLFxcXFxuICAgICAgICBwaWNfdXJsOiBpbWcgKyAnQFJlZmVyZXI9JyxcXFxcbiAgICAgICAgdXJsOiAkKHVybCkucnVsZSgoKSA9PiB7XFxcXG4gICAgICAgICAgICB2YXIgcmVzID0ge307XFxcXG4gICAgICAgICAgICB2YXIgaXRlbXMgPSBbXTtcXFxcbiAgICAgICAgICAgIHZhciBodG1sID0gSlNPTi5wYXJzZShnZXRSZXNDb2RlKCkpO1xcXFxuICAgICAgICAgICAgdmFyIG15dXJsID0gTVlfVVJMLm1hdGNoKC8oW1xcXFxcXFxcU10qPzpcXFxcXFxcXC9cXFxcXFxcXC9bXFxcXFxcXFxTXSo/KVxcXFxcXFxcLy8pWzFdO1xcXFxuICAgICAgICAgICAgaXRlbXMucHVzaCh7XFxcXG4gICAgICAgICAgICAgICAgdGl0bGU6ICcnLFxcXFxuICAgICAgICAgICAgICAgIGRlc2M6ICcyNTUmJmZsb2F0JyxcXFxcbiAgICAgICAgICAgICAgICB1cmw6ICcnLFxcXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAneDVfd2Vidmlld19zaW5nbGUnXFxcXG4gICAgICAgICAgICB9KTtcXFxcbiAgICAgICAgICAgIHJlZnJlc2hYNVdlYlZpZXcoJycpO1xcXFxuICAgICAgICAgICAgdHJ5IHtcXFxcbiAgICAgICAgICAgIGV2YWwoSlNPTi5wYXJzZShmZXRjaCgnaGlrZXI6Ly9wYWdlL3R2bW92bGlzdCcsIHt9KSkucnVsZSk7XFxcXG4gICAgICAgICAgICB9IGNhdGNoIChlKSB7fVxcXFxuICAgICAgICAgICAgcmVzLmRhdGEgPSBpdGVtcztcXFxcbiAgICAgICAgICAgIHNldEhvbWVSZXN1bHQocmVzKTtcXFxcbiAgICAgICAgfSksXFxcXG4gICAgICAgIGRlc2M6IGRlc2MsXFxcXG4gIC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gICAgfSBlbHNlIGlmIChodG1sLmRhdGEudm9kX2luZm8gJiYgaHRtbC5kYXRhLnZvZF9pbmZvLnZvZF91cmxfd2l0aF9wbGF5ZXIpIHtcXFxcbiAgICAgICAgdmFyIHB0YWIgPSBjb250c1trXS5jb2RlID8gY29udHNba10uY29kZSA6IHRhYnNba107XFxcXG4gICAgfSBlbHNlIHtcXFxcbiAgICAgICAgdmFyIHB0YWIgPSBjb250c1trXS5mcm9tID8gY29udHNba10uZnJvbSA6IHRhYnNba107XFxcXG4gICAgfVxcXFxuICAgIGl0ZW1zLnB1c2goe1xcXFxuICAgICAgICB0aXRsZTogKGdldE15VmFyKHRpdGxlLCAnMCcpID09IGsgPyAn8J+RifCfj7snIDogJycpICsgcHRhYixcXFxcbiAgICAgICAgdXJsOiBgaGlrZXI6Ly9lbXB0eUBsYXp5UnVsZT0uanM6cHV0TXlWYXIoJ2AgKyB0aXRsZSArIFxcXFxcXFwiJywgJ1xcXFxcXFwiICsgayArIGAnKTtyZWZyZXNoUGFnZSgpOyd0b2FzdDovL+WIh+aNouaIkOWKn++8gSdgLFxcXFxuICAgICAgICBjb2xfdHlwZTogJ3Njcm9sbF9idXR0b24nXFxcXG4gICAgfSk7XFxcXG5cXFxcbn1cXFxcblxcXFxuXFxcXG5cXFxcbnZhciBqaWVrID0gJyc7XFxcXG4vL2ZvciAodmFyIGkgPSAwOyBpIDwgY29udHMubGVuZ3RoOyBpKyspIHtcXFxcbmlmIChnZXRNeVZhcignYXBwbWFwcHNvcnQnLCAnMScpID09ICcxJykge1xcXFxuICAgIGlmIChjb250c1tnZXRNeVZhcih0aXRsZSwgJzAnKV0udXJscykge1xcXFxuICAgICAgICB2YXIgbGlzdCA9IGNvbnRzW2dldE15VmFyKHRpdGxlLCAnMCcpXS51cmxzO1xcXFxuICAgIH0gZWxzZSBpZiAoY29udHNbZ2V0TXlWYXIodGl0bGUsICcwJyldLnVybCkge1xcXFxuICAgICAgICB2YXIgbGlzdCA9IGNvbnRzW2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lWYXIodGl0bGUsICcwJyldLnBsYXllcl9pbmZvLnBhcnNlICYmIChjb250c1tnZXRNeVZhcih0aXRsZSwgJzAnKV0ucGxheWVyX2luZm8ucGFyc2UpLmluZGV4T2YoXFxcXFxcXCI9XFxcXFxcXCIpICE9IC0xKSB7XFxcXG4gICAgICAgICAgICAgICAgdmFyIGppZWsgPSAoY29udHNbZ2V0TXlWYXIodGl0bGUsICcwJyldLnBsYXllcl9pbmZvLnBhcnNlKS5yZXBsYWNlKC9cXFxcXFxcXC5cXFxcXFxcXC4vZywgXFxcXFxcXCIuXFxcXFxcXCIpLnNwbGl0KCcsJylbMF07XFxcXG4gICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgIHZhciBqaWVrID0gXFxcXFxcXCJcXFxcXFxcIjtcXFxcbiAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgIC8vc2V0RXJyb3Ioamllayk7ICAgICAgICAgICAgICAgIFxcXFxuICAgICAgICB9XFxcXG4gICAgfSBjYXRjaCAoZSkge31cXFxcbiAgICAvL2ppZWvmi7zmjqVcXFxcbiAgICBpZiAoamllayAhPSAnJyAmJiBqaWVrICE9IG51bGwpIHtcXFxcbiAgICAgICAgaWYgKGppZWsuc3Vic3RyaW5nKDAsIDQpID09ICdodHRwJykge1xcXFxuICAgICAgICAgICAgamllayA9IGppZWs7XFxcXG4gICAgICAgIH0gZWxzZSBpZiAoamllay5zdWJzdHJpbmcoMCwgMikgPT0gJ1xcXFxcXFxcL1xcXFxcXFxcLycpIHtcXFxcbiAgICAgICAgICAgIGppZWsgPSAnaHR0cHM6JyArIGppZWs7XFxcXG4gICAgICAgIH1cXFxcbiAgICB9IGVsc2Uge1xcXFxuICAgICAgICBqaWVrID0gXFxcXFxcXCJcXFxcXFxcIjtcXFxcbiAgICB9XFxcXG4gICAgLy/lr7nlpLHmlYjmjqXlj6Pov5vooYzmm7/mjaJcXFxcbiAgICBpZiAoL2Nva2Vtdi8udGVzdChteXVybCk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Hl3LykgIT0gLTEpIHtcXFxcbiAgICAgICAgamllayA9ICdodHRwOi8vd3d3LjEwODBrYW4uY2MvamlleGkvcnIucGhwP3VybD0nO1xcXFxuICAgIH0gZWxzZSBpZiAoL21pYW9wYXJ0eS8udGVzdChwdGFiKSAmJiBteXVybC5zZWFyY2goL2Z1bjRrLykgIT0gLTEpIHtcXFxcbiAgICAgICAgamllayA9ICdodHRwczovL3d3dy5mdW40ay5jb20vYXBsYXllci8/dXJsPSc7XFxcXG4gICAgfSBlbHNlIGlmICgvamh5dW5cXFxcXFxcXC5waHAvLnRlc3QoamllaykpIHtcXFxcbiAgICAgICAgamllayA9IGppZWsucmVwbGFjZSgnaHR0cDovL3N2aXAuamh5dW4uanguY246MTIzNC9qaHl1bi5waHA/dXJsPScsICdodHRwczovL2FwaS5qaGR5dy52aXAvP3VybD0nKTtcXFxcbiAgICB9IGVsc2UgaWYgKC93d3dcXFxcXFxcXC5haWxlbW9cXFxcXFxcXC5tZS8udGVzdChqaWVrKSkge1xcXFxuICAgICAgICBqaWVrID0gamllay5yZXBsYWNlKCdhaWxlbW8nLCAnYWlsZW1vbycpO1xcXFxuICAgIH07XFxcXG4gICAgLy/miZPljbDmjqXlj6NcXFxcbiAgICB0cnkge1xcXFxuICAgICAgICBpZiAoaiA9PSAnMCcpIHtcXFxcbiAgICAgICAgICAgIGlmIChodG1sLmRhdGEudm9kX3VybF93aXRoX3BsYXllcikge1xcXFxuICAgICAgICAgICAgICAgIGxvZygnXFxcXFxcXFxu57q/6Lev77yaJyArIHB0YWIgKyAnXFxcXFxcXFxu6KeG6aKR77yaJyArIHZsaW5rICsgJ1xcXFxcXFxcbicgKyAn6Kej5p6Q5o6l5Y+j77yaXFxcXFxcXFxuJyArIGppZWspO1xcXFxuICAgICAgICAgICAgfSBlbHNlIGlmIChodG1sLmRhdGEudm9kX2luZm8gJiYgaHRtbC5kYXRhLnZvZF9pbmZvLnZvZF91cmxfd2l0aF9wbGF5ZXIpIHtcXFxcbiAg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+dfOacny9nLCAnJykgOiB0aXRsZTtcXFxcbiAgICBpZiAobGlzdC5sZW5ndGggPD0gNCkge1xcXFxuICAgICAgICB2YXIgY2x0ID0gJ3RleHRfMic7XFxcXG4gICAgfSBlbHNlIHtcXFxcbiAgICAgICAgdmFyIGNsdCA9IGlzTmFOKHRpdGxlKSA/ICdmbGV4X2J1dHRvbicgOiAndGV4dF81J1xcXFxuICAgIH07XFxcXG4gICAgaXRlbXMucHVzaCh7XFxcXG4gICAgICAgIHRpdGxlOiB0aXRsZSxcXFxcbiAgICAgICAgdXJsOiAkKCdoaWtlcjovL2VtcHR5JykubGF6eVJ1bGUoKHB0YWIsIGxpbmssIG15dXJsLCB2bGluaykgPT4ge1xcXFxuICAgICAgICAgICAgICAgIGZ1bmN0aW9uIG9wZW51cmwocmVzdXJsKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIGlmIChyZXN1cmwubWF0Y2goL3lvdWt1fG1ndHZ8aXhpZ3VhfHFxLmNvbXxxaXlpfG1pZ3V8YmlsaWJpbGl8c29odXxwcHR2fGxlfDE5MDUuY29tLykgJiYgcmVzdXJsLnNlYXJjaCgvaHRtbHxiaWxpYmlsaXxpeGlndWEvKSAhPSAtMSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgLy9odG1s572R6aG16LCD55So5pat5o+S6Kej5p6QXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgZW5EbiA9IEpTT04ucGFyc2UoZmV0Y2goJ2hpa2VyOi8vZmlsZXMvcnVsZXMveHlxL2FwcG1zZXQuanNvbicsIHt9KSkuZW5EbjtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChlbkRuID09ICcxJykge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxvZygn6LCD55So5pat5o+S6Kej5p6QaHRtbCcpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoXFxcXFxcXCJ2YXIgY29uZmlnID1cXFxcXFxcIiArIGZldGNoKFxcXFxcXFwiaGlrZXI6Ly9maWxlcy9jYWNoZS9NeVBhcnNlU2V0Lmpzb25cXFxcXFxcIikpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoZmV0Y2goY29uZmlnLmNqKSk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGF5dG1QYXJzZShyZXN1cmwpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVzdXJsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9O1xcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9cXFxcXFxcXC5tM3U4fFxcXFxcXFxcLm1wNHxvYmpcXFxcXFxcXC90b3N8bmV0ZWFzZVxcXFxcXFxcLmNvbS8udGVzdChyZXN1cmwpICYmIC9odHRwLy50ZXN0KHJlc3VybCkgJiYgIS9cXFxcXFxcXC5odG1sLy50ZXN0KHJlc3VybCkgJiYgIS9cXFxcXFxcXD1odHRwLy50ZXN0KHJlc3VybCkgJiYgcHRhYiAhPSAnZHVvZHVvenknKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoL3drZmlsZS8udGVzdChyZXN1cmwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJlc3VybCArICc7e1JlZmVyZXJAaHR0cHM6Ly9mYW50dWFuLndrZmlsZS5jb20vfSdcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIC9cXFxcXFxcXD1odC8udGVzdChyZXN1cmwpID8gcmVzdXJsLnN1YnN0cmluZyhyZXN1cmwuaW5kZXhPZignPWh0JykgKyAxKSA6IHJlc3VybCArICcjaXNWaWRlbz10cnVlIyc7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAvL+iwg+eUqOaWreaPkumAmueUqOWHveaVsOino+aekFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGVuRG4gPSBKU09OLnBhcnNlKGZldGNoKCdoaWtlcjovL2ZpbGVzL3J1bGVzL3h5cS9hcHBtc2V0Lmpzb24nLCB7fSkpLmVuRG47XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoZW5EbiA9PSAnMScpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsb2coJ+iwg+eUqOaWreaPkumAmueUqOWHveaVsOino+aekFxcXFxcXFxcbicgKyBwdGFiICsgJyjpgJrnlKjlh73mlbApJyk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZXZhbChcXFxcXFxcInZhciBjb25maWcgPVxcXFxcXFwiICsgZmV0Y2goXFxcXFxcXCJoaWtlcjovL2ZpbGVzL2NhY2hlL015UGFyc2VTZXQuanNvblxcXFxcXFwiKSk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZXZhbChmZXRjaChjb25maWcuY2opKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgbmFtZSA9IHB0YWIgKyAnKOmAmueUqOWHveaVsCknO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBQYXJzZVNbbmFtZV0ocmVzdXJsLCBteXVybCk7XFxcXG5cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAocHRhYiA9PSAnZHVvZHVvenknKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZXZhbChnZXRDcnlwdG9KUygpKTtcXFxcblxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGZ1bmN0aW9uIERlKHdvcmQpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGEgPSBDcnlwdG9KUy5lbmMuVXRmOC5wYXJzZShtZDUoJ3JYald2WGw2JykpXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciB0ID0gQ3J5cHRvSlMuZW5jLlV0ZjgucGFyc2UoJ05YYkhvV0picHNFT2luOGInKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gQ3J5cHRvSlMuQUVTLmRlY3J5cHQod29yZCwgYSwge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaXY6IHQsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtb2RlOiBDcnlwdG9KUy5tb2RlLkNCQyxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBhZGRpbmc6IENyeXB0b0pTLnBhZC5Qa2NzN1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KS50b1N0cmluZyhDcnlwdG9KUy5lbmMuVXRmOClcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9O1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBkZHp5ID0gJ2FoSGdSajBrY2VIZE1jNjZMNXk0JyArIGJhc2U2NEVuY29kZShyZXN1cmwpLnNsaWNlKDEwKS5yZXBsYWNlKC9cXFxcXFxcXD0vZywnTzBPME8nKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvL2h0dHBzOi8vYm8uZGQ1MjAuY2MveHBsYXkvYXBpLnBocFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vaHR0cHM6Ly9iby5kZDUyMC5jYy94bXBsYXllci9hcGkucGhwICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBkZHd5ID0gZmV0Y2goJ2h0dHBzOi8vYm8uZGQ1MjAuY2MveG1wbGF5ZXIvZHVvZHVvLnBocCcsIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcXFxcXCJVc2VyLUFnZW50XFxcXFxcXCI6IE1PQklMRV9VQVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBib2R5OiAndXJsPScgKyBkZHp5LFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICdQT1NUJ1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vbG9nKGRkd3kpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBEZShKU09OLnBhcnNlKGRkd3kpLnVybCk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9taWFvcGFydHkvLnRlc3QocHRhYikpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXF1aXJlQ2FjaGUoJ2h0dHBzOi8vY29kZS5hbGl5dW4uY29tL2x6azIzNTU5L1B1YmxpY1J1bGUvcmF3L21hc3Rlci94NXJ1bGUuanMnLCAyNCk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHg1cnVsZSgnaHR0cHM6Ly93d3cuZnVuNGsuY29tL2FwbGF5ZXIvP3VybD0nICsgcmVzdXJsKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJlc3VybFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfTtcXFxcbiAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgIH07XFxcXG4gICAgICAgICAgICAgICAgXFxcXG4gICAgICAgICAgICAgICAgdHJ5IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIGVuRG4gPSBKU09OLnBhcnNlKGZldGNoKCdoaWtlcjovL2ZpbGVzL3J1bGVzL3h5cS9hcHBtc2V0Lmpzb24nLCB7fSkpLmVuRG47XFxcXG4gICAgICAgICAgICAgICAgICAgIGlmIChlbkRuID09ICcxJyAmJiB2bGluay5tYXRjaCgveW91a3V8bWd0dnxpeGlndWF8cXEuY29tfHFpeWl8bWlndXxiaWxpYmlsaXxzb2h1fHBwdHZ8bGV8MTkwNS5jb20vKSAmJiB2bGluay5zZWFyY2goL2h0bWx8YmlsaWJpbGl8aXhpZ3VhLykgIT0gLTEpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGxvZygn5bey5byA5ZCv5pat5o+S77yM5bCG6LCD55So5pat5o+S6Kej5p6QaHRtbCcpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgZXZhbChcXFxcXFxcInZhciBjb25maWcgPVxcXFxcXFwiICsgZmV0Y2goXFxcXFxcXCJoaWtlcjovL2ZpbGVzL2NhY2hlL015UGFyc2VTZXQuanNvblxcXFxcXFwiKSk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBldmFsKGZldGNoKGNvbmZpZy5jaikpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGF5dG1QYXJzZSh2bGluayk7XFxcXG4gICAgICAgICAgICAgICAgICAgIH07XFxcXG4gICAgICAgICAgICAgICAgfSBjYXRjaCAoZSkge31cXFxcbiAgICAgICAgICAgICAgICBcXFxcbiAgICAgICAgICAgICAgICB2YXIgc3JjdXJsID0gbGluaztcXFxcbiAgICAgICAgICAgICAgICAvL2xvZyhzcmN1cmwpO1xcXFxuICAgICAgICAgICAgICAgIC8v5Yqo5oCB6Kej5p6Q5Luj56CB5byA5aeLXFxcXG4gICAgICAgICAgICAgICAgdHJ5IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgLy/lpITnkIbmjIflrprop4bpopHkuI7nur/ot69cXFxcbiAgICAgICAgICAgICAgICAgICAgaWYgKC9cXFxcXFxcXC5tM3U4fFxcXFxcXFxcLm1wNHxvYmpcXFxcXFxcXC90b3N8bmV0ZWFzZVxcXFxcXFxcLmNvbS8udGVzdChzcmN1cmwpICYmIC9odHRwLy50ZXN0KHNyY3VybCkgJiYgIS9cXFxcXFxcXC5odG1sLy50ZXN0KHNyY3VybCkgJiYgIS9cXFxcXFxcXD1odHRwLy50ZXN0KHNyY3VybCkpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICgvd2tmaWxlLy50ZXN0KHNyY3VybCkpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gc3JjdXJsICsgJzt7UmVmZXJlckBodHRwczovL2ZhbnR1YW4ud2tmaWxlLmNvbS99J1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gL1xcXFxcXFxcPWh0Ly50ZXN0KHNyY3VybCkgPyBzcmN1cmwuc3Vic3RyaW5nKHNyY3VybC5pbmRleE9mKCc9aHQnKSArIDEpIDogc3JjdXJsICsgJyNpc1ZpZGVvPXRydWUjJztcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmICgvaGQ4XFxcXFxcXFwucHcvLnRlc3QodmxpbmspICYmIC9cXFxcXFxcXC5tM3U4fFxcXFxcXFxcLm1wNC8udGVzdCh2bGluaykpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB2bGluaztcXFxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChzcmN1cmwuaW5kZXhPZihcXFxcXFxcIi9zaGFyZS9cXFxcXFxcIikgIT0gLTEpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHRyeSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGxpbmsgPSBzcmN1cmwuc3BsaXQoXFxcXFxcXCIvc2hhcmVcXFxcXFxcIilbMF07XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGZjID0gZmV0Y2goc3JjdXJsLCB7fSkucmVwbGFjZShcXFxcXFxcInZhciBwdXJsXFxcXFxcXCIsIFxcXFxcXFwidmFyIG1haW5cXFxcXFxcIik7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGZjLmluZGV4T2YoXFxcXFxcXCJtYWluXFxcXFxcXCIpICE9IC0xKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBtYXQgPSBmYy5tYXRjaCgvdmFyIG1haW4uKj87LylbMF07XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwobWF0KTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHBsYXkgPSAobWFpbi5pbmRleE9mKFxcXFxcXFwiaHR0cFxcXFxcXFwiKSAhPSAtMSA/IG1haW4gOiBsaW5rICsgbWFpbik7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG1haW4gPSBmYy5tYXRjaCgvdXJsOi4qP1tcXFxcXFxcXCdcXFxcXFxcXFxcXFxcXFwiXSguKj8pW1xcXFxcXFxcJ1xcXFxcXFxcXFxcXFxcXCJdLylbMV07XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwbGF5ID0gKG1haW4uaW5kZXhPZihcXFxcXFxcImh0dHBcXFxcXFxcIikgIT0gLTEgPyBtYWluIDogbGluayArIG1haW4pXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcGxheTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gJ3g1V2ViVmlldzovLycgKyAoc3JjdXJsKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcXFxuXFxcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoLzk4M3ZpcC8udGVzdChzcmN1cmwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gSlNPTi5wYXJzZShmZXRjaChzcmN1cmwsIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWFkZXJzOiB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXFxcXFwiVXNlci1BZ2VudFxcXFxcXFwiOiBNT0JJTEVfVUFcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJlZGlyZWN0OiBmYWxzZSxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aXRoSGVhZGVyczogdHJ1ZVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSkpLmhlYWRlcnMubG9jYXRpb25bMF07XFxcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL3hcXFxcXFxcXC1uXFxcXFxcXFwuY2N8bmhkejY2Ni8udGVzdChzcmN1cmwpICYmIC9cXFxcXFxcXC5odG1sfGJpbGliaWxpLy50ZXN0KHNyY3VybCkpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBvcGVudXJsKHZsaW5rKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgICAgICAvL+WkhOeQhuaMh+WumuinhumikeWSjOe6v+i3r+e7k+adn1xcXFxuICAgICAgICAgICAgICAgICAgICAvLy0tLS3liIblibLnur8tLS0tLy9cXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIHNjb2RlID0gSlNPTi5wYXJzZShmZXRjaChzcmN1cmwsIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBcXFxcXFxcIlVzZXItQWdlbnRcXFxcXFxcIjogXFxcXFxcXCJva2h0dHAvNC4xLjBcXFxcXFxcIlxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJlZGlyZWN0OiBmYWxzZSxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHdpdGhTdGF0dXNDb2RlOiB0cnVlXFxcXG4gICAgICAgICAgICAgICAgICAgIH0pKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgLy9sb2coc2NvZGUpO1xcXFxuICAgICAgICAgICAgICAgICAgICBpZiAoc2NvZGUuc3RhdHVzQ29kZSA9PSAnMzAyJyB8fCBzY29kZS5zdGF0dXNDb2RlID09ICczMDEnKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAvL+aJk+W8gOino+aekOaciTMwMumHjeWumuWQkeeahOmTvuaOpVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlZHVybCA9IHNjb2RlLmhlYWRlcnMubG9jYXRpb25bMF0ucmVwbGFjZSgvXFxcXFxcXFxcXFxcXFxcXC9nLCAnJyk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoL1xcXFxcXFxcPWh0dHAvLnRlc3QocmVkdXJsKSAmJiAvaHRtbHxiaWxpYmlsaXxrZXlcXFxcXFxcXD0vLnRlc3QocmVkdXJsKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBKU09OLnBhcnNlKGZldGNoKHJlZHVybCwge30pKS51cmw7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9cXFxcXFxcXD1odHRwLy50ZXN0KHJlZHVybCkgJiYgL1xcXFxcXFxcLm0zdTh8XFxcXFxcXFwubXA0fFxcXFxcXFxcLmZsdi8udGVzdChyZWR1cmwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJlZHVybC5zdWJzdHJpbmcocmVkdXJsLmluZGV4T2YoJz1odHRwJykgKyAxKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL2h0dHAvLnRlc3QocmVkdXJsKSAmJiAva2V5XFxcXFxcXFw9fHVpZFxcXFxcXFxcPS8udGVzdChyZWR1cmwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIEpTT04ucGFyc2UoZmV0Y2gocmVkdXJsLCB7fSkpLnVybDtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL2h0dHAvLnRlc3QocmVkdXJsKSAmJiAvaHRtbHxiaWxpYmlsaS8udGVzdChyZWR1cmwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9wZW51cmwodmxpbmspO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVkdXJsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAvL3ZhciBodG1sID0gcmVxdWVzdChzcmN1cmwpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGh0bWwgPSBzY29kZS5ib2R5O1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgLy9sb2coaHRtbCk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoLzQwNCBOb3QgRm91bmR85aSH5qGI5ZCO5Y+v57un57ut6K6/6ZeuLy50ZXN0KGh0bWwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9wZW51cmwodmxpbmspO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmICgvXFxcXFxcXFw8Ym9keS8udGVzdChodG1sKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxvZygn5bCd6K+V6Z2eSlNPTuaOpeWPo+e9kemhteino+aekCcpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJlcXVpcmVDYWNoZSgnaHR0cHM6Ly9jb2RlLmFsaXl1bi5jb20vbHprMjM1NTkvUHVibGljUnVsZS9yYXcvbWFzdGVyL3g1cnVsZS5qcycsIDI0KTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4geDVydWxlKHNyY3VybCwgc3JjdXJsKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvL3JldHVybiBvcGVudXJsKHNyY3VybCk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vanNvbuino+aekOeahOWPlumTvuaOpVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwdXJsID0gaHRtbC5tYXRjaCgvW1xcXFxcXFxcJ1xcXFxcXFxcXFxcXFxcXCJddXJsW1xcXFxcXFxcJ1xcXFxcXFxcXFxcXFxcXCJdOi4qP1tcXFxcXFxcXCdcXFxcXFxcXFxcXFxcXFwiXSguKj8pW1xcXFxcXFxcJ1xcXFxcXFxcXFxcXFxcXCJdLylbMV0ucmVwbGFjZSgvXFxcXFxcXFxcXFxcXFxcXC9nLCAnJyk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy9sb2cocHVybCk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKC9odHRwLy50ZXN0KHB1cmwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChwdGFiID09ICdiaWxpYmlsaScpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJzt7UmVmZXJlckBodHRwczovL3d3dy5iaWxpYmlsaS5jb20vJiZVc2VyLUFnZW50QE1vemlsbGEvNS4wfSc7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAocHRhYiA9PSAnbWd0dicpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJyNpc1ZpZGVvPXRydWUjJyArICc7e1JlZmVyZXJAd3d3Lm1ndHYuY29tJiZVc2VyLUFnZW50QE1vemlsbGEvNS4wfSc7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL29qYmsvLnRlc3QocHVybCkpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJzt7UmVmZXJlckBodHRwczovL2Jhay5vamJranguY29tL30nO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYoL3ZpZGVvX21wNHx0eXBlXFxcXFxcXFw9bTN1OHxwdFxcXFxcXFxcPW0zdTh8XFxcXFxcXFwvdmlkZW9cXFxcXFxcXC90b3NcXFxcXFxcXC8vLnRlc3QocHVybCkpe1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHB1cmwgKyAnI2lzVmlkZW89dHJ1ZSMnO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHB1cmxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvL+mdnmh0dHDlvIDlpLTnmoTmiZPlvIDljp/pk77mjqUgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBvcGVudXJsKHZsaW5rKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgLy/miqXplJnliKTmlq3lpITnkIZcXFxcbiAgICAgICAgICAgICAgICAgICAgbG9nKCfmiafooYzmiqXplJnot7PovazlpITnkIYnKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgLyppZiAoc3JjdXJsLnN1YnN0cmluZygwLCAyKSA9PSAnXFxcXFxcXFwvXFxcXFxcXFwvJykge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9wZW51cmwoJ2h0dHBzOicgKyBzcmN1cmwpO1xcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9cXFxcXFxcXD1odHRwLy50ZXN0KHNyY3VybCkgJiYgL1xcXFxcXFxcLmh0bWx8YmlsaWJpbGkvLnRlc3Qoc3JjdXJsKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgLy9yZXR1cm4gc3JjdXJsLnNwbGl0KCc9JylbMV07XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gb3BlbnVybChzcmN1cmwuc3Vic3RyaW5nKHNyY3VybC5pbmRleE9mKCc9aHR0cCcpICsgMSkpO1xcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgeyovXFxcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBvcGVudXJsKHZsaW5rKVxcXFxuICAgICAgICAgICAgICAgICAgICAvL3JldHVybiAneDVXZWJWaWV3Oi8vJytzcmN1cmxcXFxcbiAgICAgICAgICAgICAgICAgICAgLy99XFxcXG4gICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgIC8v5Yqo5oCB6Kej5p6Q5Luj56CB57uT5p2fXFxcXG4gICAgICAgICAgICB9LFxcXFxuICAgICAgICAgICAgcHRhYixcXFxcbiAgICAgICAgICAgIGxpbmssXFxcXG4gICAgICAgICAgICBteXVybCxcXFxcbiAgICAgICAgICAgIHZsaW5rKSxcXFxcbiAgICAgICAgY29sX3R5cGU6IGNsdFxcXFxuICAgIH0pO1xcXFxufVxcXFxuLy99XFxcIn0se1xcXCJjb2xfdHlwZVxcXCI6XFxcIm1vdmllXzNcXFwiLFxcXCJuYW1lXFxcIjpcXFwiVFbnroDku4vkuI7pgInpm4ZcXFwiLFxcXCJwYXRoXFxcIjpcXFwidHZtb3ZsaXN0XFxcIixcXFwicnVsZVxcXCI6XFxcInZhciB0YWJzID0gT2JqZWN0LmtleXMoaHRtbC52aWRlb2xpc3QpO1xcXFxudmFyIHRodW1iID0gaHRtbC5pbWdfdXJsO1xcXFxuaXRlbXMucHVzaCh7XFxcXG4gICAgdGl0bGU6ICfliafmg4XnroDku4vvvJonLFxcXFxuICAgIGRlc2M6IGh0bWwuaW50cm8sXFxcXG4gICAgcGljX3VybDogdGh1bWIsXFxcXG4gICAgdXJsOiAkKCdoaWtlcjovL2VtcHR5I25vUmVjb3JkSGlzdG9yeSMnKS5ydWxlKChkZXMpID0+IHtcXFxcbiAgICAgICAgc2V0UmVzdWx0KFt7XFxcXG4gICAgICAgICAgICB0aXRsZTogZGVzLFxcXFxuICAgICAgICAgICAgY29sX3R5cGU6ICdsb25nX3RleHQnXFxcXG4gICAgICAgIH1dKTtcXFxcbiAgICB9LCBodG1sLmludHJvKSxcXFxcbiAgICBjb2xf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2ZsZXhfYnV0dG9uJyA6ICd0ZXh0XzUnXFxcXG4gICAgfTtcXFxcbiAgICBpdGVtcy5wdXNoKHtcXFxcbiAgICAgICAgdGl0bGU6IHRpdGxlLFxcXFxuICAgICAgICB1cmw6ICQoJ2hpa2VyOi8vZW1wdHknKS5sYXp5UnVsZSgocHRhYiwgc3JjdXJsLCBteXVybCkgPT4ge1xcXFxuICAgICAgICAgICAgZnVuY3Rpb24gb3BlbnVybChyZXN1cmwpIHtcXFxcbiAgICAgICAgICAgICAgICBpZiAocmVzdXJsLm1hdGNoKC95b3VrdXxtZ3R2fGl4aWd1YXxxcS5jb218cWl5aXxtaWd1fGJpbGliaWxpfHNvaHV8cHB0dnxsZXwxOTA1LmNvbS8pICYmIHJlc3VybC5zZWFyY2goL2h0bWx8YmlsaWJpbGkvKSAhPSAtMSkge1xcXFxuICAgICAgICAgICAgICAgICAgICB2YXIgZW5EbiA9IEpTT04ucGFyc2UoZmV0Y2goJ2hpa2VyOi8vZmlsZXMvcnVsZXMveHlxL2FwcG1zZXQuanNvbicsIHt9KSkuZW5EbjtcXFxcbiAgICAgICAgICAgICAgICAgICAgaWYgKGVuRG4gPT0gJzEnKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBsb2coJ+iwg+eUqOaWreaPkuino+aekCcpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgZXZhbChcXFxcXFxcInZhciBjb25maWcgPVxcXFxcXFwiICsgZmV0Y2goXFxcXFxcXCJoaWtlcjovL2ZpbGVzL2NhY2hlL015UGFyc2VTZXQuanNvblxcXFxcXFwiKSk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBldmFsKGZldGNoKGNvbmZpZy5jaikpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGF5dG1QYXJzZShyZXN1cmwpO1xcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJlc3VybFxcXFxuICAgICAgICAgICAgICAgICAgICB9O1xcXFxuICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoL1xcXFxcXFxcPUxUXFxcXFxcXFwtLy50ZXN0KHJlc3VybCkpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgbG9nKCfosIPnlKjmlq3mj5JsdG5i6YCa55So6Kej5p6QJyk7XFxcXG4gICAgICAgICAgICAgICAgICAgIGV2YWwoXFxcXFxcXCJ2YXIgY29uZmlnID1cXFxcXFxcIiArIGZldGNoKFxcXFxcXFwiaGlrZXI6Ly9maWxlcy9jYWNoZS9NeVBhcnNlU2V0Lmpzb25cXFxcXFxcIikpO1xcXFxuICAgICAgICAgICAgICAgICAgICBldmFsKGZldGNoKGNvbmZpZy5jaikpO1xcXFxuICAgICAgICAgICAgICAgICAgICB2YXIgbmFtZSA9ICdsdG5iKOmAmueUqOWHveaVsCknO1xcXFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gUGFyc2VTW25hbWVdKHJlc3VybC5zdWJzdHJpbmcocmVzdXJsLmluZGV4T2YoJz1MVC0nKSArIDEpKTtcXFxcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVzdXJsXFxcXG4gICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgfTtcXFxcbiAgICAgICAgICAgIFxcXFxuICAgICAgICAgICAgdHJ5IHtcXFxcbiAgICAgICAgICAgICAgICB2YXIgZW5EbiA9IEpTT04ucGFyc2UoZmV0Y2goJ2hpa2VyOi8vZmlsZXMvcnVsZXMveHlxL2FwcG1zZXQuanNvbicsIHt9KSkuZW5EbjtcXFxcbiAgICAgICAgICAgICAgICBpZiAoZW5EbiA9PSAnMScgJiYgc3JjdXJsLm1hdGNoKC95b3VrdXxtZ3R2fGl4aWd1YXxxcS5jb218cWl5aXxtaWd1fGJpbGliaWxpfHNvaHV8cHB0dnxsZXwxOTA1LmNvbS8pICYmIHNy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cXFxuICAgICAgICAgICAgICAgICAgICB0cnkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGxpbmsgPSBzcmN1cmwuc3BsaXQoXFxcXFxcXCIvc2hhcmVcXFxcXFxcIilbMF07XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgZmMgPSBmZXRjaChzcmN1cmwsIHt9KS5yZXBsYWNlKFxcXFxcXFwidmFyIHB1cmxcXFxcXFxcIiwgXFxcXFxcXCJ2YXIgbWFpblxcXFxcXFwiKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChmYy5pbmRleE9mKFxcXFxcXFwibWFpblxcXFxcXFwiKSAhPSAtMSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBtYXQgPSBmYy5tYXRjaCgvdmFyIG1haW4uKj87LylbMF07XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZXZhbChtYXQpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwbGF5ID0gKG1haW4uaW5kZXhPZihcXFxcXFxcImh0dHBcXFxcXFxcIikgIT0gLTEgPyBtYWluIDogbGluayArIG1haW4pO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgbWFpbiA9IGZjLm1hdGNoKC91cmw6Lio/W1xcXFxcXFxcJ1xcXFxcXFxcXFxcXFxcXCJdKC4qPylbXFxcXFxcXFwnXFxcXFxcXFxcXFxcXFxcIl0vKVsxXTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcGxheSA9IChtYWluLmluZGV4T2YoXFxcXFxcXCJodHRwXFxcXFxcXCIpICE9IC0xID8gbWFpbiA6IGxpbmsgKyBtYWluKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwbGF5O1xcXFxuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gJ3g1V2ViVmlldzovLycgKyAoc3JjdXJsKVxcXFxuICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChwdGFiID09ICdhbGl6eScpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIHB1cmwgPSBmZXRjaCgnaHR0cHM6Ly9mb3ViaW4uY29tL2ppZXhpLnBocD91cmw9JyArIHNyY3VybCwge30pLm1hdGNoKC9cXFxcXFxcXFxcXFxcXFwidXJsXFxcXFxcXFxcXFxcXFxcIjpcXFxcXFxcXFxcXFxcXFwiKC4qPylcXFxcXFxcXFxcXFxcXFwiLylbMV07XFxcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsO1xcXFxuICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoLzE5anhcXFxcXFxcXC52aXB8bmZ5aW5nc2hpLy50ZXN0KHNyY3VybCkpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIHB1cmwgPSBKU09OLnBhcnNlKGZldGNoKHNyY3VybC5yZXBsYWNlKCdodHRwOi8vJywgJ2h0dHBzOi8vJyksIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBcXFxcXFxcIlVzZXItQWdlbnRcXFxcXFxcIjogTU9CSUxFX1VBXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9LFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmVkaXJlY3Q6IGZhbHNlLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgd2l0aEhlYWRlcnM6IHRydWVcXFxcbiAgICAgICAgICAgICAgICAgICAgfSkpLmhlYWRlcnMubG9jYXRpb25bMF07XFxcXG4gICAgICAgICAgICAgICAgICAgIGlmICgvdGl0YW4ubWd0di8udGVzdChwdXJsKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHB1cmwgKyAnI2lzVmlkZW89dHJ1ZSMnICsgJzt7UmVmZXJlckB3d3cubWd0di5jb20mJlVzZXItQWdlbnRATW96aWxsYS81LjB9JztcXFxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmICgvb2JqXFxcXFxcXFwvdG9zLy50ZXN0KHB1cmwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcHVybCArICcjaXNWaWRlbz10cnVlIyc7XFxcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcHVybFxcXFxuICAgICAgICAgICAgICAgICAgICB9O1xcXFxuICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAvKmVsc2UgaWYgKC96aGFpa2FueXMvLnRlc3Qoc3JjdXJsKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHB1cmwgPSBKU09OLnBhcnNlKGZldGNoKHNyY3VybCArICcmYXBwPTEwMDAzJmFjY291bnQ9MjcyNzc1MDI4JnBhc3N3b3JkPXFxMjcyNzc1MDI4Jywge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcXFxcXCJVc2VyLUFnZW50XFxcXFxcXCI6IE1PQklMRV9VQVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmVkaXJlY3Q6IGZhbHNlLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHdpdGhIZWFkZXJzOiB0cnVlXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KSkuaGVhZGVycy5sb2NhdGlvblswXTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICgvdGl0YW4ubWd0di8udGVzdChwdXJsKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJyNpc1ZpZGVvPXRydWUjJyArICc7e1JlZmVyZXJAd3d3Lm1ndHYuY29tJiZVc2VyLUFnZW50QE1vemlsbGEvNS4wfSc7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKC9vYmpcXFxcXFxcXC90b3MvLnRlc3QocHVybCkpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcHVybCArICcjaXNWaWRlbz10cnVlIyc7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9O1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9Ki9cXFxcblxcXFxuICAgICAgICAgICAgICAgIC8vLS0tLeWIhuWJsue6vy0tLS0vL1xcXFxuICAgICAgICAgICAgICAgIHZhciBzY29kZSA9IEpTT04ucGFyc2UoZmV0Y2goc3JjdXJsLCB7XFxcXG4gICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIFxcXFxcXFwiVXNlci1BZ2VudFxcXFxcXFwiOiBNT0JJTEVfVUFcXFxcbiAgICAgICAgICAgICAgICAgICAgfSxcXFxcbiAgICAgICAgICAgICAgICAgICAgcmVkaXJlY3Q6IGZhbHNlLFxcXFxuICAgICAgICAgICAgICAgICAgICB3aXRoU3RhdHVzQ29kZTogdHJ1ZVxcXFxuICAgICAgICAgICAgICAgIH0pKTtcXFxcbiAgICAgICAgICAgICAgICAvL2xvZyhzY29kZSk7XFxcXG4gICAgICAgICAgICAgICAgaWYgKHNjb2RlLnN0YXR1c0NvZGUgPT0gJzMwMicgfHwgc2NvZGUuc3RhdHVzQ29kZSA9PSAnMzAxJykge1xcXFxuICAgICAgICAgICAgICAgICAgICB2YXIgcHVybCA9IHNjb2RlLmhlYWRlcnMubG9jYXRpb25bMF0ucmVwbGFjZSgvXFxcXFxcXFxcXFxcXFxcXC9nLCAnJyk7XFxcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgLy92YXIgaHRtbCA9IHJlcXVlc3Qoc3JjdXJsKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIGh0bWwgPSBzY29kZS5ib2R5O1xcXFxuICAgICAgICAgICAgICAgICAgICAvL2xvZyhodG1sKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgaWYgKC80MDQgTm90IEZvdW5kfOWkh+ahiOWQjuWPr+e7p+e7reiuv+mXrnzkuI3lrZjlnKgvLnRlc3QoaHRtbCkgfHwgaHRtbCA9PSAnJykge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9wZW51cmwoc3JjdXJsLnN1YnN0cmluZyhzcmN1cmwuaW5kZXhPZignPWh0dHAnKSArIDEpKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmICgvXFxcXFxcXFxcXFxcXFxcInVybFxcXFxcXFxcXFxcXFxcXCJcXFxcXFxcXDpcXFxcXFxcXFxcXFxcXFwiaHR0cC8udGVzdChodG1sKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHB1cmwgPSBodG1sLm1hdGNoKC9cXFxcXFxcXFxcXFxcXFwidXJsXFxcXFxcXFxcXFxcXFxcIjpcXFxcXFxcXFxcXFxcXFwiKC4qPylcXFxcXFxcXFxcXFxcXFwiLylbMV0ucmVwbGFjZSgvXFxcXFxcXFxcXFxcXFxcXC9nLCAnJyk7XFxcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoaHRtbC5zdGFydHNXaXRoKCd7JykpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwdXJsID0gc3JjdXJsLnN1YnN0cmluZyhzcmN1cmwuaW5kZXhPZignPWh0dHAnKSArIDEpO1xcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgLy92YXIgcHVybCA9IHNyY3VybFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmVxdWlyZUNhY2hlKCdodHRwczovL2NvZGUuYWxpeXVuLmNvbS9semsyMzU1OS9QdWJsaWNSdWxlL3Jhdy9tYXN0ZXIveDVydWxlLmpzJywgMjQpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHg1cnVsZShzcmN1cmwsIHNyY3VybCk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAvL3JldHVybiAneDVXZWJWaWV3Oi8vJysoc3JjdXJsKSBcXFxcbiAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgIH07XFxcXG4gICAgICAgICAgICAgICAgLy9sb2cocHVybCk7XFxcXG4gICAgICAgICAgICAgICAgaWYgKC90aXRhbi5tZ3R2Ly50ZXN0KHB1cmwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJyNpc1ZpZGVvPXRydWUjJyArICc7e1JlZmVyZXJAd3d3Lm1ndHYuY29tJiZVc2VyLUFnZW50QE1vemlsbGEvNS4wfSc7XFxcXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmICgvb2JqXFxcXFxcXFwvdG9zLy50ZXN0KHB1cmwpKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBwdXJsICsgJyNpc1ZpZGVvPXRydWUjJztcXFxcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gcHVybFxcXFxuICAgICAgICAgICAgICAgIH07XFxcXG5cXFxcbiAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHtcXFxcbiAgICAgICAgICAgICAgICBpZiAoc3JjdXJsLnN1YnN0cmluZygwLCAyKSA9PSAnXFxcXFxcXFwvXFxcXFxcXFwvJykge1xcXFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gb3BlbnVybCgnaHR0cHM6JyArIHNyY3VybCk7XFxcXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmICgvXFxcXFxcXFw9aHR0cC8udGVzdChzcmN1cmwpICYmIC9cXFxcXFxcXC5odG1sfGJpbGliaWxpLy50ZXN0KHNyY3VybCkpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgLy9yZXR1cm4gc3JjdXJsLnNwbGl0KCc9JylbMV07XFxcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBvcGVudXJsKHNyY3VybC5zdWJzdHJpbmcoc3JjdXJsLmluZGV4T2YoJz1odHRwJykgKyAxKSk7XFxcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9wZW51cmwoc3JjdXJsKVxcXFxuICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgIC8v5Yqo5oCB6Kej5p6Q5Luj56CB57uT5p2fXFxcXG4gICAgICAgIH0sIHB0YWIsIHNyY3VybCwgbXl1cmwpLFxcXFxuICAgICAgICBjb2xfdHlwZTogY2x0XFxcXG4gICAgfSk7XFxcXG59XFxcXG4vL31cXFwifSx7XFxcImNvbF90eXBlXFxcIjpcXFwibW92aWVfM1xcXCIsXFxcIm5hbWVcXFwiOlxcX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FxcXG4gICAgfSBlbHNlIHtcXFxcbiAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBsaXN0Lmxlbmd0aDsgaSsrKSB7XFxcXG5cXFxcbiAgICAgICAgICAgIGlmICgvXFxcXFxcXFwvdm9kXFxcXFxcXFwvLy50ZXN0KHRkb21pbikpIHtcXFxcbiAgICAgICAgICAgICAgICB2YXIgdGl0bGUgPSBsaXN0W2ldLnRpdGxlO1xcXFxuICAgICAgICAgICAgICAgIHZhciBwaWMgPSBsaXN0W2ldLnBpYztcXFxcbiAgICAgICAgICAgICAgICAvL3ZhciB2aWQ9dGRvbWluKycvZGV0YWlsP3ZvZF9pZD0nK2xpc3RbaV0ubmV4dGxpbmsrJyZyZWxfbGltaXQ9MTAnO1xcXFxuICAgICAgICAgICAgICAgIHZhciB2aWQgPSBsaXN0W2ldLm5leHRsaW5rO1xcXFxuICAgICAgICAgICAgICAgIHZhciByZW0gPSBsaXN0W2ldLnN0YXRlO1xcXFxuICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnN0YXRlO1xcXFxuICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICBpZiAodGRvbWluLmluZGV4T2YoJ2FwaS5waHAvYXBwLycpICE9IC0xKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciB0aXRsZSA9IGxpc3RbaV0udm9kX25hbWU7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciBwaWMgPSBsaXN0W2ldLnZvZF9waWM7XFxcXG4gICAgICAgICAgICAgICAgICAgIGlmICgvZmFudHVhbi8udGVzdCh0ZG9taW4pKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgdmlkID0gJ2h0dHBzOi8vZmFudHVhbi53a2ZpbGUuY29tL2FwaS5waHAvYXBwL3ZpZGVvX2RldGFpbD9pZD0nICsgbGlzdFtpXS52b2RfaWQgKyAnJnRva2VuPSc7XFxcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgdmlkID0gdGRvbWluICsgJ3ZpZGVvX2RldGFpbD9pZD0nICsgbGlzdFtpXS52b2RfaWQgKyAnJnRva2VuPSc7XFxcXG4gICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIHJlbSA9IGxpc3RbaV0udm9kX3JlbWFya3M7XFxcXG4gICAgICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnR5cGUudHlwZV9kZXM7XFxcXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmICh0ZG9taW4uaW5kZXhPZigneGdhcHAucGhwL3YxLycpICE9IC0xKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciB0aXRsZSA9IGxpc3RbaV0udm9kX25hbWU7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciBwaWMgPSBsaXN0W2ldLnZvZF9waWM7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciB2aWQgPSB0ZG9taW4gKyAndmlkZW9fZGV0YWlsP2lkPScgKyBsaXN0W2ldLnZvZF9pZDtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIHJlbSA9IGxpc3RbaV0udm9kX3JlbWFya3M7XFxcXG4gICAgICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnR5cGUudHlwZV9kZXM7XFxcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIHRpdGxlID0gbGlzdFtpXS52b2RfbmFtZTtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIHBpYyA9IGxpc3RbaV0udm9kX3BpYztcXFxcbiAgICAgICAgICAgICAgICAgICAgaWYgKC9pb3Blbnl1bi8udGVzdCh0ZG9taW4pKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgdmlkID0gdGRvbWluICsgJy9kZXRhaWxJRD92b2RfaWQ9JyArIGxpc3RbaV0udm9kX2lkICsgJyZ0b2tlbj0nO1xcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHZpZCA9IHRkb21pbiArICcvZGV0YWlsP2tleT0nICsgZGF0ZVN0ciArICcmdm9kX2lkPScgKyBsaXN0W2ldLnZvZF9pZCArICcmdG9rZW49JztcXFxcbiAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgICAgICB2YXIgcmVtID0gbGlzdFtpXS52b2RfcmVtYXJrcztcXFxcbiAgICAgICAgICAgICAgICAgICAgLy92YXIgY29uPWxpc3RbaV0udHlwZS50eXBlX2RlcztcXFxcbiAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICB9XFxcXG5cXFxcbiAgICAgICAgICAgIGl0ZW1zLnB1c2goe1xcXFxuICAgICAgICAgICAgICAgIHRpdGxlOiB0aXRsZS5yZXBsYWNlKGtleSwgJ+KAnOKAnCcgKyBrZXkgKyAn4oCd4oCdJyksXFxcXG4gICAgICAgICAgICAgICAgcGljX3VybDogcGljICsgJ0BSZWZlcmVyPScsXFxcXG4gICAgICAgICAgICAgICAgdXJsOiAkKHRkb21pbi5pbmRleE9mKFxcXFxcXFwibW9nYWlfYXBpXFxcXFxcXCIpICE9IC0xID8gdmlkICsgJztnZXQ7dXRmLTg7e1VzZXItQWdlbnRARGFydC8yLjE0IChkYXJ0OmlvKX0nIDogdmlkICsgJztnZXQ7dXRmLTg7e1VzZXItQWdlbnRAb2todHRwLzQuMS4wfScpLnJ1bGUoKHRkb21pbikgPT4ge1xcXFxuICAgICAgICAgICAgICAgICAgICB2YXIgcmVzID0ge307XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciBpdGVtcyA9IFtdO1xcXFxuICAgICAgICAgICAgICAgICAgICB2YXIgaHRtbCA9IEpTT04ucGFyc2UoZ2V0UmVzQ29kZSgpKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgaXRlbXMucHVzaCh7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogJycsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiAnMjU1JiZmbG9hdCcsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB1cmw6ICcnLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6ICd4NV93ZWJ2aWV3X3NpbmdsZSdcXFxcbiAgICAgICAgICAgICAgICAgICAgfSk7XFxcXG4gICAgICAgICAgICAgICAgICAgIHJlZnJlc2hYNVdlYlZpZXcoJycpO1xcXFxuICAgICAgICAgICAgICAgICAgICB2YXIgbXl1cmwgPSBNWV9VUkwubWF0Y2goLyhbXFxcXFxcXFxTXSo/OlxcXFxcXFxcL1xcXFxcXFxcL1tcXFxcXFxcXFNdKj8pXFxcXFxcXFwvLylbMV07XFxcXG4gICAgICAgICAgICAgICAgICAgIGlmICgvXFxcXFxcXFwvdm9kXFxcXFxcXFwvLy50ZXN0KHRkb21pbikpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoSlNPTi5wYXJzZShmZXRjaCgnaGlrZXI6Ly9wYWdlL3R2bW92bGlzdCcsIHt9KSkucnVsZSk7XFxcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBldmFsKEpTT04ucGFyc2UoZmV0Y2goJ2hpa2VyOi8vcGFnZS9hcHBtb3ZsaXN0Jywge30pKS5ydWxlKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgICAgICByZXMuZGF0YSA9IGl0ZW1zO1xcXFxuICAgICAgICAgICAgICAgICAgICBzZXRIb21lUmVzdWx0KHJlcyk7XFxcXG4gICAgICAgICAgICAgICAgfSwgdGRvbWluKSxcXFxcbiAgICAgICAgICAgICAgICAvL2NvbnRlbnQ6cmVtLFxcXFxuICAgICAgICAgICA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0LzIuMTQgKGRhcnQ6aW8pfSc7XFxcXG4gICAgICAgIH0gZWxzZSBpZiAoL2RpamlheGlhLy50ZXN0KG11cmwpKSB7XFxcXG4gICAgICAgICAgICB2YXIgbGluayA9ICdodHRwOi8vd3d3LmRpamlheGlhLmNvbS9hcGkucGhwL2FwcC92aWRlb19kZXRhaWw/aWQ9JyArIHVybDtcXFxcbiAgICAgICAgfVxcXFxuICAgICAgICBpdGVtcy5wdXNoKHtcXFxcbiAgICAgICAgICAgIHRpdGxlOiB0aXRsZSxcXFxcbiAgICAgICAgICAgIHBpY191cmw6IGltZyArICdAUmVmZXJlcj0nLFxcXFxuICAgICAgICAgICAgdXJsOiAkKGxpbmspLnJ1bGUoKCkgPT4ge1xcXFxuICAgICAgICAgICAgICAgIHZhciByZXMgPSB7fTtcXFxcbiAgICAgICAgICAgICAgICB2YXIgaXRlbXMgPSBbXTtcXFxcbiAgICAgICAgICAgICAgICBpdGVtcy5wdXNoKHtcXFxcbiAgICAgICAgICAgICAgICAgICAgdGl0bGU6ICcnLFxcXFxuICAgICAgICAgICAgICAgICAgICBkZXNjOiAnMjU1JiZmbG9hdCcsXFxcXG4gICAgICAgICAgICAgICAgICAgIHVybDogJycsXFxcXG4gICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiAneDVfd2Vidmlld19zaW5nbGUnXFxcXG4gICAgICAgICAgICAgICAgfSk7XFxcXG4gICAgICAgICAgICAgICAgcmVmcmVzaFg1V2ViVmlldygnJyk7XFxcXG4gICAgICAgICAgICAgICAgdmFyIGh0bWwgPSBKU09OLnBhcnNlKGdldFJlc0NvZGUoKSk7XFxcXG4gICAgICAgICAgICAgICAgdmFyIG15dXJsID0gTVlfVVJMLm1hdGNoKC8oW1xcXFxcXFxcU10qPzpcXFxcXFxcXC9cXFxcXFxcXC9bXFxcXFxcXFxTXSo/KVxcXFxcXFxcLy8pWzFdO1xcXFxuICAgICAgICAgICAgICAgIHRyeSB7XFxcXG4gICAgICAgICAgICAgICAgIC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vLnRlc3QocmVtZikpIHtcXFxcbiAgICAgICAgICAgIHZhciByZW12ID0gSlNPTi5wYXJzZShiYXNlNjREZWNvZGUocmVtZi5zcGxpdCgnQCcpWzJdKSkudmVyc2lvbjtcXFxcbiAgICAgICAgfSBlbHNlIGlmICgv77+laG9tZV9ydWxl77+lLy50ZXN0KHJlbWYpKSB7XFxcXG4gICAgICAgICAgICB2YXIgcmVtdiA9IEpTT04ucGFyc2UocmVtZi5zcGxpdCgn77+laG9tZV9ydWxl77+lJylbMV0pLnZlcnNpb247XFxcXG4gICAgICAgIH07XFxcXG4gICAgICAgIGlmICgv77+laG9tZV9ydWxlLy50ZXN0KHJlbWYpKSB7XFxcXG4gICAgICAgICAgICBsb2coJ+i/nOeoi+eJiOacrO+8micgKyByZW12KTtcXFxcbiAgICAgICAgICAgIGxvZygn5pys5Zyw54mI5pys77yaJyArIGxvY3Zlcik7XFxcXG4gICAgICAgICAgICBpZiAobG9jdmVyICE9IHJlbXYpIHtcXFxcbiAgICAgICAgICAgICAgICBwdXRWYXIoJ2FwcG52ZXInLCByZW1mKTtcXFxcbiAgICAgICAgICAgICAgICByZWZyZXNoUGFnZSgpO1xcXFxuICAgICAgICAgICAgICAgIHJldHVybiAndG9hc3Q6Ly/mnInmlrDniYjmnKzvvIzngrnlr7zlhaXmm7TmlrDlj6/mm7TmlrDop4TliJnjgIInO1xcXFxuICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICByZXR1cm4gJ3RvYXN0Oi8v5pqC5peg5paw54mI5pys77yMMjTlsI/ml7blhoXmo4DmtYvml6DmlYjjgIInXFxcXG4gICAgICAgICAgICB9O1xcXFxuICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgcmV0dXJuICd0b2FzdDovL+ajgOa1i+abtOaWsOWksei0pe+8jOWPr+iDveS6keerr+aKvemjjuS6huOAgidcXFxcbiAgICAgICAgfVxcXFxuICAgIH0sIGxvY3ZlciksXFxcXG4gICAgY29s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nKTtcXFxcbiAgICAgICAgfVxcXFxuICAgIH0gZWxzZSBpZiAoaHRtbC5kYXRhLnZvZF9pbmZvICYmIGh0bWwuZGF0YS52b2RfaW5mby52b2RfdXJsX3dpdGhfcGxheWVyKSB7XFxcXG4gICAgICAgIHZhciBjb250cyA9IGh0bWwuZGF0YS52b2RfaW5mby52b2RfdXJsX3dpdGhfcGxheWVyO1xcXFxuICAgICAgICBpZiAoY29udHMubGVuZ3RoIDwgMSkge1xcXFxuICAgICAgICAgICAgY29udHMgPSBodG1sLmRhdGEudm9kX2luZm8udm9kX3BsYXlfdXJsLnNwbGl0KCckJCQnKTtcXFxcbiAgICAgICAgfVxcXFxuICAgIH0gZWxzZSBpZiAoaHRtbC5kYXRhLmxlbmd0aCA9PSAxKSB7XFxcXG4gICAgICAgIHZhciBjb250cyA9IGh0bWwuZGF0YVswXS52b2RfcGxheV9saXN0O1xcXFxuICAgICAgICAvL2xvZyhjb250cyk7XFxcXG4gICAgICAgIGlmIChjb250cy5sZW5ndGggPCAxKSB7XFxcXG4gICAgICAgICAgICBjb250cyA9IGh0bWwuZGF0YVswXS52b2RfcGxheV91cmwuc3BsaXQoJyQkJCcpO1xcXFxuICAgICAgICB9XFxcXG4gICAgfSBlbHNlIHtcXFxcbiAgICAgICAgdmFyIGNvbnRzID0gaHRtbC5kYXRhLnZvZF9wbGF5X2xpc3Q7XFxcXG4gICAgICAgIGlmIChjb250cy5sZW5ndGggPCAxKSB7XFxcXG4gICAgICAgICAgICBjb250cyA9IGh0bWwuZGF0YS52b2RfcGxheV91cmwuc3BsaXQoJyQkJCcpO1xcXFxuICAgICAgICB9XFxcXG4gICAgfVxcXFxuXFxcXG4gICAgZm9yICh2YXIgaSA9IDA7IGkgPCBjb250cy5sZW5ndGg7IGkrKykge1xcXFxuICAgICAgICBpZiAoaHRtbC52aWRlb2xpc3QpIHtcXFxcbiAgICAgICAgICAgIHZhciBsaXN0ID0gaHRtbC52aWRlb2xpc3RbY29udHNbaV1dO1xc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Z6eXxoZHlhbmd0dnx0a3lzfHRlZ291eXMvLnRlc3QobGluaykpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIGhtdXJsID0gbGluayArICc/YWM9bGlzdCZ6bT0nICsga2V5ICsgJyZwYWdlPTEnO1xcXFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnP2FjPWxpc3Qmd2Q9JyArIGtleSArICcmcGFnZT0xJztcXFxcbiAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgIGlmICgvZGlqaWF4aWEvLnRlc3QobGluaykpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgbGluayA9ICdodHRwOi8vd3d3LmRpamlheGlhLmNvbS9hcGkucGhwL2FwcC8nXFxcXG4gICAgICAgICAgICAgICAgfTtcXFxcbiAgICAgICAgICAgICAgICBpZiAobGluay5pbmRleE9mKCdhcGkucGhwL2FwcC8nKSAhPSAtMSkge1xcXFxuICAgICAgICAgICAgICAgICAgICB2YXIgaG11cmwgPSBsaW5rICsgJ3NlYXJjaD9wZz0xJnRleHQ9JyArIGtleSArICcmdG9rZW49JztcXFxcbiAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKGxpbmsuaW5kZXhPZigneGdhcHAucGhwL3YxLycpICE9IC0xKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnc2VhcmNoP3BnPTEmdGV4dD0nICsga2V5O1xcXFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIGlmICgvaW9wZW55dW4vLnRlc3QobGluaykpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnL2xpc3Q/cGFnZT1meXBhZ2UmbGltaXQ9MTAmd2Q9JyArIGtleTtcXFxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBobXVybCA9IGxpbmsgKyAnP3BhZ2U9MSZsaW1pdD0xMCZ3ZD0nICsga2V5O1xcXFxuICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgLy9EYXRhLnB1c2goe3VybDogaG11cmwsb3B0aW9uczoge2hlYWRlcnM6IHtcXFxcXFxcIlVzZXItQWdlbnRcXFxcXFxcIjogXFxcXFxcXCJEYXJ0LzIuMTQgKGRhcnQ6aW8pXFxcXFxcXCJ9LHRpbWVvdXQ6IHRpbWVvdX19KTtcXFxcbiAgICAgICAgICAgIERhdGEucHVzaCh7XFxcXG4gICAgICAgICAgICAgICAgdXJsOiBobXVybCxcXFxcbiAgICAgICAgICAgICAgICBvcHRpb25zOiB7XFxcXG4gICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIFxcXFxcXFwiVXNlci1BZ2VudFxcXFxcXFwiOiBsaW5rLmluZGV4T2YoXFxcXFxcXCJtb2dhaV9hcGlcXFxcXFxcIikgIT0gLTEgPyBcXFxcXFxcIkRhcnQvMi4xNCAoZGFydDppbylcXFxcXFxcIiA6IFxcXFxcXFwib2todHRwLzQuMS4wXFxcXFxcXCJcXFxcbiAgICAgICAgICAgICAgICAgICAgfSxcXFxcbiAgICAgICAgICAgICAgICAgICAgdGltZW91dDogdGltZW91XFxcXG4gICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgfSk7XFxcXG4gICAgICAgICAgICBUaXQucHVzaCh7XFxcXG4gICAgICAgICAgICAgICAgdGl0OiBsaXN0W2pdLnRpdGxlLFxcXFxuICAgICAgICAgICAgICAgIGxpbms6IGxpbmssXFxcXG4gICAgICAgICAgICAgICAgdHlwbm06IGxpdGl0XFxcXG4gICAgICAgICAgIC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gdHJ5IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgaHRtbCA9IGh0bWwuc3Vic3RyaW5nKDAsIDIpID09ICdcXFxcXFxcXHJcXFxcXFxcXG4nID8gaHRtbC5yZXBsYWNlKCdcXFxcXFxcXHJcXFxcXFxcXG4nLCAnJykgOiBodG1sO1xcXFxuICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHt9XFxcXG4gICAgICAgICAgICAgICAgaWYgKC9idHdhZi8udGVzdChodG1sKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICBodG1sID0gZmV0Y2gocGFyYW0uaXQudXJsICsgJyZidHdhZicgKyBodG1sLm1hdGNoKC9idHdhZiguKj8pXFxcXFxcXFxcXFxcXFxcIi8pWzFdLCB7fSk7XFxcXG4gICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgIGlmIChodG1sID09IFxcXFxcXFwiXFxcXFxcXCIgfHwgaHRtbCA9PSBudWxsIHx8IGh0bWwuc3Vic3RyaW5nKDAsIDUpID09ICdlcnJvcicgfHwgIWh0bWwuZW5kc1dpdGgoJ30nKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICBkLnB1c2goe1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdGl0bGU6IHBhcmFtLnRpdC50aXQgKyAnICcgKyAn5pyq5pCc57Si5Yiw77yM54K55Ye76K6/6Zeu5Y6f572R6aG1JyxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogcGFyYW0uaXQudXJsICsgYEBsYXp5UnVsZT0uanM6aW5wdXQuc3BsaXQoJzsnKVswXWAsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiBcXFxcXFxcIlxcXFxcXFwiLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcGljX3VybDogXFxcXFxcXCJcXFxcXFxcIixcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiAndGV4dF9jZW50ZXJfMSdcXFxcbiAgICAgICAgICAgICAgICAgICAgfSk7XFxcXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChodG1sLmxlbmd0aCA8IDgwKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIGQucHVzaCh7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogcGFyYW0udGl0LnRpdCArICcgJyArICfov5Tlm57mlbDmja7kuI3lrozmlbTvvIzngrnlh7vorr/pl67ljp/nvZHpobUnLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiBwYXJhbS5pdC51cmwgKyBgQGxhenlSdWxlPS5qczppbnB1dC5zcGxpdCgnOycpWzBdYCxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGRlc2M6IFxcXFxcXFwiXFxcXFxcXCIsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBwaWNfdXJsOiBcXFxcXFxcIlxcXFxcXFwiLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6ICd0ZXh0X2NlbnRlcl8xJ1xcXFxuICAgICAgICAgICAgICAgICAgICB9KTtcXFxcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICBodG1sID0gSlNPTi5wYXJzZShodG1sKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgLy9sb2coaHRtbCk7XFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciB0eXBldCA9IHBhcmFtLnRpdC50eXBubTtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIHRkb21pbiA9IHBhcmFtLnRpdC5saW5rO1xcXFxuICAgICAgICAgICAgICAgICAgICBpZiAoaHRtbC5saXN0KSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgbGlzdCA9IGh0bWwubGlzdDtcXFxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChodG1sLmRhdGEubGlzdCkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGxpc3QgPSBodG1sLmRhdGEubGlzdDtcXFxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChodG1sLmRhdGEpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBsaXN0ID0gaHRtbC5kYXRhO1xcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGxpc3QgPSBbXTtcXFxcbiAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgICAgICBpZiAobGlzdC5sZW5ndGggPCAxKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBkLnB1c2goe1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiBwYXJhbS50aXQudGl0ICsgJyAnICsgJ+WIl+ihqOWwj+S6jjHvvIzml6Dms5XlsZXnpLrvvIzngrnlh7vorr/pl67ljp/nvZHpobUnLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogcGFyYW0uaXQudXJsICsgYEBsYXp5UnVsZT0uanM6aW5wdXQuc3BsaXQoJzsnKVswXWAsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZGVzYzogXFxcXFxcXCJcXFxcXFxcIixcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBwaWNfdXJsOiBcXFxcXFxcIlxcXFxcXFwiLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiAndGV4dF9jZW50ZXJfMSdcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBsaXN0Lmxlbmd0aDsgaSsrKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKC9cXFxcXFxcXC92b2RcXFxcXFxcXC8vLnRlc3QodGRvbWluKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgdGl0bGUgPSBsaXN0W2ldLnRpdGxlO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcGljID0gbGlzdFtpXS5waWM7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciB2aWQgPSBsaXN0W2ldLm5leHRsaW5rO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVtID0gbGlzdFtpXS5zdGF0ZTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAodGRvbWluLmluZGV4T2YoJ2FwaS5waHAvYXBwLycpICE9IC0xKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgdGl0bGUgPSBsaXN0W2ldLnZvZF9uYW1lO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHBpYyA9IGxpc3RbaV0udm9kX3BpYztcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICgvZmFudHVhbi8udGVzdCh0ZG9taW4pKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHZpZCA9ICdodHRwczovL2ZhbnR1YW4ud2tmaWxlLmNvbS9hcGkucGhwL2FwcC92aWRlb19kZXRhaWw/aWQ9JyArIGxpc3RbaV0udm9kX2lkICsgJyZ0b2tlbj0nO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgdmlkID0gdGRvbWluICsgJ3ZpZGVvX2RldGFpbD9pZD0nICsgbGlzdFtpXS52b2RfaWQgKyAnJnRva2VuPSc7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVtID0gbGlzdFtpXS52b2RfcmVtYXJrcztcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnR5cGUudHlwZV9kZXM7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAodGRvbWluLmluZGV4T2YoJ3hnYXBwLnBocC92MS8nKSAhPSAtMSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHRpdGxlID0gbGlzdFtpXS52b2RfbmFtZTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBwaWMgPSBsaXN0W2ldLnZvZF9waWM7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgdmlkID0gdGRvbWluICsgJ3ZpZGVvX2RldGFpbD9pZD0nICsgbGlzdFtpXS52b2RfaWQ7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVtID0gbGlzdFtpXS52b2RfcmVtYXJrcztcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnR5cGUudHlwZV9kZXM7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgdGl0bGUgPSBsaXN0W2ldLnZvZF9uYW1lO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHBpYyA9IGxpc3RbaV0udm9kX3BpYztcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICgvaW9wZW55dW4vLnRlc3QodGRvbWluKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciB2aWQgPSB0ZG9taW4gKyAnL2RldGFpbElEP3ZvZF9pZD0nICsgbGlzdFtpXS52b2RfaWQgKyAnJnRva2VuPSc7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciB2aWQgPSB0ZG9taW4gKyAnL2RldGFpbD9rZXk9JyArIGRhdGVTdHIgKyAnJnZvZF9pZD0nICsgbGlzdFtpXS52b2RfaWQgKyAnJnRva2VuPSc7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVtID0gbGlzdFtpXS52b2RfcmVtYXJrcztcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vdmFyIGNvbj1saXN0W2ldLnR5cGUudHlwZV9kZXM7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcblxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvL3ZhciBjb249bGlzdFtpXS5zdGF0ZTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvL2xvZyh2aWQpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGQucHVzaCh7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiBNWV9UWVBFID09IFxcXFxcXFwiaG9tZVxcXFxcXFwiID8gdGl0bGUucmVwbGFjZShrZXksICfigJzigJwnICsga2V5ICsgJ+KAneKAnScpICsgJ1xcXFxcXFxcbicgKyByZW0gOiB0aXRsZSArIHJlbSxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcGljX3VybDogcGljICsgJ0BSZWZlcmVyPScsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJCh0ZG9taW4uaW5kZXhPZihcXFxcXFxcIm1vZ2FpX2FwaVxcXFxcXFwiKSAhPSAtMSA/IHZpZCArICc7Z2V0O3V0Zi04O3tVc2VyLUFnZW50QERhcnQvMi4xNCAoZGFydDppbyl9JyA6IHZpZCArICc7Z2V0O3V0Zi04O3tVc2VyLUFnZW50QG9raHR0cC80LjEuMH0nKS5ydWxlKCh0ZG9taW4sdGt0LHBhdHQpID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciByZXMgPSB7fTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBpdGVtcyA9IFtdO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYodGt0IT0nJyl7c2V0UGFnZVRpdGxlKHRrdCsnLScrcGF0dCk7fVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGh0bWwgPSBKU09OLnBhcnNlKGdldFJlc0NvZGUoKSk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpdGVtcy5wdXNoKHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogJycsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGVzYzogJzI1NSYmZmxvYXQnLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJycsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6ICd4NV93ZWJ2aWV3X3NpbmdsZSdcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIG15dXJsID0gTVlfVVJMLm1hdGNoKC8oW1xcXFxcXFxcU10qPzpcXFxcXFxcXC9cXFxcXFxcXC9bXFxcXFxcXFxTXSo/KVxcXFxcXFxcLy8pWzFdO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKC9cXFxcXFxcXC92b2RcXFxcXFxcXC8vLnRlc3QodGRvbWluKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoSlNPTi5wYXJzZShmZXRjaCgnaGlrZXI6Ly9wYWdlL3R2bW92bGlzdCcsIHt9KSkucnVsZSk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGV2YWwoSlNPTi5wYXJzZShmZXRjaCgnaGlrZXI6Ly9wYWdlL2FwcG1vdmxpc3QnLCB7fSkpLnJ1bGUpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxcXFxuXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXMuZGF0YSA9IGl0ZW1zO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2V0SG9tZVJlc3VsdChyZXMpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LCB0ZG9taW4scGFyYW0udGl0LnRpdCx0aXRsZSksXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vY29udGVudDogcmVtLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiB0eXRpdCArICcgPT4gJyArIHBhcmFtLnRpdC50aXQsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnbW92aWVfMV92ZXJ0aWNhbF9waWMnXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9IC8vZm9yIGlcXFxcbiAgICAgICAgICAgICAgICAgICAgfSAvL2lmIGxpc3QubGVuZ3RoXFxcXG4gICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgIHJldHVybiBkO1xcXFxuICAgICAgICAgICAgfSxcXFxcbiAgICAgICAgICAgIHBhcmFtOiB7XFxcXG4gICAgICAgICAgICAgICAgaXQ6IGl0LFxcXFxuICAgICAgICAgICAgICAgIHRpdDogVGl0W2tdXFxcXG4gICAgICAgICAgICB9LFxcXFxuICAgICAgICAgICAgaWQ6IFxcXFxcXFwidGFza1xcXFxcXFwiXFxcXG4gICAgICAgIH0pXFxcXG4gICAgfVxcXFxuXFxcXG4gICAgYmF0Y2hFeGVjdXRlKHRhc2tzLCB7XFxcXG4gICAgICAgIGZ1bmM6IGZ1bmN0aW9uKHBhcmFtLCBpZCwgZXJyb3IsIHJlc3VsdCkge1xcXFxuICAgICAgICAgICAgLy9sb2coXFxcXFxcXCJsaXN0ZW5lcjogXFxcXFxcXCIgKyAocmVzdWx0IHx8IFtdKS5sZW5ndGgpXFxcXG4gICAgICAgICAgICBwYXJhbS5pID0gcGFyYW0uaSArIDE7XFxcXG4gICAgICAgICAgICBpZiAocmVzdWx0KSB7XFxcXG4gICAgICAgICAgICAgICAgZm9yIChsZXQgaXQgb2YgcmVzdWx0KSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHBhcmFtLmogPSBwYXJhbS5qICsgMTtcXFxcbiAgICAgICAgICAgICAgICAgICAgYWRkSXRlbUJlZm9yZShwYWdlaWQsIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiBpdC50aXRsZSxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGRlc2M6IGl0LmRlc2MsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB1cmw6IGl0LnVybCxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHBpY191cmw6IGl0LnBpY191cmwsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBjb2xfdHlwZTogaXQuY29sX3R5cGUsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBleHRyYToge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlkOiBcXFxcXFxcIl9fYXBwXFxcXFxcXCIgKyBNWV9QQUdFICsgXFxcXFxcXCJAXFxcXFxcXCIgKyBwYXJhbS5qXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgIH0pXFxcXG4gICAgICAgICAgICAgICAgfVxcXFxuXFxcXG4gICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICBpZiAocGFyYW0uaSA+PSBwYXJhbS5hbGwpIHtcXFxcbiAgICAgICAgICAgICAgICBkZWxldGVJdGVtKHBhZ2VpZClcXFxcbiAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgdXBkYXRlSXRlbSh7XFxcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOiBcXFxcXFxcIuato+WcqOWKoOi9veesrFxcXFxcXFwiICsgTVlfUEFHRSArIFxcXFxcXFwi6aG177yM6L+b5bqm77yaXFxcXFxcXCIgKyAocGFyYW0uaSArIDEpICsgXFxcXFxcXCIvXFxcXFxcXCIgKyBwYXJhbS5hbGwsXFxcXG4gICAgICAgICAgICAgICAgICAgIHVybDogXFxcXFxcXCJcXFxcXFxcIixcXFxcbiAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6IFxcXFxcXFwidGV4dF9jZW50ZXJfMVxcXFxcXFwiLFxcXFxuICAgICAgICAgICAgICAgICAgICBkZXNjOiBcXFxcXFxcIlxcXFxcXFwiLFxcXFxuICAgICAgICAgICAgICAgICAgICBwaWNfdXJsOiBcXFxcXFxcIlxcXFxcXFwiLFxcXFxuICAgICAgICAgICAgICAgICAgICBleHRyYToge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgaWQ6IHBhZ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g5Yiw5b2T5YmN6aG5XFxcXG4gICAgICAgIGlmIChpdGVtLnRpdGxlID09IOiusOW9lVtpXS50eXBlKSB7XFxcXG4gICAgICAgICAgICBpdGVtLmxpc3QgPSDlvZPliY3mnaHnm64uY29uY2F0KGl0ZW0ubGlzdC5maWx0ZXIoZCA9PiBkLnVybCAhPSDorrDlvZVbaV0udXJsKSk7XFxcXG4gICAgICAgICAgICByZXR1cm4gdHJ1ZVxcXFxuICAgICAgICB9XFxcXG4gICAgfSk7XFxcXG4gICAgaWYgKCFyZXMpIHtcXFxcbiAgICAgICAgLy/lpoLmnpzmsqHmib7nm7jlkIznsbvlnovmt7vliqDkuIDkuKrnsbvlnotcXFxcbiAgICAgICAg5paw6K6w5b2VLnB1c2goe1xcXFxuICAgICAgICAgICAgdGl0bGU6IOiusOW9lVtpXS50eXBlLFxcXFxuICAgICAgICAgICAgbGlzdDog5b2T5YmN5p2h55uuXFxcXG4gICAgICAgIH0pO1xcXFxuICAgIH1cXFxcbiAgICB9XFxcXG59XFxcXG52YXIgbmV3ZmlsZSA9IHt9O1xcXFxubmV3ZmlsZS5kYXRhID0g5paw6K6w5b2VO1xcXFxuLy9sb2cocmVtZmlsZSk7XFxcIn1dXCJ9IiwicGljVXJsIjoiaHR0cHM6Ly9waWMud3VqaW5wcC5jb20vdXBsb2FkL3ZvZC8yMDIyMDUwMi0xLzBjNmFiMWY4NDY4YTRiMjlhZTliZjVmZWVjMjQ2ZTg5LmpwZ0BSZWZlcmVyPSIsInRpdGxlIjoiTVjlvbHop4Yt57qi5Li55b+DIn0=
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement