Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 海阔视界规则分享,当前分享的是:小程序¥home_rule_v2¥base64://@橘子动漫🍊@eyJsYXN0X2NoYXB0ZXJfcnVsZSI6Ii5hbnRob2xvZ3ktbGlzdC1wbGF5JiZhLC0xJiZUZXh0LmpzOifmm7TmlrDoh7PvvJonK2lucHV0IiwidGl0bGUiOiLmqZjlrZDliqjmvKvwn42KIiwiYXV0aG9yIjoiIiwidXJsIjoiaGlrZXI6Ly9lbXB0eSMjaHR0cHM6Ly93d3cubWduYWNnLmNvbS8iLCJ2ZXJzaW9uIjowLCJjb2xfdHlwZSI6Im1vdmllXzMiLCJjbGFzc19uYW1lIjoiIiwidHlwZSI6InZpZGVvIiwiY2xhc3NfdXJsIjoiIiwiYXJlYV9uYW1lIjoiIiwiYXJlYV91cmwiOiIiLCJzb3J0X25hbWUiOiIiLCJ5ZWFyX25hbWUiOiIiLCJzb3J0X3VybCI6IiIsInllYXJfdXJsIjoiIiwiZmluZF9ydWxlIjoianM6XG52YXIgZCA9IFtdO1xuXG5NWV9VUkwgPSBNWV9VUkwucmVwbGFjZSgnaGlrZXI6Ly9lbXB0eSMjJywgJycpO1xudmFyIGh0bWwgPSBmZXRjaChNWV9VUkwpO1xuLypcbmNvbnN0IGhvc3QgPSAnaHR0cHM6Ly93d3cubWduYWNnLmNvbS8nO1xudmFyIGh0bWwgPSBmZXRjaChob3N0LCB7XG4gICAgaGVhZGVyczoge1xuICAgICAgICAnVXNlci1BZ2VudCc6IE1PQklMRV9VQVxuICAgIH1cbn0pOyovXG5cbi8v5qCH6aKYLOaPj+i/sCzlm77niYcs6ZO+5o6lXG52YXIg5qCH6aKYID0gJ2EmJnRpdGxlJztcbnZhciDmj4/ov7AgPSAnLnB1YmxpYy1wcnQmJlRleHQnO1xudmFyIOWbvueJhyA9ICdpbWd8fC5sYXp5JiZkYXRhLXNyY3x8ZGF0YS1vcmlnaW5hbCc7XG52YXIg6ZO+5o6lID0gJ2EmJmhy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lei0puWPtycpKSB7XG5kLnB1c2goe1xuICAgICAgICB0aXRsZTogJ+eUseS6jumDqOWIhuinhumikeS6jOe6p+mhtemdoumcgOimgeeZu+W9lemqjOivge+8jOivt+WFiOeZu+W9lemqjOivgScsXG4gICAgICAgIGRlc2M6ICfpqozor4HmiJDlip/ljbPlj6/mn6XnnIsnLFxuICAgICAgICB1cmw6ICQoJ2hpa2VyOi8vZW1wdHknKS5ydWxlKCgpID0+IHtcbiAgICAgICAgICAgIHZhciBpdGVtcyA9IFtdO1xuICAgICAgICAgICAgdmFyIGltZ2xpbiA9ICdodHRwczovL3d3dy5tZ25hY2cuY29tL3ZlcmlmeS9pbmRleC5odG1sP3I9JyArIE1hdGgucmFuZG9tKCk7XG4gICAgICAgICAgICAvL+WPluWbvueJh2Nvb2tpZVxuICAgICAgICAgICAgdmFyIGNvayA9IEpTT04ucGFyc2UoZmV0Y2hDb29raWUoaW1nbGluLCB7XG4gICAgICAgICAgICAgICAgaGVhZGVyczoge1xuICAgICAgICAgICAgICAgICAgICAnVXNlci1BZ2VudCc6IE1PQklMRV9VQVxuICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgbWV0aG9kOiAnR0VUJyxcbiAgICAgICAgICAgICAgICB3aXRoSGVhZGVyczogdHJ1ZVxuICAgICAgICAgICAgfSkpLmpvaW4oJzsnKTtcblxuICAgICAgICAgICAgLy/mmL7npLrpqozor4HnoIFcbiAgICAgICAgICAgIGl0ZW1zLnB1c2goe1xuICAgICAgICAgICAgICAgIHBpY191cmw6IGltZ2xpbiArICdAVXNlci1BZ2VudD0nICsgTU9CSUxFX1VBICsgJ0BDb29raWU9JyArIGNvayxcbiAgICAgICAgICAgICAgICB1cmw6ICQoJycpLmxhenlSdWxlKCgpID0+IHtcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJlZnJlc2hQYWdlKCk7XG4gICAgICAgICAgICAgICAgfSksXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6ICdwaWNfMV9mdWxsJ1xuICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAvL+i+k+WFpeahhlxuICAgICAgICAgICAgaXRlbXMucHVzaCh7XG4gICAgICAgICAgICAgICAgdGl0bGU6ICcnLFxuICAgICAgICAgICAgICAgIHVybDogXCIndG9hc3Q6Ly/kvaDovpPlhaXnmoTmmK8nICsgaW5wdXRcIixcbiAgICAgICAgICAgICAgICBkZXNjOiBcIui0puWPt1wiLFxuICAgICAgICAgICAgICAgIGV4dHJhOiB7XG4gICAgICAgICAgICAgICAgICAgIG9uQ2hhbmdlOiBcInB1dE15VmFyKCfotKblj7cnLGlucHV0KVwiLFxuICAgICAgICAgICAgICAgICAgICB0aXRsZVZpc2libGU6IGZhbHNlXG4gICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgICBjb2xfdHlwZTogJ2lucHV0J1xuICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICBpdGVtcy5wdXNoKHtcbiAgICAgICAgICAgICAgICB0aXRsZTogJycsXG4gICAgICAgICAgICAgICAgZGVzYzogXCLlr4bnoIFcIixcbiAgICAgICAgICAgICAgICB1cmw6IFwiJ3RvYXN0Oi8v5L2g6L6T5YWl55qE5pivJyArIGlucHV0XCIsXG4gICAgICAgICAgICAgICAgZXh0cmE6IHtcbiAgICAgICAgICAgICAgICAgICAgb25DaGFuZ2U6IFwicHV0TXlWYXIoJ+WvhueggScsaW5wdXQpXCIsXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlVmlzaWJsZTogZmFsc2VcbiAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnaW5wdXQnXG4gICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIGl0ZW1zLnB1c2goe1xuICAgICAgICAgICAgICAgIHRpdGxlOiAnJyxcbiAgICAgICAgICAgICAgICB1cmw6IFwiJ3RvYXN0Oi8v5L2g6L6T5YWl55qE5pivJyArIGlucHV0XCIsXG4gICAgICAgICAgICAgICAgZGVzYzogXCLpqozor4HnoIFcIixcbiAgICAgICAgICAgICAgICBleHRyYToge1xuICAgICAgICAgICAgICAgICAgICBvbkNoYW5nZTogXCJwdXRNeVZhcign5qmY5a2Q6aqM6K+B56CBJyxpbnB1dClcIixcbiAgICAgICAgICAgICAgICAgICAgdGl0bGVWaXNpYmxlOiBmYWxzZVxuICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6ICdpbnB1dCdcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgaXRlbXMucHVzaCh7XG4gICAgICAgICAgICAgICAgdGl0bGU6ICflj5HpgIEnLFxuICAgICAgICAgICAgICAgIHVybDogJChNWV9VUkwpLmxhenlSdWxlKChjb2spID0+IHtcbiAgICAgICAgICAgICAgICAgICAgdmFyIGNvZCA9IGdldE15VmFyKCfmqZjlrZDpqozor4HnoIEnKTtcbiAgICAgICAgICAgICAgICAgICAgdmFyIHVzZXJuYW1lID0gZ2V0TXlWYXIoJ+i0puWPtycpO1xuICAgICAgICAgICAgICAgICAgICB2YXIgcGFzc3dkID0gZ2V0TXlWYXIoJ+WvhueggScpO1xuICAgICAgICAgICAgICAgICAgICB2YXIgaHRtbCA9IEpTT04ucGFyc2UoZmV0Y2goJ2h0dHBzOi8vd3d3Lm1nbmFjZy5jb20vdXNlci9sb2dpbi5odG1sJywge1xuICAgICAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICdYLVJlcXVlc3RlZC1XaXRoJzogJ1hNTEh0dHBSZXF1ZXN0JyxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAnVXNlci1BZ2VudCc6IE1PQklMRV9VQSxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAnQ29va2llJzogY29rXG4gICAgICAgICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgICAgICAgICAgYm9keToge1xuICAgICAgICAgICAgICAgICAgICB1c2VyX25hbWU6IHVzZXJuYW1lLFxuICAgICAgICAgICAgICAgICAgICB1c2VyX3B3ZDogcGFzc3dkLFxuICAgICAgICAgICAgICAgICAgICB2ZXJpZnk6IGNvZFxuICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICdQT1NUJ1xuICAgICAgICAgICAgICAgICAgICB9KSk7XG4gICAgICAgICAgICAgICAgICAgIGlmIChodG1sLmNvZGUgPT0gMSkge1xuICAgICAgICAgICAgICAgICAgICAgICAgc2V0SXRlbSgnZmxjb29rJywgY29rKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2sodHJ1ZSk7XG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXCJ0b2FzdDovL+mqjOivgeaIkOWKn+OAglwiXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoaHRtbC5jb2RlID09IDEwMDMpICB7XG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXCJ0b2FzdDovL+mqjOivgeWksei0pSzor7fovpPlhaXmraPnoa7otKblj7flr4bnoIFcIlxuICAgICAgICAgICAgICAgICAgICB9ZWxzZSBpZiAoaHRtbC5jb2RlID09IDEwMDIpICB7XG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXCJ0b2FzdDovL+mqjOivgeWksei0pSzpqozor4HnoIHovpPlhaXmnInor69cIlxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfSwgY29rKSxcbiAgICAgICAgICAgICAgICBjb2xfdHlwZTogJ3RleHRfMidcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgc2V0UmVzdWx0KGl0ZW1zKTtcbiAgICAgICAgfSksXG4gICAgICAgIGNvbF90eXBlOiAndGV4dF9jZW50ZXJfMSdcbiAgICB9KTtcbn1jb25zdCBsaXN0ID0gcGRmYShodG1sLCAnYm9keSYmLnNlYXJjaC1ib3gnKTtcbmxpc3QuZm9yRWFjaChpdGVtID0+IHsgIFxudm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hdGEgPSBvYmouZGF0YTtcXG4gICAgICAgIHZhciBydW0gPSBnZXRNeVZhcigncm51bScpO1xcblxcbiAgICAgICAgdmFyIGkgPSBOdW1iZXIoZ2V0TXlWYXIoJ2Jhbm5lcmknLCAnMCcpKTtcXG4gICAgICAgIGlmIChydW0gIT0gJycpIHtcXG4gICAgICAgICAgICBpID0gTnVtYmVyKHJ1bSkgKyAxXFxuICAgICAgICAgICAgY2xlYXJNeVZhcigncm51bScpXFxuICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgIGkgPSBpICsgMTtcXG4gICAgICAgIH1cXG4gICAgICAgIC8vbG9nKGkpXFxuICAgICAgICAvL2xvZyhkYXRhLmxlbmd0aClcXG5cXG4gICAgICAgIGlmIChpID4gZGF0YS5sZW5ndGggLSAxKSB7XFxuICAgICAgICAgICAgaSA9IDBcXG4gICAgICAgIH1cXG4gICAgICAgIHZhciBpdGVtID0gZGF0YVtpXTtcXG4gICAgICAgIC8vbG9nKGl0ZW0pXFxuICAgICAgICB0cnkge1xcbiAgICAgICAgICAgIHVwZGF0ZUl0ZW0oaWQrJ2JhcicsIHtcXG4gICAgICAgICAgICAgICAgdGl0bGU6IGl0ZW0udGl0bGUsXFxuICAgICAgICAgICAgICAgIGltZzogaXRlbS5pbWcsXFxuICAgICAgICAgICAgICAgIHVybDogaXRlbS51cmwsXFxuICAgICAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgICAgICAvL25hbWU6IGl0ZW0udGl0bGUucmVwbGFjZSgvPFtePl0rPi9nLCAnJyksXFxuICAgICAgICAgICAgICAgICAgICAvL3NuYW1lOiBpdGVtLmV4dHJhLnNuYW1lLFxcbiAgICAgICAgICAgICAgICAgICAgLy9zdHlwZTogaXRlbS5leHRyYS5zdHlwZSxcXG4gICAgICAgICAgICAgICAgICAgIC8vc3VybDogaXRlbS51cmwsXFxuICAgICAgICAgICAgICAgICAgICAvL2ltZzppdGVtLmltZyxcXG4gICAgICAgICAgICA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d2Vlay1tb2R1bGUtJyArIChrPT0wPzA6aykgKyAnJiYucHVibGljLWxpc3QtYm94LDA6MTJcXFwiKTsnKTsvL+aYn+acn+WIl+ihqFxcbiAgICBpZiAod2tfbnVtID09IGspIHtcXG4gICAgICAgIGV2YWwoJ3drJytrKS5mb3JFYWNoKGl0ZW0gPT4ge1xcbiAgICAgICAgICAgIHZhciB1cmxsID0gTVlfSE9NRSArIHBkZmgoaXRlbSwgJ2EmJmhyZWYnKSArICcjaW1tZXJzaXZlVGhlbWUjJztcXG4gICAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgICAgICB0aXRsZTogcGRmaChpdGVtLCDmoIfpopgpLFxcbiAgICAgICAgICAgICAgICBkZXNjOiBwZGZoKGl0ZW0sIOaPj+i/sCksXFxuICAgICAgICAgICAgICAgIGltZzogcGQoaXRlbSwg5Zu+54mHKSArIFxcXCJAUmVmZXJlcj1cXFwiLFxcbiAgICAgICAgICAgICAgICB1cmw6ICdoaWtlcjovL3BhZ2UvZWojbm9IaXN0b3J5IyNpbW1lcnNpdmVUaGVtZSMnLFxcbiAgICAgICAgICAgICAgICBleHRyYToge1xcbiAgICAgICAgICAgICAgICAgICAgdXJsOiB1cmxsLFxcbiAgICAgICAgICAgICAgICAgICAgdGl0bGU6IHBkZmgoaXRlbSwg5qCH6aKYKSxcXG4gICAgICAgICAgICAgICAgICAgIGltZzogcGQoaXRlbSwg5Zu+54mHKSArIFxcXCJAUmVmZXJlcj1cXFwiLFxcbiAgICAgICAgICAgICAgICB9LFxcbiAgICAgICAgICAgICAgICBjb2xfdHlwZTogJ21vdmllXzMnLFxcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgfSlcXG4gICAgfSAgICBcXG59XFxuZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6IFxcXCJibGFua19ibG9ja1xcXCJcXG4gICAgICAgICAgICB9KTtcXG4gICAgICAgIH1cXG5cIn0se1wiY29sX3R5cGVcIjpcIm1vd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ICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgcmV0dXJuIFxcXCJ2aWRlbzovL1xcXCIgKyBpbnB1dFxcbiAgICAgICAgICAgIH1cXG4gICAgICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgICAgICByZXR1cm4gXFxcInZpZGVvOi8vXFxcIiArIGlucHV0XFxuICAgICAgICB9XFxuICAgIH0pLFxcbiAgICB1cGRhdGE6IGZ1bmN0aW9uKHJ1bGUpIHtcXG4gICAgICAgIHNldExhc3RDaGFwdGVyUnVsZSgnanM6JyArICQudG9TdHJpbmcoKHVybCxydWxlKSA9PiB7XFxuICAgICAgICAgICAgdmFyIGh0bWw9ZmV0Y2godXJsKTtcXG4gICAgICAgICAgICBzZXRSZXN1bHQoZXZhbChydWxlKSlcXG4gICAgICAgIH0sTVlfVVJMLCBydWxlKSlcXG4gICAgfSxcXG4gICAgY2xvc2U6IGZ1bmN0aW9uKGxpc3QsIHNvcnRzKSB7XFxuICAgICAgICBhZGRMaXN0ZW5lcignb25DbG9zZScsICQudG9TdHJpbmcoKGxpc3QsIHNvcnRzKSA9PiB7XFxuICAgICAgICAgICAgbGlzdC5tYXAoeCA9PiB7XFxuICAgICAgICAgICAgICAgIGNsZWFyTXlWYXIoJ2VyXycgKyB4ICsgJ2ZvbGQnKTtcXG4gICAgICAgICAgICAgICAgY2xlYXJNeVZhcignZXJfJyt4KTtcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIGZvciAobGV0IGkgPSAwOyBpIDwgc29ydHM7IGkrKykge1xcbiAgICAgICAgICAgICAgICBjbGVhck15VmFyKCdwbGF5bGlzdF8nICsgaSk7XFxuICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIGNsZWFyTXlWYXIoJ2VyX3BsYXlsaXN0cycpO1xcbiAgICAgICAgfSwgbGlzdCwgc29ydHMpKVxcbiAgICB9LFxcbiAgICBkYXRhQ29udmVydDogZnVuY3Rpb24oZGF0YSkge1xcbiAgICAgICAgdm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FxuICAgICAgICBudW0gPSB0eXBlb2YobnVtKSA9PSAndW5kZWZpbmVkJyA/IDkwIDogbnVtXFxuICAgICAgICBkZXNjID0gZGVzYy5zdGFydHNXaXRoKCfjgIDjgIAnKSA/IGRlc2MgOiAn44CA44CAJyArIGRlc2M7XFxuICAgICAgICBkZXNjID0gZGVzYy5yZXBsYWNlKC8nL2csIFxcXCImIzM5O1xcXCIpXFxuXFxuICAgICAgICBmdW5jdGlvbiBzdWJzdHIoc3RyLCBtYXhMZW5ndGgpIHtcXG4gICAgICAgICAgICBsZXQgbGVuID0gMDtcXG4gICAgICAgICAgICBmb3IgKGxldCBpID0gMDsgaSA8IHN0ci5sZW5ndGg7IGkrKykge1xcbiAgICAgICAgICAgICAgICBpZiAoc3RyLmNoYXJDb2RlQXQoaSkgPiAyNTUpIHtcXG4gICAgICAgICAgICAgICAgICAgIGxlbiArPSAyO1xcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgbGVuKys7XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgaWYgKGxlbiA+IG1heExlbmd0aCkge1xcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHN0ci5zbGljZSgwLCBpKSArICcuLi4nO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIHJldHVybiBzdHI7XFxuICAgICAgICB9XFxuICAgICAgICBsZXQgc2Rlc2MgPSBzdWJzdHIoZGVzYywgbnVtKTtcXG4gICAgICAgIHZhciBsYXp5ID0gJChgI25vTG9hZGluZyNgKS5sYXp5UnVsZSgoZGMsIHNkYywgbSkgPT4ge1xcbiAgICAgICAgICAgIHZhciBzaG93ID0gc3RvcmFnZTAuZ2V0SXRlbShtLCAnMCcpO1xcbiAgICAgICAgICAgIHZhciB0aXRsZSA9IGZpbmRJdGVtKCdkZXNjJykudGl0bGU7XFxuICAgICAgICAgICAgdmFyIHJlID0gLyg8XFxcXC9zbWFsbD48YnI+Lio/PikuKy9nO1xcbiAgICAgICAgICAgIHZhciBleHAgPSAn5bGV5byAOic7XFxuICAgICAgICAgICAgdmFyIHJldCA9ICfmlLbotbc6JztcXG4gICAgICAgICAgICBpZiAoc2hvdyA9PSAnMScpIHtcXG4gICAgICAgICAgICAgICAgdXBkYXRlSXRlbSgnZGVzYycsIHtcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOiB0aXRsZVxcbiAgICAgICAgICAgICAgICAgICAgICAgIC5yZXBsYWNlKHJldCwgZXhwKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIC5yZXBsYWNlKHJlLCAnJDEnICsgc2RjICsgJzwvc21hbGw+JylcXG4gICAgICAgICAgICAgICAgICAgICAgICAucmVwbGFjZSgvKDxcXFxcL3NtYWxsPjxicj48Zm9udCBjb2xvcj1cXFwiKS4qPyhcXFwiPikvLCAnJDEjOEEyQkUyJDInKS8v5pS26LW36aKc6ImyXFxuXFxuICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgIHN0b3JhZ2UwLnNldEl0ZW0obSwgJzAnKTtcXG4gICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICB1cGRhdGVJdGVtKCdkZXNjJywge1xcbiAgICAgICAgICAgICAgICAgICAgdGl0bGU6IHRpdGxlXFxuICAgICAgICAgICAgICAgICAgICAgICAgLnJlcGxhY2UoZXhwLCByZXQpXFxuICAgICAgICAgICAgICAgICAgICAgICAgLnJlcGxhY2UocmUsICckMScgKyBkYyArICc8L3NtYWxsPicpXFxuICAgICAgICAgICAgICAgICAgICAgICAgLnJlcGxhY2UoLyg8XFxcXC9zbWFsbD48YnI+PGZvbnQgY29sb3I9XFxcIikuKj8oXFxcIj4pLywgJyQxIzAwODAwMCQyJykvL+WxleW8gOminOiJslxcbiAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICBzdG9yYWdlMC5zZXRJdGVtKG0sICcxJyk7XFxuICAgICAg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iAgICAgICAgICAgIGlmICgvKOWvvOa8lHzkuLvmvJR857G75Z6LKe+8mi8udGVzdChzdHIpKSB7XFxuICAgICAgICAgICAgICAgIHN0ciA9IHN0ci5zcGxpdCgnLycpLm1hcCgodmFsLCBpbmRleCkgPT4gKGluZGV4ID09PSAwID8gJycgOiAnJykgKyB2YWwpLnNsaWNlKDAsIDUpLmpvaW4oJyAnKS5yZXBsYWNlKC8gJC8sICcnKTtcXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgcmV0dXJuIHN0clxcbiAgICAgICAgfSlcXG4gICAgfSxcXG4gICAgc2V0Q29udGVudDogZnVuY3Rpb24ob2JqKSB7XFxuICAgICAgICB2YXIgY29udGVudHMgPSBvYmoubWFpbjtcXG4gICAgICAgIHZhciBzb3J0T3JkZXIgPSBvYmouc29ydDtcXG4gICAgICAgIHZhciBpbWcgPSBvYmouaW1nO1xcbiAgICAgICAgdmFyIHRleHRzID0gY29udGVudHMubWFwKHggPT4gcGRmaCh4LCAnVGV4dCcpKTtcXG4gICAgICAgIHZhciBhcnJheSA9IHRleHRzLnNvcnQoKGEsIGIpID0+IHtcXG4gICAgICAgICAgICBjb25zdCBpbmRleEEgPSBzb3J0T3JkZXIuaW5kZXhPZihhLnN1YnN0cigwLCAyKSk7XFxuICAgICAgICAgICAgY29uc3QgaW5kZXhCID0gc29ydE9yZGVyLmluZGV4T2YoYi5zdWJzdHIoMCwgMikpO1xcbiAgICAgICAgICAgIHJldHVybiBpbmRleEEgLSBpbmRleEI7XFxuICAgICAgICB9KVxcbiAgICAgICAgdmFyIHJlZ2V4ID0gbmV3IFJlZ0V4cCgnKCcgKyBzb3J0T3JkZXIuam9pbignfCcpICsgJyknKTtcXG4gICAgICAgIGFycmF5ID0gYXJyYXkuZmlsdGVyKGZ1bmN0aW9uKGl0ZW0pIHtcXG4gICAgICAgICAgICByZXR1cm4gcmVnZXgudGVzdChpdGVtKTtcXG4gICAgICAgIH0pO1xcbiAgICAgICAgYXJyYXkgPSB0aGlzLnN0ckNvbnZlcnQoYXJyYXkpXFxuICAgICAgICB2YXIgdGl0bGVzID0gW107XFxuICAgICAgICB2YXIgZGVzY3MgPSBbXTtcXG4gICAgICAgIHN3aXRjaCAoYXJyYXkubGVuZ3RoKSB7XFxuICAgICAgICAgICAgY2FzZSA0OlxcbiAgICAgICAgICAgIGNhc2UgNTpcXG4gICAgICAgICAgICAgICAgdGl0bGVzID0gYXJyYXkuc2xpY2UoMCwgMik7XFxuICAgICAgICAgICAgICAgIGRlc2NzID0gYXJyYXkuc2xpY2UoMik7XFxuICAgICAgICAgICAgICAgIGJyZWFrO1xcbiAgICAgICAgICAgIGNhc2UgNjpcXG4gICAgICAgICAgICAgICAgdGl0bGVzID0gYXJyYXkuc2xpY2UoMCwgMyk7XFxuICAgICAgICAgICAgICAgIGRlc2NzID0gYXJyYXkuc2xpY2UoMyk7XFxuICAgICAgICAgICAgICAgIGJyZWFrO1xcbiAgICAgICAgfVxcbiAgICAgICAgc3RvcmFnZTAucHV0TXlWYXIoJ2VyX2luZm8nLHtcXG4gICAgICAgICAgZGVzYzpkZXNjcy5qb2luKCdcXFxcbicpLFxcbiAgICAgICAgICBpbWc6aW1nLFxcbiAgICAgICAgfSlcXG4gICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgLy90aXRsZTogdGl0bGVzWzBdICsgJ1xcXFxuJyArIHRoaXMuc21hbGwodGl0bGVzLnNsaWNlKDEsIDMpLmpvaW4oJ1xcXFxuJykpLFxcbiAgICAgdGl0bGU6ICB0aGlzLnNtYWxsKHRpdGxlc1swXSArICdcXFxcbicgKyB0aXRsZXMuc2xpY2UoMSwgMykuam9pbignXFxcXG4nKSwncmVkJyksXFxuICAgICAgICAgICBkZXNjOiB0aGlzLnNtYWxsKGRlc2NzLmpvaW4oJ1xcXFxuJyksJyNGRjdGMDAnKSxcXG4gICAgIC8vZGVzYzogdGhpcy5zbWFsbChwZGZoKGh0bWwsICcuY29udGV4dCYmLndpZGdldCYmVGV4dCcpLCcjRkY3RjAwJyksXFxuICAgICAgICAgICAgcGljX3VybDogaW1nICsgJ0BSZWZlcmVyPScsXFxuICAgICAgICAgICAgdXJsOiBNWV9VUkwsXFxuICAgICAgICAgICAgY29sX3R5cGU6ICdtb3ZpZV8xX3ZlcnRpY2FsX3BpY19ibHVyJyxcXG4gICAgICAgIH0pXFxuICAgICAgICBpZiAob2JqLmRlc2MgIT0gdW5kZWZpbmVkKSB7XFxuICAgICAgICAgICAgdGhpcy5zZXREZXNjKG9iai5kZXNjKTtcXG4gICAgICAgIH1cXG4gICAgfSxcXG4gICAgc2V0Q3VzdG9tOiBmdW5jdGlvbihvYmosIGltZykge1xcbiAgICAgICAgdmFyIGFycmF5ID0gW107XFxuICAgICAgICBpZiAob2JqLmNvbnN0cnVjdG9yID09IEFycmF5KSB7XFxuICAgICAgICAgICAgYXJyYXkgPSBvYmo7XFxuICAgICAgICB9XFxuICAgICAgICBhcnJheSA9IHRoaXMuc3RyQ29udmVydChhcnJheSk7XFxuICAgICAgICB2YXIgdGl0bGVzID0gW107XFxuICAgICAgICB2YXIgZGVzY3MgPSBbXTtcXG4gICAgICAgIHN3aXRjaCAoYXJyYXkubGVuZ3RoKSB7XFxuICAgICAgICAgICAgY2FzZSA0OlxcbiAgICAgICAgICAgIGNhc2UgNTpcXG4gICAgICAgICAgICAgICAgdGl0bGVzID0gYXJyYXkuc2xpY2UoMCwgMik7XFxuICAgICAgICAgICAgICAgIGRlc2NzID0gYXJyYXkuc2xpY2UoMik7XFxuICAgICAgICAgICAgICAgIGJyZWFrO1xcbiAgICAgICAgICAgIGNhc2UgNjpcXG4gICAgICAgICAgICAgICAgdGl0bGVzID0gYXJyYXkuc2xpY2UoMCwgMyk7XFxuICAgICAgICAgICAgICAgIGRlc2NzID0gYXJyYXkuc2xpY2UoMyk7XFxuICAgICAgICAgICAgICAgIGJyZWFrO1xcbiAgICAgICAgfVxcbiAgICAgICAgc3RvcmFnZTAucHV0TXlWYXIoJ2VyX2luZm8nLHtcXG4gICAgICAgICAgZGVzYzpkZXNjcy5qb2luKCdcXFxcbicpLFxcbiAgICAgICAgICBpbWc6aW1nLFxcbiAgICAgICAgfSlcXG4gICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgdGl0bGU6IHRpdGxlc1swXSArICdcXFxcbicgKyB0aGlzLnNtYWxsKHRpdGxlcy5zbGljZSgxLCAzKS5qb2luKCdcXFxcbicpKSxcXG4gICAgICAgICAgICBkZXNjOiB0aGlzLnNtYWxsKGRlc2NzLmpvaW4oJ1xcXFxuJykpLFxcbiAgICAgICAgICAgIHBpY191cmw6IGltZyArICdAUmVmZXJlcj0nLFxcbiAgICAgICAgICAgIHVybDogTVlfVVJMLFxcbiAgICAgICAgICAgIGNvbF90eXBlOiAnbW92aWVfMV92ZXJ0aWNhbF9waWNfYmx1cicsXFxuICAgICAgICB9KVxcbiAgICB9LFxcblxcblxcbi8v57q/6LevXFxuICAgIGlzQ29sb3I6ZnVuY3Rpb24odGV4dCkge1xcbiAgICAgY29uc3QgcmVnZXggPSAvXiMoWzAtOUEtRmEtZl17M318WzAtOUEtRmEtZl17Nn0pJHxeKFthLXpdKykkL2k7XFxuICAgICByZXR1cm4gcmVnZXgudGVzdCh0ZXh0KTtcXG4gICAgfSxcXG4gICAgZ2V0UHJlc2V0OmZ1bmN0aW9uKGN1c3RvbSl7XFxuICAgICAgaWYodHlwZW9mIGN1c3RvbWRhdGE9PSdvYmplY3QnJiYhY3VzdG9tKXtcXG4gICAgICAgIGN1c3RvbT1jdXN0b21kYXRhO1xcbiAgICAgIH1lbHNle1xcbiAgICAgICAgY3VzdG9tPWN1c3RvbT9jdXN0b206e31cXG4gICAgICB9XFxuICAgICAgY3VzdG9tLuato+W6j+minOiJsj0oY3VzdG9tLuato+W6j+minOiJsiYmdGhpcy5pc0NvbG9yKGN1c3RvbS7mraPluo/popzoibIpKT9jdXN0b20u5q2j5bqP6aKc6ImyOicjMUFBRDE5JztcXG4gICAgICBjdXN0b20u6YCG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AgICAgICAgICAgICB2YXIgcGxpc3QgPSBzdG9yYWdlMC5nZXRNeVZhcignZXJfcGxheWxpc3RzJywgJ3t9Jyk7XFxuICAgICAgICAgICAgICAgICAgXFxuICAgICAgICAgICAgICAgICAgdmFyIGNvbCA9IHBsaXN0W3Noc29ydF0uY29sX3R5cGU7XFxuICAgICAgICAgICAgICAgICAgdmFyIGNscyA9IHBsaXN0W3Noc29ydF0uY2xzO1xcbiAgICAgICAgICAgICAgICAgIHZhciBwaWM9cGxpc3Rbc2hzb3J0XS5waWM7XFxuICAgICAgICAgICAgICAgICAgdXBkYXRlSXRlbShidG4uZXh0cmEuaWQsIHtcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOiBidG4udGl0bGUucmVwbGFjZShmb2xkc1swXSwgZm9sZHNbMV0pLFxcbiAgICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgICAgXFxuICAgICAgICAgICAgICAgICAgcHV0TXlWYXIodmFyaSsnZm9sZCcsJzEnKTtcXG4gICAgICAgICAgICAgIC8vcmV0dXJuICd0b2FzdDovL+WxleW8gOaJjeiDveaTjeS9nCc7XFxuICAgICAgICAgICAgICAgICB9ZWxzZXtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBwbGlzdCA9IHN0b3JhZ2UwLmdldE15VmFyKCdlcl9wbGF5bGlzdHMnLCAne30nKTtcXG4gICAgICAgICAgICAgICAgICAgIFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIGNvbCA9IHBsaXN0W3Noc29ydF0uY29sX3R5cGU7XFxuICAgICAgICAgICAgICAgICAgICB2YXIgY2xzID0gcGxpc3Rbc2hzb3J0XS5jbHM7XFxuICAgICAgICAgICAgICAgICAgICB2YXIgcGljPXBsaXN0W3Noc29ydF0ucGljO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIHB1dE15VmFyKHZhcmksIGkpO1xcblxcbiAgICAgICAgICAgICAgICB2YXIgeGxpc3Q9bGlzdHNbaV07XFxuICAgICAgICAgICAgICAgIGlmKCQuZnVuYyE9dW5kZWZpbmVkJiYkLmZ1bmMuY29uc3RydWN0b3I9PUZ1bmN0aW9uKXtcXG4gICAgICAgICAgICAgICAgICAgIHhsaXN0PSQuZnVuYyhpKTtcXG4gICAgICAgICAgICAgICAgc3RvcmFnZTAucHV0TXlWYXIoc2hzb3J0ICsgJ19saXN0JywgeGxpc3QpO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIHZhciBwbGF5cyA9IHhsaXN0Lm1hcCh4ID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdGl0bGU6IHgudGl0bGUsXFxuICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiB4LnVybCxcXG4gICAgICAgICAgICAgICAgICAgICAgICBjb2xfdHlwZTogY29sLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHBpYzpwaWMsXFxuICAgICAgICAgICAgICAgICAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaWQ6IHgudXJsLnJlcGxhY2UoL0BsYXp5UnVsZVtcXFxcc1xcXFxTXSsvZywgJycpLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBjbHM6IGNscyxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgIGlmIChnZXRNeVZhcihzaHNvcnQgKyAnX3NvcnQnKSA9PSAnMScpIHtcXG4gICAgICAgICAgICAgICAgICAgIHBsYXlzLnJldmVyc2UoKTtcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB2YXIgcGNmZz1zdG9yYWdlMC5nZXRNeVZhcihzaHNvcnQrJ19wdXNoY2ZnJywne30nKTtcXG4gICAgICAgICAgICAgICAgaWYocGNmZ1sn5Y2V5o6oJ10pe1xcbiAgICAgICAgICAgICAgICAgIHVwZGF0ZUl0ZW0oc2hzb3J0KydfcHVzaCcse1xcbiAgICAgICAgICAgICAgICAgICAgdGl0bGU6cGNmZ1snb2JqJ11bJ+WNleaOqCddWzBdXFxuICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgICBwY2ZnWyfljZXmjqgnXT1mYWxzZTtcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICBpZihwY2ZnWyfpgInmjqgnXSl7XFxuICAgICAgICAgICAgICAgICAgdXBkYXRlSXRlbShzaHNvcnQrJ19wdXNocycse1xcbiAgICAgICAgICAgICAgICAgICAgdGl0bGU6cGNmZ1snb2JqJ11bJ+mAieaOqCddWzBdXFxuICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgICBwY2ZnWyfpgInmjqgnXT1mYWxzZTtcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICBzdG9yYWdlMC5wdXRNeVZhcihzaHNvcnQrJ19wdXNoY2ZnJyxwY2ZnKTtcXG4gICAgICAgICAgICAgICAgZGVsZXRlSXRlbUJ5Q2xzKHNoc29ydCk7XFxuICAgICAgICAgICAgICAgIGFkZEl0ZW1BZnRlcihzaHNvcnQgKyAnX2xpbmUnLCBwbGF5cyk7XFxuXFxuICAgICAgICAgICAgICAgIHZhciB0YWJ4ID0gZmluZEl0ZW1zQnlDbHMoc2hzb3J0ICsgJ190YWInKTtcXG4gICAgICAgICAgICAgICAgdGFieC5mb3JFYWNoKCh4LCBpaSkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIHRpdGxlID0geC50aXRsZTtcXG4gICAgICAgICAgICAgICAgICAgIGlmIChpID09IGlpKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdXBkYXRlSXRlbSh4LmV4dHJhLmlkLCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiB0aXRsZS5yZXBsYWNlKC8jKFxcXFx3Kyk/L2csIGxpbmVjKSxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB1cGRhdGVJdGVtKHguZXh0cmEuaWQsIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGl0bGU6IHRpdGxlLnJlcGxhY2UoLyMoXFxcXHcrKT8vZywgJyMnKSxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICByZXR1cm4gJ3RvYXN0Oi8v5YiH5o2i5oiQ5Yqf77yBJztcXG4gICAgICAgICAgICB9LCB2YXJpLCBzaHNvcnQsIGksY3VzdG9tLue6v+i3r+mAieS4rSlcXG4gICAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgICAgICB0aXRsZTogJ+KAnOKAnOKAneKAnScgKyAoZ2V0TXlWYXIodmFyaSwgJzAnKSA9PSBpID8gdGFic1tpXS5mb250Y29sb3IoY3VzdG9tLue6v+i3r+mAieS4rSkgOiB0YWJzW2ldLmZvbnRjb2xvcignIycpKSxcXG4gICAgICAgICAgICAgICAgdXJsOiB1cmwsXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnc2Nyb2xsX2J1dHRvbicsXFxuICAgICAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgICAgICBjbHM6IHNoc29ydCArICdfdGFiJyxcXG4gICAgICAgICAgICAgICAgICAgIGlkOiBzaHNvcnQgKyAnX3RhYl8nICsgaSxcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICB9XFxuICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgIGNvbF90eXBlOidibGFua19ibG9jaycsIC8vJ2JsYW5rX2Jsb2NrJyxcXG4gICAgICAgICAgICBleHRyYToge1xcbiAgICAgICAgICAgICAgICBpZDogc2hzb3J0ICsgJ19saW5lJyxcXG4gICAgICAgICAgICB9XFxuICAgICAgICB9KVxcbiAgICB9LFxcbiAgICBwdXNoVGFiOmZ1bmN0aW9uKHZhcmksc2hzb3J0KXtcXG4gICAgICBhZGRMaXN0ZW5lcignb25SZWZyZXNoJywgJC50b1N0cmluZygoc2hzb3J0KSA9PiB7XFxuICAgICAgICBjbGVhck15VmFyKHNoc29ydCsnX3B1c2hjZmcnKTtcXG4gICAgICAgIGNsZWFyTXlWYXIoc2hzb3J0KydfZHVvc2VsZWN0Jyk7XFxuICAgICAgICB9LCBzaHNvcnQpKVxcbiAgICAgICB2YXIgcG9iaj17XFxuICAgICAgICfljZXmjqgnOlsn4qa/5Y2V5o6oJywnPGI+4qa/5Y2V5o6oPC9iPicuZm9udGNvbG9yKCcjMDBGQTlBJyldLFxcbiAgICAgICAn6YCJ5o6oJzpbJ+KYkemAieaOqCcsJzxiPuKYkemAieaOqDwvYj4nLmZvbnRjb2xvcignIzQ2ODJCNCcpXSxcXG4gICAgICB9XFxuICAgICAgXFxuICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgdGl0bGU6J+KMmCcsXFxuICAgICAgICAgIGNvbF90eXBlOidzY3JvbGxfYnV0dG9uJyxcXG4gICAgICAgICAgdXJsOidoaWtlcjovL2VtcHR5JyxcXG4gICAgICAgICAgZXh0cmE6e1xcbiAgICAgICAgICAgIGNsczpzaHNvcnQrJ19wdXNodGFiJyxcXG4gICAgICAgICAgfVxcbiAgICAgICAgfSx7XFxuICAgICAgICAgIHRpdGxlOnBvYmpbJ+WNleaOqCddWzBdLFxcbiAgICAgICAgICBjb2xfdHlwZTonc2Nyb2xsX2J1dHRvbicsXFxuICAgICAgICAgIHVybDokKCcjbm9Mb2FkaW5nIycpLmxhenlSdWxlKChzaHNvcnQscG9iaix2YXJpKT0+e1xcbiAgICAgICAgICBpZihnZXRNeVZhcih2YXJpKydmb2xkJywnMScpPT0nMCcpe1xcbiAgICAgICAgICAgIHJldHVybiAndG9hc3Q6Ly/lsZXlvIDmiY3og73mk43kvZwnO1xcbiAgICAgICAgICB9XFxuICAgICAgICAgICAgXFxuICAgICAgICAgIHZhciB0aXRsZXM9cG9ialsn5Y2V5o6oJ107XFxuICAgICAgICAgIHZhciBwY2ZnPXN0b3JhZ2UwLmdldE15VmFyKHNoc29ydCsnX3B1c2hjZmcnLCd7fScpO1xcbiAgICAgICAgICBwY2ZnWydvYmonXT1wb2JqO1xcbiAgICAgICAgICB2YXIg5Y2V5o6oPXBjZmdbJ+WNleaOqCddP3BjZmdbJ+WNleaOqCddOmZhbHNlO1xcbiAgICAgICAgICBcXG4gICAgICAgICAgaWYo5Y2V5o6oKXtcXG4gICAgICAgICAgICB1cGRhdGVJdGVtKHNoc29ydCsnX3B1c2gnLHtcXG4gICAgICAgICAgICAgIHRpdGxlOnRpdGxlc1swXSxcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIHBjZmdbJ+WNleaOqCddPWZhbHNlO1xcbiAgICAgICAgICAgIHBjZmdbJ3BsYXlsaXN0J10ubWFwKCh4KT0+e1xcbiAgICAgICAgICAgICAgIHVwZGF0ZUl0ZW0oeC5leHRyYS5pZCx7XFxuICAgICAgICAgICAgICAgICB1cmw6eC51cmwsXFxuICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgICB9ZWxzZXtcXG4gICAgICAgICAgICB1cGRhdGVJdGVtKHNoc29ydCsnX3B1c2gnLHtcXG4gICAgICAgICAgICAgIHRpdGxlOifigJzigJzigJ3igJ0nK3RpdGxlc1sxXSxcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIHVwZGF0ZUl0ZW0oc2hzb3J0KydfcHVzaHMnLHtcXG4gICAgICAgICAgICAgIHRpdGxlOnBvYmpbJ+mAieaOqCddWzBdLFxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgcGNmZ1sn5Y2V5o6oJ109dHJ1ZTtcXG4gICAgICAgICAgICBwY2ZnWyfpgInmjqgnXT1mYWxzZTtcXG4gICAgICAgICAgICB2YXIgcGxheWxpc3Q9ZmluZEl0ZW1zQnlDbHMoc2hzb3J0KTtcXG4gICAgICAgICAgICBwY2ZnWydwbGF5bGlzdCddPXBsYXlsaXN0O1xcbiAgICAgICAgICAgIGZpbmRJdGVtc0J5Q2xzKHNoc29ydCkubWFwKHg9PntcXG4gICAgICAgICAgICAgIHZhciBkcHVzaD17XFxuICAgICAgICAgICAgICAgIG5hbWU6Z2V0UGFnZVRpdGxlKCksXFxuICAgICAgICAgICAgICAgIHVybDp4LnRpdGxlKyckJyt4LmV4dHJhLmlkXFxuICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICB1cGRhdGVJdGVtKHguZXh0cmEuaWQse1xcbiAgICAgICAgICAgICAgICB1cmw6JCgnJykubGF6eVJ1bGUoKGRwdXNoKT0+e1xcbiAgICAgICAgICAgICAgICAgcmV0dXJuICdoaWtlcjovL3BhZ2UvcHVzaD9ydWxlPVhZUeaOqOmAgSZwdXNodXJsPScgKyBlbmNvZGVVUklDb21wb25lbnQoSlNPTi5zdHJpbmdpZnkoZHB1c2gpKTtcXG4gICAgICAgICAgICAgICAgfSxkcHVzaClcXG4gICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgfSlcXG4gICAgICAgICAgfVxcbiAgICAgICAgICBzdG9yYWdlMC5wdXRNeVZhcihzaHNvcnQrJ19wdXNoY2ZnJyxwY2ZnKTtcXG4gICAgICAgICAgcmV0dXJuICd0b2FzdDovLycrKOWNleaOqD8n5Y2V5o6o5byA5ZCvJzon5Y2V5o6o5YWz6ZetJyk7XFxuICAgICAgICAgIH0sc2hzb3J0LHBvYmosdmFyaSksXFxuICAgICAgICAgIGV4dHJhOntcXG4gICAgICAgICAgICBpZDpzaHNvcnQrJ19wdXNoJyxcXG4gICAgICAgICAgICBjbHM6c2hzb3J0KydfcHVzaHRhYicsXFxuICAgICAgICAgIH1cXG4gICAgICAgIH0se1xcbiAgICAgICAgICB0aXRsZTpwb2JqWyfpgInmjqgnXVswXSxcXG4gICAgICAgICAgY29sX3R5cGU6J3Njcm9sbF9idXR0b24nLFxcbiAgICAgICAgICB1cmw6JCgnI25vTG9hZGluZyMnKS5sYXp5UnVsZSgoc2hzb3J0LHBvYmosdmFyaSk9PntcXG4gICAgICAgICAgaWYoZ2V0TXlWYXIodmFyaSsnZm9sZCcsJzEnKT09JzAnKXtcXG4gICAgICAgICAgICByZXR1cm4gJ3RvYXN0Oi8v5bGV5byA5omN6IO95pON5L2cJztcXG4gICAgICAgICAgfVxcbiAgICAgICAgICB2YXIgdGl0bGVzPXBvYmpbJ+mAieaOqCddO1xcbiAgICAgICAgICB2YXIgcGNmZz1zdG9yYWdlMC5nZXRNeVZhcihzaHNvcnQrJ19wdXNoY2ZnJywne30nKTtcXG4gICAgICAgICAgcGNmZ1snb2JqJ109cG9iajtcXG4gICAgICAgICAgdmFyIOmAieaOqD1wY2ZnWyfpgInmjqgnXT9wY2ZnWyfpgInmjqgnXTpmYWxzZTtcXG4gICAgICAgICAgaWYo6YCJ5o6oKXtcXG4gICAgICAgICAgICB1cGRhdGVJdGVtKHNoc29ydCsnX3B1c2hzJyx7XFxuICAgICAgICAgICAgICB0aXRsZTp0aXRsZXNbMF0sXFxuICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICBwY2ZnWyfpgInmjqgnXT1mYWxzZTtcXG4gICAgICAgICAgICBwY2ZnWydwbGF5bGlzdCddLm1hcCgoeCk9PntcXG4gICAgICAgICAgICAgICB1cGRhdGVJdGVtKHguZXh0cmEuaWQse1xcbiAgICAgICAgICAgICAgICAgdGl0bGU6eC50aXRsZSxcXG4gICAgICAgICAgICAgICAgIHVybDp4LnVybCxcXG4gICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgdXBkYXRlSXRlbShzaHNvcnQrJ19wdXNodG8nLCB7XFxuICAgICAgICAgICAgICAgICAgICB0aXRsZTogJ+aOqOmAgeacrOmhtT0+VFZCb3gnLFxcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgIGNsZWFyTXlWYXIoc2hzb3J0KydfZHVvc2VsZWN0Jyk7XFxuICAgICAgICAgICB9ZWxzZXtcXG4gICAgICAgICAgICB1cGRhdGVJdGVtKHNoc29ydCsnX3B1c2hzJyx7XFxuICAgICAgICAgICAgICB0aXRsZTon4oCc4oCc4oCd4oCdJyt0aXRsZXNbMV0sXFxuICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICBwY2ZnWyfpgInmjqgnXT10cnVlO1xcbiAgICAgICAgICAgIHBjZmdbJ+WNleaOqCddPWZhbHNlO1xcbiAgICAgICAgICAgIHZhciBwbGF5bGlzdD1maW5kSXRlbXNCeUNscyhzaHNvcnQpO1xcbiAgICAgICAgICAgIHBjZmdbJ3BsYXlsaXN0J109cGxheWxpc3Q7XFxuICAgICAgICAgICAgbGV0IElkcz1wbGF5bGlzdC5tYXAoaXQgPT4gaXQuZXh0cmEuaWQpO1xcbiAgICAgICAgICAgICAgICBJZHMuZm9yRWFjaCh4ID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHZhciB0aXRsZSA9IGZpbmRJdGVtKHgpLnRpdGxlO1xcbiAgICAgICAgICAgICAgICAgICAgdXBkYXRlSXRlbSh4LCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiAkLm1zbSh0aXRsZSwgeCxzaHNvcnQpLFxcbiAgICAgICAgICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgIHVwZGF0ZUl0ZW0oc2hzb3J0KydfcHVzaCcse1xcbiAgICAgICAgICAgICAgdGl0bGU6cG9ialsn5Y2V5o6oJ11bMF0sXFxuICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICB1cGRhdGVJdGVtKHNoc29ydCsnX3B1c2h0bycsIHtcXG4gICAgICAgICAgICAgICAgICAgIH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XAobGkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgIHJldHVybiBsaS5tYXAoaXRlbSA9PiBpdGVtLnRpdGxlICsgJyQnICsgaXRlbS51cmwpLmpvaW4oJyMnKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KS5qb2luKCckJCQnKTtcXG4gICAgICAgICAgfWNhdGNoe1xcbiAgICAgICAgICB2YXIgcGxzPXN0b3JhZ2UwLmdldE15VmFyKHNoc29ydCtcXFwiX2xpc3RcXFwiLCdbXScpLm1hcCh4ID0+IHgudGl0bGUgKyBcXFwiJFxcXCIgKyB4LnVybCkuam9pbihcXFwiI1xcXCIpO1xcbiAgICAgICAgICB2YXIgdGFicz1bdGFic1tnZXRNeVZhcih2YXJpLCcwJyldXTtcXG4gICAgICAgICAgfVxcbiAgICAgICAgICAvKmxvZyhwbHMpXFxuICAgICAgICAgIGxvZyh0YWJzKSovXFxuICAgICAgICAgIH1cXG4gICAgICAgICAgaWYo6YCJ5o6oKXtcXG4gICAgICAgICAgdmFyIHBscz1zdG9yYWdlMC5nZXRNeVZhcihzaHNvcnQrXFxcIl9kdW9zZWxlY3RcXFwiLCdbXScpLm1hcCh4ID0+IHgudGl0bGUgKyBcXFwiJFxcXCIgKyB4LnVybCkuam9pbihcXFwiI1xcXCIpO1xcbiAgICAgICAgICBpZihwbHMubGVuZ3RoPT0wKXtcXG4gICAgICAgICAgICByZXR1cm4gJ3RvYXN0Oi8v6YCJ5oup5Li656m6JztcXG4gICAgICAgICAgfVxcbiAgICAgICAgICB2YXIgdGFicz1bJ+aSreaUvuWIl+ihqCddO1xcbiAgICAgICAgICB9XFxuICAgICAgICAgIFxcbiAgICAgICAgICB2YXIgaW5mbz1zdG9yYWdlMC5nZXRNeVZhcignZXJfaW5mbycsJ3t9Jyk7XFxuICAgICAgICAgIHZhciBkZXNjID1pbmZvWydkZXNjJ107XFxuICAgICAgICAgIHZhciDmjqjpgIEgPSB7XFxuICAgICAgICAgICAgICAgICBcXFwibmFtZVxcXCI6IGdldFBhZ2VUaXRsZSgpLFxcbiAgICAgICAgICAgICAgICAgXFxcImNvbnRlbnRcXFwiOiBkZXNjfHwnJyxcXG4gICAgICAgICAgICAgICAgIFxcXCJwaWNcXFwiOiBpbmZvWydpbWcnXSB8fCAnJyxcXG4gICAgICAgICAgICAgICAgIFxcXCJmcm9tXFxcIjogdGFicy5qb2luKCckJCQnKSxcXG4gICAgICAgICAgICAgICAgIFxcXCJ1cmxcXFwiOiBwbHMsXFxuICAgICAgICAgICB9XFxuICAgICAgICAgIC8vbG9nKOaOqOmAgSlcXG4gICAgICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9wYWdlL3B1c2g/cnVsZT1YWVHmjqjpgIEmcHVzaHVybD1cXFwiICsgZW5jb2RlVVJJQ29tcG9uZW50KEpTT04uc3RyaW5naWZ5KOaOqOmAgSkpXFxuICAgICAgICAgIH0sc2hzb3J0LHZhcmkpLFxcbiAgICAgICAgICBleHRyYTp7XFxuICAgICAgICAgICAgaWQ6c2hzb3J0KydfcHVzaHRvJyxcXG4gICAgICAgICAgICBjbHM6c2hzb3J0KydfcHVzaHRhYidcXG4gICAgICAgICAgfVxcbiAgICAgICAgfSx7XFxuICAgICAgICAgIGNvbF90eXBlOidibGFua19ibG9jaycsXFxuICAgICAgICAgIGV4dHJhOntcXG4gICAgICAgICAgICBjbHM6c2hzb3J0KydfcHVzaHRhYicsXFxuICAgICAgICAgIH1cXG4gICAgICAgIH0pXFxuICAgIH0sXFxuICAgIHNldExvbmdjbGljazpmdW5jdGlvbihzaHNvcnQsY3VzdG9tKXtcXG4gICAgICByZXR1cm4gW3t0aXRsZTon5qC35byP8J+OqCcsanM6ICQudG9TdHJpbmcoKHNoc29ydCk9PntcXG4gICAgICAgICAgICAgICAgICAgIGxldCBhbGxfY29scyA9IFsnJ10uY29uY2F0KGdldENvbFR5cGVzKCkpO1xcbiAgICAgICAgICAgICAgICAgICAgYWxsX2NvbHM9YWxsX2NvbHMuZmlsdGVyKHg9PlxcbiAgICAgICAgICAgICAgICAgICAgICAvKHRleHRffGZsZXgpLiovLnRlc3QoeCkmJnghPSd0ZXh0X2ljb24nKTtcXG4gICAgICAgICAgICAgICAgICAgICAgLy9sb2coYWxsX2NvbHMpXFxuICAgICAgICAgICAgICAgICAgICBsZXQgY2xzID0gc3RvcmFnZTAuZ2V0TXlWYXIoJ2VyX3BsYXlsaXN0cycsJ3t9JylcXG4gICAgICAgICAgICAgICAgICAgIHx8ICcnO1xcbiAgICAgICAgICAgICAgICAgICAgaWYoY2xzW3Noc29ydF0hPScnKXtcXG4gICAgICAgICAgICAgICAgICAgICAgY29sPWNsc1tzaHNvcnRdLmNvbF90eXBlO1xcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgbGV0IOaMiemSruagt+W8jyA9IGFsbF9jb2xzLm1hcCgoaXQpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gaXQgPT09IGNvbCA/ICfwn5GJJyArIGl0OiBpdDtcXG4gICAgICAgICAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgICAgICAgICAgbGV0IHRpcHMgPSAn6K+36YCJ5oup6YCJ6ZuG5oyJ6ZKu5qC35byPJztcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiAkKOaMiemSruagt+W8jywgMiwgdGlwcykuc2VsZWN0KChzaHNvcnQsY2xzKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgIGlucHV0ID0gaW5wdXQucmVwbGFjZSgv8J+RiS9nLCAnJyk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgLypzdG9yYWdlMC5zZXRJdGVtKCfmjInpkq7moLflvI8nLCBpbnB1dCk7Ki9cXG4gICAgICAgICAgICAgICAgICAgICAgICBsZXQgb2xkSWRzID0gKGZpbmRJdGVtc0J5Q2xzKHNoc29ydCkgfHwgW10pLm1hcChpdD0+aXQuZXh0cmEuaWQpOyAvL+iAgeWFg+e0oGlkc1xcbiAgICAgICAgICAgICAgICAgICAgICAgIG9sZElkcy5mb3JFYWNoKHg9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVwZGF0ZUl0ZW0oeCwge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6IGlucHV0XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAndG9hc3Q6Ly/lt7LliIfmjaLpgInpm4bmjInpkq7moLflvI/kuLo6JyArIGlucHV0O1xcbiAgICAgICAgICAgICAgICAgICAgfSxzaHNvcnQsY2xzKTtcXG4gICAgICAgICAgICAgICAgfSxzaHNvcnQsY3VzdG9tKX1dXFxuICAgIH0sXFxuICAgIHNldFRhYnM6IGZ1bmN0aW9uKHRhYnMsIHZhcmksIHNoc29ydCxwYXJzZSkge1xcbiAgICAgICAgbGV0IGN1c3RvbT1wYXJzZS7oh6rlrprkuYk7XFxuICAgICAgICBjdXN0b20gPXRoaXMuZ2V0UHJlc2V0KGN1c3RvbSk7XFxuICAgICAgICBzaHNvcnQgPSBzaHNvcnQgPyBzaHNvcnQgOiAnc2hzb3J0JztcXG4gICAgICAgIHZhciB0aXRsZSA9IChnZXRNeVZhcihzaHNvcnQgKyAnX3NvcnQnLCAnMCcpID09ICcxJykgPyAnPGI+PHNwYW4gc3R5bGU9XFxcImNvbG9yOiAnK2N1c3RvbS7pgIbluo/popzoibIrJ1xcXCI+6YCG5bqPPC9zcGFuPjwvYj4nIDogJzxiPjxzcGFuIHN0eWxlPVxcXCJjb2xvcjogJytjdXN0b20u5q2j5bqP6aKc6ImyKydcXFwiPuato+W6jzwvc3Bhbj48L2I+J1xcbiAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICB0aXRsZTogdmFyaSArICc6JyArIHRpdGxlLFxcbiAgICAgICAgICAgIGRlc2M6ICflhbEnICsgU3RyaW5nKHRhYnMubGVuZ3RoKS5mb250Y29sb3IoJyM0NjgyQjQnKSArICfmnaHnur/ot68nLFxcbiAgICAgICAgICAgIHVybDogJCgnI25vTG9hZGluZyMnKS5sYXp5UnVsZSgoc2hzb3J0LHZhcmksY3VzdG9tKSA9PiB7XFxuICAgICAgICAgICAgICBsZXQgY29uZiA9IGdldE15VmFyKHNoc29ydCArICdfc29ydCcsICcwJyk7XFxuICAgICAgICAgICAgICBpZihnZXRNeVZhcignZXJfJyt2YXJpKydmb2xkJywnMScpPT0nMCcpe1xcbiAgICAgICAgICAgICAgcmV0dXJuICd0b2FzdDovL+WxleW8gOaJjeiDveaTjeS9nCc7XFxuICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIHZhciBjbHNsaXN0cyA9IGZpbmRJdGVtc0J5Q2xzKHNoc29ydCk7XFxuICAgICAgICAgICAgICAgIHZhciBuZXdjbHNsaXN0ID0gJC5kYXRhQ29udmVydChjbHNsaXN0cyk7XFxuICAgICAgICAgICAgICAgXFxuICAgICAgICAgICAgICAgdmFyIHRpdGxlcz1bYCR7Y3VzdG9tLuato+W6j+minOiJsn1cXFwiPuato+W6j2AsYCR7Y3VzdG9tLumAhuW6j+minOiJsn1cXFwiPumAhuW6j2BdO1xcbiAgICAgICAgICAgICAgIFxcbiAgICAgICAgICAgICAgICBkZWxldGVJdGVtQnlDbHMoc2hzb3J0KTtcXG4gICAgICAgICAgICAgICAgbmV3Y2xzbGlzdC5yZXZlcnNlKCk7XFxuICAgICAgICAgICAgICAgIGFkZEl0ZW1BZnRlcihzaHNvcnQgKyAnX2xpbmUnLCBuZXdjbHNsaXN0KTtcXG5cXG4gICAgICAgICAgICAgICAgdmFyIG9iaiA9IGZpbmRJdGVtKHNoc29ydCArICdfYXZhdGFyJylcXG5cXG4gICAgICAgICAgICAgICAgaWYgKGNvbmYgPT0gJzEnKSB7XFxuICAgICAgICAgICAgICAgICAgICB1cGRhdGVJdGVtKHNoc29ydCArICdfYXZhdGFyJywge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiBvYmoudGl0bGUucmVwbGFjZSh0aXRsZXNbMV0sIHRpdGxlc1swXSksXFxuICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgcHV0TXlWYXIoc2hzb3J0ICsgJ19zb3J0JywgJzAnKTtcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgIHVwZGF0ZUl0ZW0oc2hzb3J0ICsgJ19hdmF0YXInLCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdGl0bGU6IG9iai50aXRsZS5yZXBsYWNlKHRpdGxlc1swXSwgdGl0bGVzWzFdKSxcXG4gICAgICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgICAgICBwdXRNeVZhcihzaHNvcnQgKyAnX3NvcnQnLCAnMScpO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIHJldHVybiAndG9hc3Q6Ly/liIfmjaLmjpLluo/miJDlip8nO1xcbiAgICAgICAgICAgIH0sIHNoc29ydCx2YXJpLGN1c3RvbSksXFxuICAgICAgICAgICAgY29sX3R5cGU6ICdhdmF0YXInLFxcbiAgICAgICAgICAgIGltZzogY3VzdG9tLuWbvuaghyAsXFxuICAgICAgICAgICAgZXh0cmE6e1xcbiAgICAgICAgICAgICAgaWQ6c2hzb3J0KydfYXZhdGFyJyxcXG4gICAgICAgICAgICAgIGxvbmdDbGljazp0aGlzLnNldExvbmdjbGljayhzaHNvcnQpLFxcbiAgICAgICAgICAgIH1cXG4gICAgICAgIH0pXFxuICAgICAgICB2YXIg5oqY5Y+gID0gJ+KAnOKAnOKAneKAnTxiPicgKyAn4pi3Jy5mb250Y29sb3IoXFxcIiNEM0QzRDNcXFwiKTtcXG4gICAgICAgIHZhciDlsZXlvIAgPSAn4oCc4oCc4oCd4oCdPGI+JyArICfimLAnLmZvbnRjb2xvcihcXFwiI0ZGQTUwMFxc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kSXRlbUFmdGVyKG9iai5leHRyYS5pZCwgY3MpO1xcbiAgICAgICAgICAgICAgICB1cGRhdGVJdGVtKGJ0bi5leHRyYS5pZCwge1xcbiAgICAgICAgICAgICAgICAgICAgdGl0bGU6IGJ0bi50aXRsZS5yZXBsYWNlKGZvbGRzWzBdLCBmb2xkc1sxXSksXFxuICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICBpZihmb2xkPT0nMScpe1xcbiAgICAgICAgICAgICAgICAgIHB1dE15VmFyKGZvbGRuYW1lLCAgJzAnKTtcXG4gICAgICAgICAgICAgICAgdmFyIHBjbHMgPSBmaW5kSXRlbXNCeUNscyhzaHNvcnQpO1xcbiAgICAgICAgICAgICAgICB2YXIgY3ggPSAkLmRhdGFDb252ZXJ0KHBjbHMpO1xcbiAgICAgICAgICAgICAgICBzdG9yYWdlMC5wdXRNeVZhcihzaHNvcnQgKyAnX2NscycsIGN4KTtcXG4gICAgICAgICAgICAgICAgZGVsZXRlSXRlbUJ5Q2xzKHNoc29ydCk7XFxuICAgICAgICAgICAgICAgIHVwZGF0ZUl0ZW0oYnRuLmV4dHJhLmlkLCB7XFxuICAgICAgICAgICAgICAgICAgICB0aXRsZTogYnRuLnRpdGxlLnJlcGxhY2UoZm9sZHNbMV0sIGZvbGRzWzBdKSxcXG4gICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICBcXG4gICAgICAgICAgICAgICAgcmV0dXJuICd0b2FzdDovLycgKyAoZm9sZCA9PT0gJzEnID8gJ+aUtui1tycgOiAn5bGV5byAJyk7XFxuICAgICAgICAgICAgfSwgZm9sZG5hbWUsc2hzb3J0KSxcXG4gICAgICAgICAgICBleHRyYToge1xcbiAgICAgICAgICAgICAgICBpZDogc2hzb3J0ICsgJ19idXR0b24nLFxcbiAgICAgICAgICAgIH1cXG4gICAgICAgIH0pXFxuICAgICAgICB0aGlzLmNyZW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sICd7fScpO1xcbiAgICAgICAgICAgIGlmIChPYmplY3Qua2V5cyhwbCkubGVuZ3RoID09IDEpIHtcXG4gICAgICAgICAgICAgICAgcmV0dXJuICdoaWtlcjovL2VtcHR5J1xcbiAgICAgICAgICAgIH1cXG5cXG4gICAgICAgICAgICB2YXIgZm9sZCA9IGdldE15VmFyKGZvbGRuYW1lLCAnMScpO1xcbiAgICAgICAgICAgIHZhciBvYmogPSBmaW5kSXRlbShzaHNvcnQgKyAnX2F2YXRhcicpXFxuICAgICAgICAgICAgaWYgKGZvbGQgPT0gJzEnKSB7XFxuICAgICAgICAgICAgICAgIHZhciBiY2xzID0gZmluZEl0ZW0oc2hzb3J0ICsgJ19idXR0b24nKTtcXG4gICAgICAgICAgICAgICAgdmFyIHRjbHMgPSBmaW5kSXRlbXNCeUNscyhzaHNvcnQgKyAnX3RhYicpO1xcbiAgICAgICAgICAgICAgICB2YXIgbGNscyA9IGZpbmRJdGVtKHNoc29ydCArICdfbGluZScpO1xcbiAgICAgICAgICAgICAgICBcXG4gICAgICAgICAgICAgICAgdmFyIHBjbHMgPSBmaW5kSXRlbXNCeUNscyhzaHNvcnQpO1xcbiAgICAgICAgICAgICAgICB2YXIgY3MgPSBbYmNsc10uY29uY2F0KHRjbHMsIFtsY2xzXSwgcGNscyk7XFxuICAgICAgICAgICAgICAgIFxcbiAgICAgICAgICAgICAgICBpZihwdXNoKXtcXG4gICAgICAgICAgICAgICAgICB2YXIgcGNscz1maW5kSXRlbXNCeUNscyhzaHNvcnQrJ19wdXNodGFiJyk7XFxuICAgICAgICAgICAgICAgICAgY3M9cGNscy5jb25jYXQoY3MpO1xcbiAgICAgICAgICAgICAgICB9XFxuXFxuICAgICAgICAgICAgICAgIHZhciBjeCA9ICQuZGF0YUNvbnZlcnQoY3MpO1xcbiAgICAgICAgICAgICAgICBzdG9yYWdlMC5wdXRNeVZhcihzaHNvcnQgKyAnX2NscycsIGN4KTtcXG4gICAgICAgICAgICAgICAgaWYocHVzaCl7XFxuICAgICAgICAgICAgICAgICAgZGVsZXRlSXRlbUJ5Q2xzKHNoc29ydCsnX3B1c2h0YWInKTtcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICBkZWxldGVJdGVtKGJjbHMuZXh0cmEuaWQpO1xcbiAgICAgICAgICAgICAgICBkZWxldGVJdGVtQnlDbHMoc2hzb3J0ICsgJ190YWInKTtcXG4gICAgICAgICAgICAgICAgZGVsZXRlSXRlbShzaHNvcnQgKyAnX2xpbmUnKTtcXG4gICAgICAgICAgICAgICAgZGVsZXRlSXRlbUJ5Q2xzKHNoc29ydCk7XFxuXFxuICAgICAgICAgICAgICAgIHVwZGF0ZUl0ZW0ob2JqLmV4dHJhLmlkLCB7XFxuICAgICAgICAgICAgICAgICAgICBkZXNjOiBvYmouZGVzYy5yZXBsYWNlKCflsZXlvIA8Zm9udCBjb2xvcj1cXFwiI0ZGQTUwMFxcXCI+4piwJywgJ+aKmOWPoDxmb250IGNvbG9yPVxcXCIjRDNEM0QzXFxcIj7imLcnKSxcXG4gICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgaWYgKGZvbGQgPT0gJzAnKSB7XFxuICAgICAgICAgICAgICAgIHZhciBjcyA9IHN0b3JhZ2UwLmdldE15VmFyKHNoc29ydCArICdfY2xzJyk7XFxuICAgICAgICAgICAgICAgIGFkZEl0ZW1BZnRlcihzaHNvcnQgKyAnX2F2YXRhcicsIGNzKTtcXG4gICAgICAgICAgICAgICAgdXBkYXRlSXRlbShvYmouZXh0cmEuaWQsIHtcXG4gICAgICAgICAgICAgICAgICAgIGRlc2M6IG9iai5kZXNjLnJlcGxhY2UoJ+aKmOWPoDxmb250IGNvbG9yPVxcXCIjRDNEM0QzXFxcIj7imLcnLCAn5bGV5byAPGZvbnQgY29sb3I9XFxcIiNGRkE1MDBcXFwiPuKYsCcpLFxcbiAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIH1cXG4gICAgICAgICAgICBwdXRNeVZhcihmb2xkbmFtZSwgZm9sZCA9PT0gJzEnID8gJzAnIDogJzEnKTtcXG4gICAgICAgICAgICByZXR1cm4gJ3RvYXN0Oi8vJyArIChmb2xkID09PSAnMScgPyAn5pS26LW3JyA6ICflsZXlvIAnKTtcXG4gICAgICAgIH0sIGZvbGRuYW1lLCBzaHNvcnQsKHBhcnNlWyfmjqjpgIEnXT90cnVlOmZhbHNlKSk7XFxuICAgICAgICB2YXIgZGVzYyA9IChmb2xkID09PSAnMCcgPyDmipjlj6AgOiDlsZXlvIApICsgJ1xcXFx0JztcXG5cXG4gICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgdGl0bGU6IHZhcmkgKyAnOlxcXFx0XFxcXHQnICsgJ+WFsScgKyBTdHJpbmcodGFicy5sZW5ndGgpLmZvbnRjb2xvcignIzQ2ODJCNCcpICsgJ+adoee6v+i3rycsXFxuICAgICAgICAgICAgZGVzYzogZGVzYyxcXG4gICAgICAgICAgICBjb2xfdHlwZTogJ2F2YXRhcicsXFxuICAgICAgICAgICAgaW1nOiBjdXN0b20u5Zu+5qCHLFxcbiAgICAgICAgICAgIHVybDogdXJsLFxcbiAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgIGlkOiBzaHNvcnQgKyAnX2F2YXRhcicsXFxuICAgICAgICAgICAgICAgIGxvbmdDbGljazp0aGlzLnNldExvbmdjbGljayhzaHNvcnQpLFxcbiAgICAgICAgICAgIH1cXG4gICAgICAgIH0pXFxuICAgICAgICBpZih0eXBlb2YocGFyc2VbJ+aOqOmAgSddKSE9J3VuZGVmaW5lZCcmJnBhcnNlWyfmjqjpgIEnXSlcXG4gICAgICAgIHRoaXMucHVzaFRhYignZXJfJyt2YXJpLHNoc29ydCk7XFxuICAgICAgICBcXG4gICAgICAgIGlmIChmb2xkID09ICcwJykge1xcbiAgICAgICAgICAgIHJldHVyblxcbiAgICAgICAgfVxcblxcbiAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICB0aXRsZTogJ+KAnOKAnOKAneKAnScgKyB0aXRsZSxcXG4gICAgICAgICAgICB1cmw6ICQoJyNub0xvYWRpbmcjJykubGF6eVJ1bGUoKHZhcmksIHNoc29ydCxjdXN0b20pID0+IHtcXG4gICAgICAgICAgICAgICAgbGV0IGNvbmYgPSBnZXRNeVZhcihzaHNvcnQgKyAnX3NvcnQnLCAnMCcpO1xcbiAgICAgICAgICAgICAgICB2YXIgY2xzbGlzdHMgPSBmaW5kSXRlbXNCeUNscyhzaHNvcnQpO1xcbiAgICAgICAgICAgICAgICB2YXIgbmV3Y2xzbGlzdCA9ICQuZGF0YUNvbnZlcnQoY2xzbGlzdHMpO1xcbiAgICAgICAgICAgICAgICBkZWxldGVJdGVtQnlDbHMoc2hzb3J0KTtcXG4gICAgICAgICAgICAgICAgbmV3Y2xzbGlzdC5yZXZlcnNlKCk7XFxuICAgICAgICAgICAgICAgIGFkZEl0ZW1BZnRlcihzaHNvcnQgKyAnX2xpbmUnLCBuZXdjbHNsaXN0KTtcXG5cXG4gICAgICAgICAgICAgICAgdmFyIG9iaiA9IGZpbmRJdGVtKHNoc29ydCArICdfYnV0dG9uJylcXG4gICAgICAgICAgICAgICAgdmFyIHRpdGxlcz1bYCR7Y3VzdG9tLuato+W6j+minOiJsn1cXFwiPuato+W6j2AsYCR7Y3VzdG9tLumAhuW6j+minOiJsn1cXFwiPumAhuW6j2BdO1xcbiAgICAgICAgICAgICAgICBcXG4gICAgICAgICAgICAgICAgaWYgKGNvbmYgPT0gJzEnKSB7XFxuICAgICAgICAgICAgICAgICAgICB1cGRhdGVJdGVtKHNoc29ydCArICdfYnV0dG9uJywge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiBvYmoudGl0bGUucmVwbGFjZSh0aXRsZXNbMV0sIHRpdGxlc1swXSksXFxuICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgcHV0TXlWYXIoc2hzb3J0ICsgJ19zb3J0JywgJzAnKTtcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgIHVwZGF0ZUl0ZW0oc2hzb3J0ICsgJ19idXR0b24nLCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdGl0bGU6IG9iai50aXRsZS5yZXBsYWNlKHRpdGxlc1swXSwgdGl0bGVzWzFdKSxcXG4gICAgICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgICAgICBwdXRNeVZhcihzaHNvcnQgKyAnX3NvcnQnLCAnMScpO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIC8vcmVmcmVzaFBhZ2UoKVxcbiAgICAgICAgICAgICAgICByZXR1cm4gJ3RvYXN0Oi8v5YiH5o2i5o6S5bqP5oiQ5YqfJ1xcbiAgICAgICAgICAgIH0sIHZhcmksIHNoc29ydCxjdXN0b20pLFxcbiAgICAgICAgICAgIGNvbF90eXBlOiAnc2Nyb2xsX2J1dHRvbicsXFxuICAgICAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgICAgICAgaWQ6IHNoc29ydCArICdfYnV0dG9uJyxcXG4gICAgICAgICAgICB9XFxuICAgICAgICB9KVxcbiAgICAgICAgdGhpcy5jcmVhdGVQTGlzdCh0YWJzLHZhcmksc2hzb3J0LGN1c3RvbSk7XFxuICAgIH0sXFxuICAgIHNldExpc3RzOiBmdW5jdGlvbihsaXN0cywgaW5kZXgsIHNoc29ydCxwYXJzZSkge1xcblxcbiAgICAgICAgc3RvcmFnZTAucHV0TXlWYXIoc2hzb3J0ICsgJ19saXN0JywgbGlzdHMpO1xcbiAgICAgICAgXFxuICAgICAgICBwYXJzZT1wYXJzZT9wYXJzZTp7fTtcXG4gICAgICAgIHZhciDmoLflvI89cGFyc2Uu5qC35byPP3BhcnNlLuagt+W8jzonJztcXG4gICAgICAgIHZhciDlm77moIc9cGFyc2Uu5Zu+5qCHP3BhcnNlLuWbvuaghzonaHR0cHM6Ly9oaWtlcmZhbnMuY29tL3R1Ymlhby9tb3ZpZS8xMy5zdmcnO1xcbiAgICAgICAgdmFyIGFqYXg9cGFyc2UuQWpheD9wYXJzZS5BamF4OmZhbHNlO1xcblxcbiAgICAgICAgc2hzb3J0ID0gc2hzb3J0ID8gc2hzb3J0IDogJ3Noc29ydCc7XFxuXFxuICAgICAgICBpZihhamF4KXtcXG4gICAgICAgICAgICB2YXIgbGlzdCA9IGxpc3RzO1xcbiAgICAgICAgICAgIGlmIChnZXRNeVZhcihzaHNvcnQgKyAnX3NvcnQnKSA9PSAnMScgJiYgbGlzdHMubGVuZ3RoID4gMCkge1xcbiAgICAgICAgICAgICAgICBsaXN0ID0gbGlzdHMucmV2ZXJzZSgpO1xcbiAgICAgICAgICAgfVxcbiAgICAgICAgfWVsc2V7XFxuICAgICAgICAgICAgdmFyIGxpc3QgPSBsaXN0c1tpbmRleF07XFxuICAgICAgICAgICAgaWYgKGdldE15VmFyKHNoc29ydCArICdfc29ydCcpID09ICcxJyAmJiBsaXN0cy5sZW5ndGggPiAwKSB7XFxuICAgICAgICAgICAgICAgIGxpc3QgPSBsaXN0c1tpbmRleF0ucmV2ZXJzZSgpO1xcbiAgICAgICAgICAgfVxcbiAgICAgICAgfVxcbiAgICAgICAgXFxuICAgICAgICBpZijmoLflvI89PScnKXtcXG4gICAgICAgICAg5qC35byPPWxpc3QubGVuZ3RoID4gMyA/ICd0ZXh0XzQnIDogJ3RleHRfMidcXG4gICAgICAgIH1cXG4gICAgICAgIFxcbiAgICAgICAgaWYobGlzdC5sZW5ndGggPiAwKXtcXG4gICAgICAgIHZhciBwbGlzdCA9IHN0b3JhZ2UwLmdldE15VmFyKCdlcl9wbGF5bGlzdHMnLCAne30nKTtcXG4gICAgICAgIGlmKCFwbGlzdC5oYXNPd25Qcm9wZXJ0eShzaHNvcnQpKXtcXG4gICAgICAgICAgICAgcGxpc3Rbc2hzb3J0XT17fTtcXG4gICAgICAgIH1cXG4gICAgICAgIHBsaXN0W3Noc29ydF1bJ2NscyddPXNoc29ydDtcXG4gICAgICAgIHBsaXN0W3Noc29ydF1bJ2NvbF90eXBlJ1095qC35byPO1xcbiAgICAgICAgcGxpc3Rbc2hzb3J0XVsncGljJ1095Zu+5qCHO1xcbiAgICAgICAgc3RvcmFnZTAucHV0TXlWYXIoJ2VyX3BsYXlsaXN0cycsIHBsaXN0KTtcXG4gICAgICAgIH0gICBcXG4gICAgICAgIFxcbiAgICAgICAgXFxuICAgICAgICBmb3IgKHZhciBqIGluIGxpc3QpIHtcXG4gICAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgICAgICB0aXRsZTogbGlzdFtqXS50aXRsZSxcXG4gICAgICAgICAgICAgICAgdXJsOiBsaXN0W2pdLnVybCxcXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6IOagt+W8jyxcXG4gICAgICAgICAgICAgICAgcGljOuWbvuaghyxcXG4gICAgICAgICAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgICAgICAgICAgIGlkOiBsaXN0W2pdLnVybC5yZXBsYWNlKC9AbGF6eVJ1bGVbXFxcXHNcXFxcU10rL2csICcnKSxcXG4gICAgICAgICAgICAgICAgICAgIGNsczogc2hzb3J0LFxcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgfSk7XFxuICAgICAgICB9XFxuICAgIH0sXFxuICAgIGdldFRhYnM6IGZ1bmN0aW9uKHBhcnNlKSB7XFxuICAgICAgICB2YXIgdGFicyA9IFtdO1xcbiAgICAgICAgdmFyIGFydHMgPSBwZGZhKGh0bWwsIHBhcnNlLue6v+i3ryk7XFxuICAgICAgICB2YXIg57q/6Lev5ZCNID0gcGFyc2Uu57q/6Lev5ZCN56ewO1xcbiAgICAgICAgdmFyIOabv+aNouWHveaVsCA9ICcnO1xcbiAgICAgICAgaWYgKHBhcnNlLue6v+i3r+WQjeensC5pbmNsdWRlcygnQEAnKSkge1xcbiAgICAgICAgICAgIOe6v+i3r+WQjSA9IHBhcnNl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ICBpZiAocGFyc2Uu6YCJ6ZuG5YiX6KGoICE9IHVuZGVmaW5lZCkge1xcbiAgICAgICAgICAgICAgICBsaXN0cy5wdXNoKHBkZmEoY29udHNbaV0sIHBhcnNlLumAiembhuWIl+ihqCkubWFwKHggPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogcGRmaCh4LCDpgInpm4blkI3np7ApXFxuLnJlcGxhY2UoXFxcIuesrFxcXCIsXFxcIlxcXCIpXFxuLnJlcGxhY2UoXFxcIumbhlxcXCIsXFxcIlxcXCIpXFxuLnJlcGxhY2UoXFxcIuacn1xcXCIsXFxcIlxcXCIpXFxuLnJlcGxhY2UoXFxcIuivnVxcXCIsXFxcIlxcXCIpXFxuLnJlcGxhY2UoXFxcIuacgOaWsFxcXCIsXFxcIlxcXCIpLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogcGQoeCwg6YCJ6ZuG6ZO+5o6lKSArIOino+aekCxcXG4gICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgfSkpXFxuICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgdmFyIHVybCA9IHBkKGNvbnRzW2ldLCDpgInpm4bpk77mjqUpO1xcbiAgICAgICAgICAgICAgICBpZiAoIemAiembhumTvuaOpS5pbmNsdWRlcygnaHJlZicpKSB7XFxuICAgICAgICAgICAgICAgICAgICB1cmwgPSBwZGZoKGNvbnRzW2ldLCDpgInpm4bpk77mjqUpO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIHRlbXAucHVzaCh7XFxuICAgICAgICAgICAgICAgICAgICB0aXRsZTogcGRmaChjb250c1tpXSwg6YCJ6ZuG5ZCN56ewKSxcXG4gICAgICAgICAgICAgICAgICAgIHVybDogdXJsICsg6Kej5p6QLFxcbiAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIH1cXG4gICA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oKChpdGVtLCBpKSA9PiB7XFxuICAgICAgICAgICAgdmFyIHRhYnMgPSBbJ+S4u+e6vyddO1xcbiAgICAgICAgICAgIGlmIChpdGVtLue6v+i3ryAhPSB1bmRlZmluZWQpIHtcXG4gICAgICAgICAgICAgICAgdGFicyA9IHRoaXMuZ2V0VGFicyhpdGVtKTtcXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgcHV0TXlWYXIocGxheStpKydfdGFicycsdGFicyk7XFxuICAgICAgICAgICAgaWYoaXRlbS5BamF4KXtcXG4gICAgICAgICAgICAgICAgaWYgKG1vZGUgPT0gMSkge1xcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5zZXRUYWJzKHRhYnMsIGl0ZW0u57G75Z6LLCBwbGF5ICsgaSxpdGVtKTtcXG4gICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICB0aGlzLnNldFRhYnMyKHRhYnMsIGl0ZW0u57G75Z6LLCBwbGF5ICsgaSxpdGVtKTtcXG4gICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgIHB1dE15VmFyKCdlcl9odG1sJyxodG1sKTtcXG4gICAgICAgICAgICAgICAgIHB1dE15VmFyKCdlcl91cmwnLE1ZX1VSTCk7XFxuXFxuICAgICAgICAgICAgICAgIHZhciBsaXN0cz1mdW5jKGdldE15VmFyKCdlcl8nK2l0ZW0u57G75Z6LLCcwJyksTVlfVVJMKTtcXG4gICAgICAgICAgICB9ZWxzZXtcXG4gICAgICAgICAgICB2YXIgbGlzdHMgPSB0aGlzLmdldExpc3RzKGl0ZW0sIHBsYXkraSk7XFxuICAgICAgICAgICAgLy9sb2cobGlzdHMpXFxuICAgICAgICAgICAgaWYgKGxpc3RzLnNvbWUoeCA9PiB4Lmxlbmd0aCA+IDApKSB7XFxuICAgICAgICAgICAgICAgIGlmIChtb2RlID09IDEpIHtcXG4gICAgICAgICAgICAgICAgICAgIHRoaXMuc2V0VGFicyh0YWJzLCBpdGVtLuexu+WeiywgcGxheSArIGksaXRlbSk7XFxuICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5zZXRUYWJzMih0YWJzLCBpdGVtLuexu+WeiywgcGxheSArIGksaXRlbSk7XFxuICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgaWYgKGdldE15VmFyKCdlcl8nICsgaXRlbS7nsbvlnosgKyAnZm9sZCcsICcxJykgPT0gJzEnKSB7XFxuICAgICAgICAgICAgICAgIHRoaXMuc2V0TGlzdHMobGlzdHMsIGdldE15VmFyKCdlcl8nK2l0ZW0u57G75Z6LLCAnMCcpLCBwbGF5ICsgaSxpdGVtKTtcXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6ICdibGFua19ibG9jaydcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgfSlcXG4gICAgfVxcbn1cXG5cXG5cXG5sZXQgTWV0aG9kcz17XFxuICAgIC8v5aSa6YCJ5qih5Z2XXFxuICAgIE11bHRpU2VsZWN0TW9kZTpmdW5jdGlvbihuYW1lLGlkLHNoc29ydCl7XFxuICAgICAgICByZXR1cm4gJCgnI25vTG9hZGluZyMnKS5sYXp5UnVsZSgoZGF0YXRpdGxlLCBkYXRhdXJsLHNoc29ydCkgPT4ge1xcbiAgICAgICAgICAgIGZ1bmN0aW9uIHVuaXF1ZShhcnIpIHtcXG4gICAgICAgICAgICBjb25zdCByZXMgPSBuZXcgTWFwKClcXG4gICAgICAgICAgICByZXR1cm4gYXJyLmZpbHRlcigoYSkgPT4gIXJlcy5oYXMoYS51cmwpICYmIHJlcy5zZXQoYS51cmwsIDEpKVxcbiAgICAgICAgICAgIH1cXG4gICAgICAgICAgICBsZXQgZHVvc2VsZWN0ID0gc3RvcmFnZTAuZ2V0TXlWYXIoc2hzb3J0K1xcXCJfZHVvc2VsZWN0XFxcIikgPyBzdG9yYWdlMC5nZXRNeVZhcihzaHNvcnQrXFxcIl9kdW9zZWxlY3RcXFwiKSA6IFtdO1xcbiAgICAgICAgICAgIGlmIChkdW9zZWxlY3QuZmluZEluZGV4KHggPT4geC51cmwgPT09IGRhdGF1cmwpID09IC0xKSB7XFxuICAgICAgICAgICAgICAgIGR1b3NlbGVjdC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOiBkYXRhdGl0bGUsXFxuICAgICAgICAgICAgICAgICAgICB1cmw6IGRhdGF1cmxcXG4gICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgZHVvc2VsZWN0ID0gdW5pcXVlKGR1b3NlbGVjdClcXG4gICAgICAgICAgICAgICAgdXBkYXRlSXRlbShkYXRhdXJsLCB7XFxuICAgICAgICAgICAgICAgICAgICB0aXRsZTogYOKAnOKAnOKAneKAnTxzcGFuIHN0eWxlPVxcXCJjb2xvcjojRkY1NzMzXFxcIj5gICsgZGF0YXRpdGxlLFxcbiAgICAgICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICBmdW5jdGlvbiByZW1vdmVCeVZhbHVlKGFyciwgdmFsKSB7XFxuICAgICAgICAgICAgICAgICAgICBmb3IgKHZhciBpID0gMDsgaSA8IGFyci5sZW5ndGg7IGkrKykge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChhcnJbaV1bJ3VybCddID09IHZhbCkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBhcnIuc3BsaWNlKGksIDEpO1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgcmVtb3ZlQnlWYWx1ZShkdW9zZWxlY3QsIGRhdGF1cmwpXFxu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nIDopoHnmbvlvZXpqozor4EnLFxcbiAgICAgICAgZGVzYzogJ+mqjOivgeaIkOWKn+WQjuWNs+WPr+afpeeci+WIhuexuycsXFxuICAgICAgICB1cmw6ICQoJ2hpa2VyOi8vZW1wdHknKS5ydWxlKCgpID0+IHtcXG4gICAgICAgICAgICB2YXIgaXRlbXMgPSBbXTtcXG4gICAgICAgICAgICB2YXIgaW1nbGluID0gJ2h0dHBzOi8vd3d3Lm1nbmFjZy5jb20vdmVyaWZ5L2luZGV4Lmh0bWw/cj0nICsgTWF0aC5yYW5kb20oKTtcXG4gICAgICAgICAgICAvL+WPluWbvueJh2Nvb2tpZVxcbiAgICAgICAgICAgIHZhciBjb2sgPSBKU09OLnBhcnNlKGZldGNoQ29va2llKGltZ2xpbiwge1xcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7XFxuICAgICAgICAgICAgICAgICAgICAnVXNlci1BZ2VudCc6IE1PQklMRV9VQVxcbiAgICAgICAgICAgICAgICB9LFxcbiAgICAgICAgICAgICAgICBtZXRob2Q6ICdHRVQnLFxcbiAgICAgICAgICAgICAgICB3aXRoSGVhZGVyczogdHJ1ZVxcbiAgICAgICAgICAgIH0pKS5qb2luKCc7Jyk7XFxuXFxuICAgICAgICAgICAgLy/mmL7npLrpqozor4HnoIFcXG4gICAgICAgICAgICBpdGVtcy5wdXNoKHtcXG4gICAgICAgICAgICAgICAgcGljX3VybDogaW1nbGluICsgJ0BVc2VyLUFnZW50PScgKyBNT0JJTEVfVUEgKyAnQENvb2tpZT0nICsgY29rLFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoJycpLmxhenlSdWxlKCgpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiByZWZyZXNoUGFnZSgpO1xcbiAgICAgICAgICAgICAgICB9KSxcXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6ICdwaWNfMV9mdWxsJ1xcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgIC8v6L6T5YWl5qGGXFxuICAgICAgICAgICAgaXRlbXMucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiAnJyxcXG4gICAgICAgICAgICAgICAgdXJsOiBcXFwiJ3RvYXN0Oi8v5L2g6L6T5YWl55qE5pivJyArIGlucHV0XFxcIixcXG4gICAgICAgICAgICAgICAgZGVzYzogXFxcIui0puWPt1xcXCIsXFxuICAgICAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgICAgICBvbkNoYW5nZTogXFxcInB1dE15VmFyKCfotKblj7cnLGlucHV0KVxcXCIsXFxuICAgICAgICAgICAgICAgICAgICB0aXRsZVZpc2libGU6IGZhbHNlXFxuICAgICAgICAgICAgICAgIH0sXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnaW5wdXQnXFxuICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgaXRlbXMucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiAnJyxcXG4gICAgICAgICAgICAgICAgZGVzYzogXFxcIuWvhueggVxcXCIsXFxuICAgICAgICAgICAgICAgIHVybDogXFxcIid0b2FzdDovL+S9oOi+k+WFpeeahOaYrycgKyBpbnB1dFxcXCIsXFxuICAgICAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgICAgICBvbkNoYW5nZTogXFxcInB1dE15VmFyKCflr4bnoIEnLGlucHV0KVxcXCIsXFxuICAgICAgICAgICAgICAgICAgICB0aXRsZVZpc2libGU6IGZhbHNlXFxuICAgICAgICAgICAgICAgIH0sXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnaW5wdXQnXFxuICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgaXRlbXMucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiAnJyxcXG4gICAgICAgICAgICAgICAgdXJsOiBcXFwiJ3RvYXN0Oi8v5L2g6L6T5YWl55qE5pivJyArIGlucHV0XFxcIixcXG4gICAgICAgICAgICAgICAgZGVzYzogXFxcIumqjOivgeeggVxcXCIsXFxuICAgICAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgICAgICBvbkNoYW5nZTogXFxcInB1dE15VmFyKCfmqZjlrZDpqozor4HnoIEnLGlucHV0KVxcXCIsXFxuICAgICAgICAgICAgICAgICAgICB0aXRsZVZpc2libGU6IGZhbHNlXFxuICAgICAgICAgICAgICAgIH0sXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnaW5wdXQnXFxuICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgaXRlbXMucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiAn5Y+R6YCBJyxcXG4gICAgICAgICAgICAgICAgdXJsOiAkKE1ZX1VSTCkubGF6eVJ1bGUoKGNvaykgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgdmFyIGNvZCA9IGdldE15VmFyKCfmqZjlrZDpqozor4HnoIEnKTtcXG4gICAgICAgICAgICAgICAgICAgIHZhciB1c2VybmFtZSA9IGdldE15VmFyKCfotKblj7cnKTtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBwYXNzd2QgPSBnZXRNeVZhcign5a+G56CBJyk7XFxuICAgICAgICAgICAgICAgICAgICB2YXIgaHRtbCA9IEpTT04ucGFyc2UoZmV0Y2goJ2h0dHBzOi8vd3d3Lm1nbmFjZy5jb20vdXNlci9sb2dpbi5odG1sJywge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgJ1gtUmVxdWVzdGVkLVdpdGgnOiAnWE1MSHR0cFJlcXVlc3QnLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAnVXNlci1BZ2VudCc6IE1PQklMRV9VQSxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgJ0Nvb2tpZSc6IGNva1xcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sXFxuICAgICAgICAgICAgICAgICAgICAgICAgYm9keToge1xcbiAgICAgICAgICAgICAgICAgICAgdXNlcl9uYW1lOiB1c2VybmFtZSxcXG4gICAgICAgICAgICAgICAgICAgIHVzZXJfcHdkOiBwYXNzd2QsXFxuICAgICAgICAgICAgICAgICAgICB2ZXJpZnk6IGNvZFxcbiAgICAgICAgICAgICAgICB9LFxcbiAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJ1BPU1QnXFxuICAgICAgICAgICAgICAgICAgICB9KSk7XFxuICAgICAgICAgICAgICAgICAgICBpZiAoaHRtbC5jb2RlID09IDEpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBzZXRJdGVtKCdmbGNvb2snLCBjb2spO1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2sodHJ1ZSk7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXCJ0b2FzdDovL+mqjOivgeaIkOWKn+OAglxcXCJcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoaHRtbC5jb2RlID09IDEwMDMpICB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXCJ0b2FzdDovL+mqjOivgeWksei0pSzor7fovpPlhaXmraPnoa7otKblj7flr4bnoIFcXFwiXFxuICAgICAgICAgICAgICAgICAgICB9ZWxzZSBpZiAoaHRtbC5jb2RlID09IDEwMDIpICB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXCJ0b2FzdDovL+mqjOivgeWksei0pSzpqozor4HnoIHovpPlhaXmnInor69cXFwiXFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH0sIGNvayksXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAndGV4dF8yJ1xcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgIHNldFJlc3VsdChpdGVtcyk7XFxuICAgICAgICB9KSxcXG4gICAgICAgIGNvbF90eXBlOiAndGV4dF9jZW50ZXJfMSdcXG4gICAgfSk7X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ICAgICAgICAgICAgdmFyIHVybD0nYSdcXG4gICAgICAgICAgICAgIGlmKHgu6ZO+5o6lLmluY2x1ZGVzKCdAQCcpKXsgICAgICAgICAgICAgICAgICBcXG4gICAgICAgICAgICAgICAgICBzdGF0ZT14LumTvuaOpS5zcGxpdCgnQEAnKVswXVxcbiAgICAgICAgICAgICAgICAgIHZhbHVlPXBkZmgocSx4LumTvuaOpS5zcGxpdCgnQEAnKVsxXSk7XFxuICAgICAgICAgICAgICAgICAgaWYoeC7ovazmjaI9PXRydWUpe1xcbiAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gYDxsaSBkYXRhLXR5cGU9XFxcIiR7c3RhdGV9XFxcIiBkYXRhLXZhbD1cXFwiJHt2YWx1ZX1cXFwiPjxhIGhyZWY9XFxcIlxcXCI+JHt0aXRsZX08L2E+PC9saT5gXFxuICAgICAgICAgICAgICAgICAgfWVsc2V7XFxuICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBgPGEgdHlwZT1cXFwiQGV4dHJhXFxcIiBzdGF0ZT1cXFwiJHtzdGF0ZX1cXFwiIHZhbHVlPVxcXCIke3ZhbHVlfVxcXCI+JHt0aXRsZX08L2E+YDtcXG4gICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICB9ZWxzZXtcXG4gICAgICAgICAgICAgICAgICBocmVmPXBkKHEseC7pk77mjqUpO1xcbiAgICAgICAgICAgICAgICAgIHJldHVybiBgPGEgaHJlZj1cXFwiJHtocmVmfVxcXCI+JHt0aXRsZX08L2E+YDtcXG4gICAgICAgICAgICAgIH1cXG4gICAgICAgICAgfSk7XFxuICAgICAgICAgIHJldHVybiDlrprkvY07XFxuICAgICAgICB9KTtcXG4gICAgICAgY2F0ZWdvcmllcy5wdXNoKOS4gOe6py5qb2luKCdcXFxcbicpKTtcXG4gICAgICAgICAgICB9KTsgICAgICAgXFxuICAgIH1cXHJcXG59wqBlbHNlwqB7wqDCoMKgwqDCoFxcclxcbiAgICBjYXRlZ29yaWVz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MKgwqB1cmw6wqAkKCkubGF6eVJ1bGUoKGZvbGQsdSxhbGwpwqA9PsKge1xcclxcbsKgwqDCoMKgwqDCoMKgwqDCoMKgwqDCoHB1dE15VmFyKE1ZX1JVTEUuZ3JvdXAswqBmb2xkwqA9PT3CoCcxJ8KgP8KgJzAnwqA6wqAnMScpO1xcbiAgICAgICAgICAgIGFsbC5mb3JFYWNoKChpdGVtKT0+e1xcbiAgICAgICAgICAgICAgIGNsZWFyTXlWYXIoaXRlbSlcXG4gICAgICAgICAgICB9KVxcclxcbsKgwqDCoMKgwqDCoMKgwqDCoMKgwqDCoHJlZnJlc2hQYWdlKGZhbHNlKTtcXHJcXG7CoMKgwqDCoMKgwqDCoMKgwqDCoMKgwqByZXR1cm7CoFxcXCJoaWtlcjovL2VtcHR5XFxcIjtcXHJcXG7CoMKgwqDCoMKgwqDCoMKgfSzCoGZvbGQs54q25oCBICzlhajmuIUpLFxcclxcbsKgwqDCoMKgwqDCoMKgwqBjb2xfdHlwZTrCoCdzY3JvbGxfYnV0dG9uJyxcXG4gICAgICAgIGV4dHJhOntcXG4gICAgICAgICAgICBsb25nQ2xpY2s6W3tcXG4gICAgICAgICAgICAgICAgdGl0bGU6J+a4hemZpOeKtuaAgScsXFxuICAgICAgICAgICAgICAgIGpzOiQudG9TdHJpbmcoKHgsYWxsLGNsKT0+e1xcbiAgICAgICAgICAgICAgICAgICAgIGNsZWFyTXlWYXIoeCk7XFxuICAgICAgICAgICAgICAgICAgICAgY2xlYXJNeVZhcignaGVhZC5jYXRlJyk7ICAgICAgICAgICAgICAgICAgICAgXFxuICAgICAgICAgICAgICAgICAgICAgYWxsLmZvckVhY2goKGl0ZW0pPT57XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNsZWFyTXlWYXIoaXRlbSlcXG4gICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgIGNsLmZvckVhY2goKGl0ZW0pPT57XFxuICAgICAgICAgICAgICAgICAgICAg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J0BAQCcpOlxcbiAgICAgICAgICAgICAgICAgICAganNvbj17XFxuICAgICAgICAgICAgICAgICAgICB0eXBlOnBkZmgoaXRlbSzliIbnsbvpk77mjqUuc3BsaXQoJ0BAQCcpWzBdKSxcXG4gICAgICAgICAgICAgICAgICAgIHZhbHVlOnBkZmgoaXRlbSzliIbnsbvpk77mjqUuc3BsaXQoJ0BAQCcpWzFdKSxcXG4gICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgIGJyZWFrO1xcbiAgICAgICAgICAgICAgICAgICAgY2FzZSDliIbnsbvpk77mjqUuaW5jbHVkZXMoJ0BAJyk6XFxuICAgICAgICAgICAgICAgICAgICBqc29uPXtcXG4gICAgICAgICAgICAgICAgICAgIHR5cGU65YiG57G76ZO+5o6lLnNwbGl0KCdAQCcpWzBdLFxcbiAgICAgICAgICAgICAgICAgICAgdmFsdWU6cGRmaChpdGVtLOWIhuexu+mTvuaOpS5zcGxpdCgnQEAnKVsxXSksXFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICBicmVhaztcXG4gICAgICAgICAgICAgICAgICAgIGRlZmF1bHQ6XFxuICAgICAgICAgICAgICAgICAgICBqc29uPXBkKGl0ZW0s5YiG57G76ZO+5o6lKTtcXG4gICAgICAgICAgICAgICAgICAgIGJyZWFrO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgLyp2YXIganNvbj3liIbnsbvpk77mjqUuaW5jbHVkZXMoJ0BAQCcpP3tcXG4gICAgICAgICAgICAgICAgICAgIHR5cGU6cGRmaChpdGVtLOWIhuexu+mTvuaOpS5zcGxpdCgnQEBAJylbMF0pLFxcbiAgICAgICAgICAgICAgICAgICAgdmFsdWU6cGRmaChpdGVtLOWIhuexu+mTvuaOpS5zcGxpdCgnQEBAJylbMV0pLFxcbiAgICAgICAgICAgICAgICB9OnBkKGl0ZW0s5YiG57G76ZO+5o6lKTtcXG4gICAgICAgICAgICAgICA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