Advertisement
xiaomianao666

邀您一起看:大学物理实验刘国营

Mar 1st, 2023
133
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 海阔视界规则分享,当前分享的是:二级页面详情¥page_detail¥大学物理实验刘国营@@eyJkYXRhIjoie1wiYXNzb2NpYXRlZE1vZGVsc01hcEZvckpvaW5UYWJsZVwiOnt9LFwiYXNzb2NpYXRlZE1vZGVsc01hcFdpdGhGS1wiOnt9LFwiYXNzb2NpYXRlZE1vZGVsc01hcFdpdGhvdXRGS1wiOnt9LFwiZmllbGRzVG9TZXRUb0RlZmF1bHRcIjpbXSxcImdtdE1vZGlmaWVkXCI6MCxcImlkXCI6MCxcImxhc3RfY2hhcHRlcl9ydWxlXCI6XCJcIixcImxpc3RUb0NsZWFyQXNzb2NpYXRlZEZLXCI6W10sXCJsaXN0VG9DbGVhclNlbGZGS1wiOltdLFwicGFnZUxpc3RcIjpbe1wiY29sX3R5cGVcIjpcInRleHRfMVwiLFwibmFtZVwiOlwi5pCc57SiXCIsXCJwYXRoXCI6XCLmkJzntKJcIixcInJ1bGVcIjpcImpzOlxcbnZhciBkID0gW107XFxudHJ5IHtcXG4gICAgaWYgKE1ZX1BBR0UgPT0gMSkge1xcbiAgICAgICAgdmFyIGVuZ2luZXMgPSBbXFxcIuixhueTo1xcXCIsIFxcXCJZbGlicmFyeVxcXCIsIFxcXCJaaGVscGVyX3Y1XFxcIiwgXFxcIlpoZWxwZXJfdjRcXFwiLCBcXFwiTGliZ2VuXFxcIiwgXFxcIum4oOaRqVxcXCIsIFxcXCLml6DlkI3lm77kuaZcXFwiLCBcXFwi572R55uYXFxcIl1cXG4gICAgICAgIGVuZ2luZXMuZm9yRWFjaChpdGVtID0+IHtcXG4gICAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgICAgICB0aXRsZTogZ2V0SXRlbShcXFwiZW5naW5lXFxcIiwgXFxcIllsaWJyYXJ5XFxcIikgPT0gaXRlbSA/IGDigJjigJjigJnigJk8c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91YmFuLmNvbS9hcGkvdjIvYm9vay9cXFwiICsgaWQsIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBhcGlrZXk6IFxcXCIwZGFkNTUxZWMwZjg0ZWQwMjkwN2ZmNWM0MmU4ZWM3MFxcXCJcXG4gICAgICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KHUsIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBib2R5OiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGhvc3Q6IFxcXCJmcm9kby5kb3ViYW4uY29tXFxcIlxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sXFxuICAgICAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBcXFwiVXNlci1BZ2VudFxcXCI6IFxcXCJSZXh4YXItQ29yZS8wLjEuMyBhcGktY2xpZW50LzEgY29tLmRvdWJhbi5mcm9kby83LjkuMC5iZXRhMigyMTUpIEFuZHJvaWQvMjUgcHJvZHVjdC9UQVMtQUwwMCB2ZW5kb3IvSFVBV0VJIG1vZGVsL1RBUy1BTDAwICByb20vYW5kcm9pZCAgbmV0d29yay93aWZpICBwbGF0Zm9ybS9tb2JpbGUgY29tLmRvdWJhbi5mcm9kby83LjkuMC5iZXRhMigyMTUpIFJleHhhci8xLjIuMTUxICBwbGF0Zm9ybS9tb2JpbGUgMS4yLjE1MVxcXCJcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICB9KSlcXG4gICAgICAgICAgICAgICAgICAgIGQudW5zaGlmdCh7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdGl0bGU6IHJlcy50aXRsZSxcXG4gICAgICAgICAgICAgICAgICAgICAgICBpbWc6IHJlcy5waWMubm9ybWFsLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogXFxcIng1Oi8vXFxcIiArIHJlcy5pbmZvX3VybCxcXG4gICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiByZXMuY2FyZF9zdWJ0aXRsZSArIFxcXCJcXFxcblxcXCIgKyBzdGFyLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiBcXFwibW92aWVfMV92ZXJ0aWNhbF9waWNfYmx1clxcXCJcXG4gICAgICAgICAgICAgICAgICAgIH0sIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBjb2xfdHlwZTogXFxcImxpbmVfYmxhbmtcXFwiXFxuICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgdmFyIGludHJvID0gYOS9nOiAhe+8miR7cmVzLmF1dGhvci5qb2luKFxcXCIsXFxcIil9XFxcXG5cXFxcbue/u+ivke+8miR7cmVzLnRyYW5zbGF0b3Iuam9pbihcXFwiLFxcXCIpfVxcXFxuXFxcXG7nroDku4vvvJoke3Jlcy5pbnRyb31cXFxcblxcXFxu5L2c6ICF566A5LuL77yaJHtyZXMuYXV0aG9yX2ludHJvfVxcXFxuXFxcXG7mkZjlvZXvvJoke3Jlcy5jYXRhbG9nfWBcXG4gICAgICAgICAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdGl0bGU6IGludHJvLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiBcXFwibG9uZ190ZXh0XFxcIlxcbiAgICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgICAgIHNldFJlc3VsdChkKVxcbiAgICAgICAgICAgICAgICB9LCBpdGVtLmlkLCBzdGFyKVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICB9KVxcbiAgICB9LFxcbiAgICBZbGlicmFyeTogZnVuY3Rpb24oa3csIHBhZ2UpIHtcXG4gICAgICAgIHZhciByZXMgPSBKU09OLnBhcnNlKHBvc3QoXFxcImh0dHBzOi8vYXBpLnlsaWJyYXJ5Lm9yZy9hcGkvc2VhcmNoL1xcXCIsIHtcXG4gICAgICAgICAgICBib2R5OiBKU09OLnN0cmluZ2lmeSh7XFxuICAgICAgICAgICAgICAgIFxcXCJrZXl3b3JkXFxcIjoga3csXFxuICAgICAgICAgICAgICAgIFxcXCJwYWdlXFxcIjogcGFnZSxcXG4gICAgICAgICAgICAgICAgXFxcInNlbnNpdGl2ZVxcXCI6IGZhbHNlXFxuICAgICAgICAgICAgfSlcXG4gICAgICAgIH0pKS5kYXRhXFxuICAgICAgICByZXMuZm9yRWFjaChpdGVtID0+IHtcXG4gICAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgICAgICB0aXRsZTogaXRlbS50aXRsZSxcXG4gICAgICAgICAgICAgICAgZGVzYzogYOKAnOKAnOKAneKAnTxzbWFsbD7kvZzogIU6JHtpdGVtLmF1dGhvcn0g5Ye654mI56S+OiR7aXRlbS5wdWJsaXNoZXI/aXRlbS5wdWJsaXNoZXI6XFxcIuaaguaXoFxcXCJ9IElTQk46JHtpdGVtLmlzYm4/aXRlbS5pc2JuOlxcXCLmmoLml6BcXFwifSDlh7rniYjml7bpl7Q6JHtpdGVtLnllYXI/aXRlbS55ZWFyOlxcXCLmmoLml6BcXFwifSDmlofku7bmoLzlvI86JHtpdGVtLmV4dGVuc2lvbn0g5paH5Lu25aSn5bCPOiR7JC5yZXF1aXJlKFxcXCJhcGlcXFwiKS5nZXRGaWxlU2l6ZShpdGVtLmZpbGVzaXplKX08L3NtYWxsPmAsXFxuICAgICAgICAgICAgICAgIHVybDogJCgpLmxhenlSdWxlKChpZCkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgdHJ5IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KFxcXCJodHRwczovL2FwaS55bGlicmFyeS5vcmcvYXBpL2RldGFpbC9cXFwiLCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJvZHk6IEpTT04uc3RyaW5naWZ5KHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJpZFxcXCI6IGlkLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcInNvdXJjZVxcXCI6IFxcXCJ6bGlicmFyeVxcXCJcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KSlcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgc2VydmVycyA9ICQucmVxdWlyZShcXFwiaGlrZXI6Ly9wYWdlL2FwaVxcXCIpLnNlcnZlcnNcXG4gICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcImlwZnPkuIvovb1cXFwiKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlcnZlcnMudW5zaGlmdChcXFwi55m+5bqm5LqR55uY6L2s5a2YXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzLmluX2xpYmdlbikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcIkxpYmdlbijmjqjojZApXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICQoc2VydmVycywgMSwgXFxcIumAieaLqee6v+i3r1xcXCIpLnNlbGVjdCgocmVzKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpbnB1dCA9PSBcXFwiTGliZ2VuKOaOqOiNkClcXFwiKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcImRvd25sb2FkOi8vXFxcIiArIHBkZmgocmVxdWVzdChcXFwiaHR0cDovL2xpYnJhcnkubG9sL21haW4vXFxcIiArIHJlcy5tZDUpLCBcXFwiI2Rvd25sb2FkJiZhJiZocmVmXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpbnB1dCA9PSBcXFwi55m+5bqm5LqR55uY6L2s5a2YXFxcIikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICQucmVxdWlyZShcXFwiYXBpXFxcIikuYmFpZHUocmVzKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKGlucHV0ID09IFxcXCJpcGZz5LiL6L29XFxcIikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGB4NTovL2h0dHBzOi8vaXBmcy1jaGVja2VyLjFrYnRvb2wuY29tLyR7cmVzLmlwZnNfY2lkfWBcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpbnB1dC5pbmNsdWRlcyhcXFwiaXBmc2d3MDAuc3Rhcml2ZXJwYW4uY29tXFxcIikpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwiZG93bmxvYWQ6Ly9cXFwiICsgaW5wdXQgKyByZXMuaXBmc19jaWQgKyBcXFwiO3tSZWZlcmVyQGh0dHBzOi8vd3guc3Rhcml2ZXJwYW4uY29tL31cXFwiXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcImRvd25sb2FkOi8vXFxcIiArIGlucHV0ICsgcmVzLmlwZnNfY2lkXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgICAgICB9LCByZXMpXFxuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgbG9nKGUubWVzc2FnZSlcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcInRvYXN0Oi8v6Kej5p6Q5aSx6LSlXFxcIlxcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB9LC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AgICAgICAgICAgIHRyeSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlcyA9IEpTT04ucGFyc2UocG9zdChcXFwiaHR0cHM6Ly9hcGkudjUuemhlbHBlci5uZXQvYXBpL2RldGFpbC9cXFwiLCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJvZHk6IEpTT04uc3RyaW5naWZ5KHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJpZFxcXCI6IGlkLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcInNvdXJjZVxcXCI6IFxcXCJ6bGlicmFyeVxcXCJcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KSlcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgc2VydmVycyA9ICQucmVxdWlyZShcXFwiaGlrZXI6Ly9wYWdlL2FwaVxcXCIpLnNlcnZlcnNcXG4gICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcImlwZnPkuIvovb1cXFwiKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlcnZlcnMudW5zaGlmdChcXFwi55m+5bqm5LqR55uY6L2s5a2YXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzLmluX2xpYmdlbikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcIkxpYmdlbijmjqjojZApXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICQoc2VydmVycywgMSwgXFxcIumAieaLqee6v+i3r1xcXCIpLnNlbGVjdCgocmVzKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpbnB1dCA9PSBcXFwiTGliZ2VuKOaOqOiNkClcXFwiKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcImRvd25sb2FkOi8vXFxcIiArIHBkZmgocmVxdWVzdChcXFwiaHR0cDovL2xpYnJhcnkubG9sL21haW4vXFxcIiArIHJlcy5tZDUpLCBcXFwiI2Rvd25sb2FkJiZhJiZocmVmXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpbnB1dCA9PSBcXFwi55m+5bqm5LqR55uY6L2s5a2YXFxcIikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICQucmVxdWlyZShcXFwiYXBpXFxcIikuYmFpZHUocmVzKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKGlucHV0ID09IFxcXCJpcGZz5LiL6L29XFxcIikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGB4NTovL2h0dHBzOi8vaXBmcy1jaGVja2VyLjFrYnRvb2wuY29tLyR7cmVzLmlwZnNfY2lkfWBcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpbnB1dC5pbmNsdWRlcyhcXFwiaXBmc2d3MDAuc3Rhcml2ZXJwYW4uY29tXFxcIikpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwiZG93bmxvYWQ6Ly9cXFwiICsgaW5wdXQgKyByZXMuaXBmc19jaWQgKyBcXFwiO3tSZWZlcmVyQGh0dHBzOi8vd3guc3Rhcml2ZXJwYW4uY29tL31cXFwiXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcImRvd25sb2FkOi8vXFxcIiArIGlucHV0ICsgcmVzLmlwZnNfY2lkXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgICAgICB9LCByZXMpXFxuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgbG9nKGUubWVzc2FnZSlcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcInRvYXN0Oi8v6Kej5p6Q5aSx6LSlXFxcIlxcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB9LCBpdGVtLmlkKVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICB9KVxcbiAgICB9LFxcbiAgICBaaGVscGVyX3Y0OiBmdW5jdGlvbihrdywgcGFnZSkge1xcbiAgICAgICAgdmFyIHJlcyA9IEpTT04ucGFyc2UocG9zdChcXFwiaHR0cHM6Ly9hcGkubWlib29rcy50ay9hcGkvc2VhcmNoL1xcXCIsIHtcXG4gICAgICAgICAgICBib2R5OiBKU09OLnN0cmluZ2lmeSh7XFxuICAgICAgICAgICAgICAgIFxcXCJrZXl3b3JkXFxcIjoga3csXFxuICAgICAgICAgICAgICAgIFxcXCJwYWdlXFxcIjogcGFnZSxcXG4gICAgICAgICAgICAgICAgXFxcInNlbnNpdGl2ZVxcXCI6IGZhbHNlXFxuICAgICAgICAgICAgfSlcXG4gICAgICAgIH0pKS5kYXRhXFxuICAgICAgICByZXMuZm9yRWFjaChpdGVtID0+IHtcXG4gICAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgICAgICB0aXRsZTogaXRlbS50aXRsZSxcXG4gICAgICAgICAgICAgICAgZGVzYzogYOKAnOKAnOKAneKAnTxzbWFsbD7kvZzogIU6JHtpdGVtLmF1dGhvcn0g5Ye654mI56S+OiR7aXRlbS5wdWJsaXNoZXI/aXRlbS5wdWJsaXNoZXI6XFxcIuaaguaXoFxcXCJ9IElTQk46JHtpdGVtLmlzYm4/aXRlbS5pc2JuOlxcXCLmmoLml6BcXFwifSDlh7rniYjml7bpl7Q6JHtpdGVtLnllYXI/aXRlbS55ZWFyOlxcXCLmmoLml6BcXFwifSDmlofku7bmoLzlvI86JHtpdGVtLmV4dGVuc2lvbn0g5paH5Lu25aSn5bCPOiR7JC5yZXF1aXJlKFxcXCJhcGlcXFwiKS5nZXRGaWxlU2l6ZShpdGVtLmZpbGVzaXplKX08L3NtYWxsPmAsXFxuICAgICAgICAgICAgICAgIHVybDogJCgpLmxhenlSdWxlKChpZCkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgdHJ5IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgc2VydmVycyA9IFsnaHR0cHM6Ly90ZXN0MS56bGliLmRvd25sb2FkJywgJ2h0dHBzOi8vdGVzdDIuemxpYi5kb3dubG9hZCcsICdodHRwczovL3psaWIuamcxMjEyMy5vbmUnXVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAkKHNlcnZlcnMsIDEsIFxcXCLor7fpgInmi6nkuIvovb3nur/ot69cXFwiKS5zZWxlY3QoKGlkKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwiZG93bmxvYWQ6Ly9cXFwiICsgaW5wdXQgKyBcXFwiL2Rvd25sb2FkL1xcXCIgKyBpZCArIFxcXCIvXFxcIlxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sIGlkKVxcbiAgICAgICAgICAgICAgICAgICAgfSBjYXRjaCAoZSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGxvZyhlLm1lc3NhZ2UpXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXCJ0b2FzdDovL+ino+aekOWksei0pVxcXCJcXG4gICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgfSwgaXRlbS5pZClcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgfSlcXG4gICAgfSxcXG4gICAg6big5pGpOiBmdW5jdGlvbihrdykge1xcbiAgICAgICAgdmFyIGlkID0gSlNPTi5wYXJzZShwb3N0KFxcXCJodHRwczovL3d3dzUuaml1bW9kaWFyeS5jb20vaW5pdF9odWJzLnBocFxcXCIsIHtcXG4gICAgICAgICAgICBib2R5OiB7XFxuICAgICAgICAgICAgICAgIHE6IGt3LFxcbiAgICAgICAgICAgICAgICByZW1vdGVfaXA6IFxcXCJcXFwiLFxcbiAgICAgICAgICAgICAgICB0aW1lX2ludDogRGF0ZS5wYXJzZShuZXcgRGF0ZSgpKSArIFxcXCJcXFwiXFxuICAgICAgICAgICAgfVxcbiAgICAgICAgfSkpLmlkXFxuICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KFxcXCJodHRwczovL3d3dzUuaml1bW9kaWFyeS5jb20vYWpheF9mZXRjaF9odWJzLnBocFxcXCIsIHtcXG4gICAgICAgICAgICBib2R5OiB7XFxuICAgICAgICAgICAgICAgIGlkOiBpZCxcXG4gICAgICAgICAgICAgICAgc2V0OiAwXFxuICAgICAgICAgICAgfVxcbiAgICAgICAgfSkpLnNvdXJjZXNcXG4gICAgICAgIHJlcy5mb3JFYWNoKGl0ZW0gPT4ge1xcbiAgICAgICAgICAgIGl0ZW0uZGV0YWlscy5kYXRhLmZvckVhY2goaXRlbTIgPT4ge1xcbiAgICAgICAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgICAgICAgICAgdGl0bGU6IFxcXCLigJzigJzigJ3igJ1cXFwiICsgaXRlbTIudGl0bGUsXFxuICAgICAgICAgICAgICAgICAgICBkZXNjOiBcXFwi4oCc4oCc4oCd4oCdXFxcIiArIGl0ZW0yLmRlcyArIFxcXCJcXFxcblxcXCIgKyBpdGVtMi52X2RlcyxcXG4gICAgICAgICAgICAgICAgICAgIGltZzogXFxcImh0dHA6XFxcIiArIGl0ZW0yLmltZ19saW5rLFxcbiAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6IGl0ZW0yLmltZ19saW5rID8gXFxcIm1vdmllXzFfdmVydGljYWxfcGljXFxcIiA6IFxcXCJ0ZXh0XzFcXFwiLFxcbiAgICAgICAgICAgICAgICAgICAgdXJsOiBpdGVtMi5saW5rXFxuICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgfSlcXG4gICAgICAgIH0pXFxuICAgIH0sXFxuICAgIGNoZWNrTGliZ2VuOiBmdW5jdGlvbigpIHtcXG4gICAgICAgIHZhciBkb21haW5zID0gW1xcXCJodHRwOi8vbGliZ2VuLnJzXFxcIiwgXFxcImh0dHA6Ly9saWJnZW4uaXNcXFwiLCBcXFwiaHR0cDovL2xpYmdlbi5zdFxcXCJdXFxuICAgICAgICB0cnkge1xcbiAgICAgICAgICAgIGZvciAoaXRlbSBvZiBkb21haW5zKSB7XFxuICAgICAgICAgICAgICAgIHZhciBjb2RlID0gSlNPTi5wYXJzZShyZXF1ZXN0KGl0ZW0sIHtcXG4gICAgICAgICAgICAgICAgICAgIHdpdGhTdGF0dXNDb2RlOiB0cnVlXFxuICAgICAgICAgICAgICAgIH0pKS5zdGF0dXNDb2RlXFxuICAgICAgICAgICAgICAgIGlmIChjb2RlID09IDIwMCkge1xcbiAgICAgICAgICAgICAgICAgICAgc2V0SXRlbShcXFwibGliZ2VuXFxcIiwgaXRlbSlcXG4gICAgICAgICAgICAgICAgICAgIHRvYXN0KFxcXCLmo4DmtYvliLDlj6/nlKjplZzlg49cXFwiKVxcbiAgICAgICAgICAgICAgICAgICAgcmVmcmVzaFBhZ2UoKVxcbiAgICAgICAgICAgICAgICAgICAgYnJlYWtcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIH1cXG4gICAgICAgICAgICB0b2FzdChcXFwi5omA5pyJ6ZWc5YOP6YO95peg5rOV5L2/55So77yM6K+35omT5byAVFrkvb/nlKhcXFwiKVxcbiAgICAgICAgfSBjYXRjaCAoZSkge1xcbiAgICAgICAgICAgIGxvZyhlLm1lc3NhZ2UpXFxuICAgICAgICB9XFxuICAgIH0sXFxuICAgIExpYmdlbjogZnVuY3Rpb24oa3csIHBhZ2UpIHtcXG4gICAgICAgIGlmIChnZXRJdGVtKFxcXCJsaWJnZW5cXFwiLCBcXFwiXFxcIikgPT0gXFxcIlxcXCIpIHtcXG4gICAgICAgICAgICB0b2FzdChcXFwi5peg5Y+v55So6ZWc5YOP77yM5q2j5Zyo5qOA5rWL5LitLi4uXFxcIilcXG4gICAgICAgICAgICAkLnJlcXVpcmUoXFxcImFwaVxcXCIpLmNoZWNrTGliZ2VuKClcXG4gICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgdmFyIHVybCA9IGdldEl0ZW0oXFxcImxpYmdlblxcXCIpICsgXFxcIi9zZWFyY2gucGhwP3JlcT1cXFwiICsga3cgKyBcXFwiJnBhZ2U9XFxcIiArIHBhZ2VcXG4gICAgICAgICAgICB2YXIgciA9IEpTT04ucGFyc2UocmVxdWVzdCh1cmwsIHtcXG4gICAgICAgICAgICAgICAgd2l0aEhlYWRlcnM6IHRydWVcXG4gICAgICAgICAgICB9KSlcXG4gICAgICAgICAgICBpZiAoci5zdGF0dXNDb2RlID09IDIwMCkge1xcbiAgICAgICAgICAgICAgICB2YXIgcmVzID0gci5ib2R5XFxuICAgICAgICAgICAgICAgIHZhciBsaXN0ID0gcGRmYShyZXMsIFxcXCJib2R5JiZ0clxcXCIpLmZpbHRlcihpdGVtID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIGlmIChpdGVtLmluY2x1ZGVzKFxcXCJub3dyYXBcXFwiKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBpdGVtXFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgIGxpc3QuZm9yRWFjaChpdGVtID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHZhciBsaSA9IGl0ZW0ubWF0Y2gobmV3IFJlZ0V4cChcXFwiPHRkKC4qPyk8L3RkPlxcXCIsIFxcXCJnXFxcIikpXFxuICAgICAgICAgICAgICAgICAgICB2YXIgZGVzYyA9IFxcXCLigJzigJzigJ3igJ08c21hbGw+XFxcIiArIHBkZmgobGlbMV0sIFxcXCJhJiZUZXh0XFxcIilcXG4gICAgICAgICAgICAgICAgICAgIGZvciAobGV0IGkgPSAzOyBpIDwgbGkubGVuZ3RoIC0gMzsgaSsrKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgZGVzYyArPSBcXFwi77ybXFxcIiArIHBkZmgobGlbaV0sIFxcXCJUZXh0XFxcIilcXG4gICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgIGRlc2MgKz0gXFxcIjwvc21hbGw+XFxcIlxcbiAgICAgICAgICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogcGRmaChsaVsyXSwgXFxcIlRleHRcXFwiKSxcXG4gICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiBkZXNjLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJCgpLmxhenlSdWxlKChsaSkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcImRvd25sb2FkOi8vXFxcIiArIHBkZmgocmVxdWVzdChwZGZoKGxpWzldLCBcXFwiYSYmaHJlZlxcXCIpKSwgXFxcIiNkb3dubG9hZCYmYSYmaHJlZlxcXCIpXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSwgbGkpXFxuICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgIHRvYXN0KFxcXCLplZzlg4/lpLHmlYjvvIzph43mlrDmo4DmtYvkuK0uLi5cXFwiKVxcbiAgICAgICAgICAgICAgICAkLnJlcXVpcmUoXFxcImFwaVxcXCIpLmNoZWNrTGliZ2VuKClcXG4gICAgICAgICAgICB9XFxuICAgICAgICB9XFxuICAgIH0sXFxuICAgIOe9keebmDogZnVuY3Rpb24oa3csIHBhZ2UpIHtcXG4gICAgICAgIHZhciByZXMgPSBKU09OLnBhcnNlKHBvc3QoXFxcImh0dHBzOi8vYXBpLmJvb2twYW4ubmV0L2FwaS9zZWFyY2gvXFxcIiwge1xcbiAgICAgICAgICAgIGJvZHk6IEpTT04uc3RyaW5naWZ5KHtcXG4gICAgICAgICAgICAgICAgXFxcImtleXdvcmRcXFwiOiBrdyxcXG4gICAgICAgICAgICAgICAgXFxcInBhZ2VcXFwiOiBwYWdlLFxcbiAgICAgICAgICAgICAgICBcXFwic2Vuc2l0aXZlXFxcIjogZmFsc2VcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgfSkpLmRhdGFcXG4gICAgICAgIHJlcy5mb3JFYWNoKGl0ZW0gPT4ge1xcbiAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiBpdGVtLmluZm8sXFxuICAgICAgICAgICAgICAgIGRlc2M6IFxcXCLigJzigJzigJ3igJ08c21hbGw+XFxcIiArIGl0ZW0uc291cmNlICsgXFxcIjwvc21hbGw+XFxcIixcXG4gICAgICAgICAgICAgICAgdXJsOiAkKCkubGF6eVJ1bGUoKGlkLCBzb3VyY2UpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHRyeSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlcyA9IEpTT04ucGFyc2UocG9zdChcXFwiaHR0cHM6Ly9hcGkuYm9va3Bhbi5uZXQvYXBpL2RldGFpbC9cXFwiLCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJvZHk6IEpTT04uc3RyaW5naWZ5KHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJpZFxcXCI6IGlkLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcInNvdXJjZVxcXCI6IHNvdXJjZVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChyZXMuZG93bmxvYWRfbGluaykge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgZGljdCA9IHt9XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJlcy5kb3dubG9hZF9saW5rLnVuc2hpZnQoe1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbmFtZTogXFxcIuWOn+e9kemhtVxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IHJlcy51cmxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICQocmVzLmRvd25sb2FkX2xpbmsubWFwKGZ1bmN0aW9uKGl0ZW0pIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBpdGVtLm5hbWVcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSksIDEsIFxcXCLor7fpgInmi6nkuIvovb3nur/ot69cXFwiKS5zZWxlY3QoKGxpbmtzKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gbGlua3NbbGlua3MubWFwKGZ1bmN0aW9uKGl0ZW0pIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gaXRlbS5uYW1lXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KS5pbmRleE9mKGlucHV0KV0udXJsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0sIHJlcy5kb3dubG9hZF9saW5rKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiByZXMudXJsXFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgfSBjYXRjaCAoZSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIGxvZyhlLm1lc3NhZ2UpXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXCJ0b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ChyZXF1ZXN0KHVybCksIFxcXCIuZGV0YWlsX2Rvd25sb2FkX2J0bl9fdjdiN2smJmhyZWZcXFwiKVxcbiAgICAgICAgICAgICAgICB9LCBcXFwiaHR0cHM6Ly93d3cuYm9vazEyMy5pbmZvXFxcIiArIHBkZmgoaXRlbSwgXFxcImEmJmhyZWZcXFwiKSlcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgfSlcXG4gICAgfSxcXG4gICAgYmFpZHU6IGZ1bmN0aW9uKHJlcykge1xcbiAgICAgICAgdHJ5IHtcXG4gICAgICAgICAgICBpZiAoIWZpbGVFeGlzdChcXFwiaGlrZXI6Ly9maWxlcy9ydWxlcy9Kb2UvYmFpZHUudHh0XFxcIikpIHtcXG4gICAgICAgICAgICAgICAgdG9hc3QoXFxcIui/mOacqueZu+mZhlxcXCIpXFxuICAgICAgICAgICAgICAgIHJldHVybiAkKCkucnVsZSgoKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICBzZXRSZXN1bHQoW3tcXG4gICAgICAgICAgICAgICAgICAgICAgICB1cmw6IFxcXCJodHRwczovL3Bhbi5iYWlkdS5jb20vXFxcIixcXG4gICAgICAgICAgICAgICAgICAgICAgICBjb2xfdHlwZTogXFxcIng1X3dlYnZpZXdfc2luZ2xlXFxcIixcXG4gICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiBcXFwiMTAwJSYmZmxvYXRcXFwiLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGV4dHJhOiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGpzOiAkLnRvU3RyaW5nKCgpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciB1cmwgPSBsb2NhdGlvbi5ocmVmXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAodXJsLmluY2x1ZGVzKFxcXCJodHRwczovL3Bhbi5iYWlkdS5jb20vd2FwXFxcIikpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmYmEud3JpdGVGaWxlKFxcXCJoaWtlcjovL2ZpbGVzL3J1bGVzL0pvZS9iYWlkdS50eHRcXFwiLCBmYmEuZ2V0Q29va2llKFxcXCJcXFwiKSlcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBhbGVydChcXFwi5bey6I635Y+W5YiwY29va2ll77yM6L+U5Zue5Y2z5Y+vXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmYmEuYmFjaygpXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB1YTogTU9CSUxFX1VBLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBjYW5CYWNrOiB0cnVlXFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgfV0pXFxuICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgdmFyIGJkc3Rva2VuID0gSlNPTi5wYXJzZShyZXF1ZXN0KFxcXCJodHRwczovL3Bhbi5iYWlkdS5jb20vYXBpL2dldHRlbXBsYXRldmFyaWFibGU/ZmllbGRzPVslMjJiZHN0b2tlbiUyMl1cXFwiLCB7XFxuICAgICAgICAgICAgICAgICAgICBoZWFkZXJzOiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgQ29va2llOiByZXF1ZXN0KFxcXCJoaWtlcjovL2ZpbGVzL3J1bGVzL0pvZS9iYWlkdS50eHRcXFwiKVxcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB9KSkucmVzdWx0LmJkc3Rva2VuXFxuICAgICAgICAgICAgICAgIHJldHVybiAkKFxcXCIv55S15a2Q5LmmL1xcXCIgKyByZXMudGl0bGUgKyBcXFwiLlxcXCIgKyByZXMuZXh0ZW5zaW9uLCBcXFwi6K+36L6T5YWl5L+d5a2Y6Lev5b6EXFxcIikuaW5wdXQoKGJkc3Rva2VuLCByZXMpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHZhciByZXMgPSBKU09OLnBhcnNlKHBvc3QoXFxcImh0dHBzOi8vcGFuLmJhaWR1LmNvbS9yZXN0LzIuMC94cGFuL2ZpbGU/bWV0aG9kPWNyZWF0ZSZiZHN0b2tlbj1cXFwiICsgYmRzdG9rZW4sIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBoZWFkZXJzOiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIENvb2tpZTogcmVxdWVzdChcXFwiaGlrZXI6Ly9maWxlcy9ydWxlcy9Kb2UvYmFpZHUudHh0XFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICB9LFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvZHk6IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2l6ZTogcmVzLmZpbGVzaXplICsgXFxcIlxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBhdGg6IGlucHV0LFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBibG9ja19saXN0OiBbcmVzLm1kNV0sXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJ0eXBlOiAwXFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgfSkpXFxuICAgICAgICAgICAgICAgICAgICBpZiAocmVzLmVycm5vID09IDApIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcInRvYXN0Oi8v6L2s5a2Y5oiQ5YqfXFxcIlxcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChyZXMuZXJybm8gPT0gLTgpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcInRvYXN0Oi8v6L2s5a2Y5aSx6LSl77yM5bey57uP5L+d5a2Y6L+H6L+Z5Li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WM3MFxcXFxcXFwiXFxcXG4gICAgICAgICAgICAgICAgICAgIH0pXFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciByZXMgPSBKU09OLnBhcnNlKHBvc3QodSwge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgYm9keToge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGhvc3Q6IFxcXFxcXFwiZnJvZG8uZG91YmFuLmNvbVxcXFxcXFwiXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9LFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXFxcXFwiVXNlci1BZ2VudFxcXFxcXFwiOiBcXFxcXFxcIlJleHhhci1Db3JlLzAuMS4zIGFwaS1jbGllbnQvMSBjb20uZG91YmFuLmZyb2RvLzcuOS4wLmJldGEyKDIxNSkgQW5kcm9pZC8yNSBwcm9kdWN0L1RBUy1BTDAwIHZlbmRvci9IVUFXRUkgbW9kZWwvVEFTLUFMMDAgIHJvbS9hbmRyb2lkICBuZXR3b3JrL3dpZmkgIHBsYXRmb3JtL21vYmlsZSBjb20uZG91YmFuLmZyb2RvLzcuOS4wLmJldGEyKDIxNSkgUmV4eGFyLzEuMi4xNTEgIHBsYXRmb3JtL21vYmlsZSAxLjIuMTUxXFxcXFxcXCJcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgfSkpXFxcXG4gICAgICAgICAgICAgICAgICAgIGQudW5zaGlmdCh7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogcmVzLnRpdGxlLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgaW1nOiByZXMucGljLm5vcm1hbCxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogXFxcXFxcXCJ4NTovL1xcXFxcXFwiICsgcmVzLmluZm9fdXJsLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgZGVzYzogcmVzLmNhcmRfc3VidGl0bGUgKyBcXFxcXFxcIlxcXFxcXFxcblxcXFxcXFwiICsgc3RhcixcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiBcXFxcXFxcIm1vdmllXzFfdmVydGljYWxfcGljX2JsdXJcXFxcXFxcIlxcXFxuICAgICAgICAgICAgICAgICAgICB9LCB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBjb2xfdHlwZTogXFxcXFxcXCJsaW5lX2JsYW5rXFxcXFxcXCJcXFxcbiAgICAgICAgICAgICAgICAgICAgfSlcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIGludHJvID0gYOS9nOiAhe+8miR7cmVzLmF1dGhvci5qb2luKFxcXFxcXFwiLFxcXFxcXFwiKX1cXFxcXFxcXG5cXFxcXFxcXG7nv7vor5HvvJoke3Jlcy50cmFuc2xhdG9yLmpvaW4oXFxcXFxcXCIsXFxcXFxcXCIpfVxcXFxcXFxcblxcXFxcXFxcbueugOS7i++8miR7cmVzLmludHJvfVxcXFxcXFxcblxcXFxcXFxcbuS9nOiAheeugOS7i++8miR7cmVzLmF1dGhvcl9pbnRyb31cXFxcXFxcXG5cXFxcXFxcXG7mkZjlvZXvvJoke3Jlcy5jYXRhbG9nfWBcXFxcbiAgICAgICAgICAgICAgICAgICAgZC5wdXNoKHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHRpdGxlOiBpbnRybyxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiBcXFxcXFxcImxvbmdfdGV4dFxcXFxcXFwiXFxcXG4gICAgICAgICAgICAgICAgICAgIH0pXFxcXG4gICAgICAgICAgICAgICAgICAgIHNldFJlc3VsdChkKVxcXFxuICAgICAgICAgICAgICAgIH0sIGl0ZW0uaWQsIHN0YXIpXFxcXG4gICAgICAgICAgICB9KVxcXFxuICAgICAgICB9KVxcXFxuICAgIH0sXFxcXG4gICAgWWxpYnJhcnk6IG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bGUoKGlkKSA9PiB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHRyeSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KFxcXFxcXFwiaHR0cHM6Ly9hcGkueWxpYnJhcnkub3JnL2FwaS9kZXRhaWwvXFxcXFxcXCIsIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBib2R5OiBKU09OLnN0cmluZ2lmeSh7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXFxcXFwiaWRcXFxcXFxcIjogaWQsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXFxcXFwic291cmNlXFxcXFxcXCI6IFxcXFxcXFwiemxpYnJhcnlcXFxcXFxcIlxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KSlcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciBzZXJ2ZXJzID0gJC5yZXF1aXJlKFxcXFxcXFwiaGlrZXI6Ly9wYWdlL2FwaVxcXFxcXFwiKS5zZXJ2ZXJzXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcXFxcXCJpcGZz5LiL6L29XFxcXFxcXCIpXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcXFxcXCLnmb7luqbkupHnm5jovazlrZhcXFxcXFxcIilcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChyZXMuaW5fbGliZ2VuKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VydmVycy51bnNoaWZ0KFxcXFxcXFwiTGliZ2VuKOaOqOiNkClcXFxcXFxcIilcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAkKHNlcnZlcnMsIDEsIFxcXFxcXFwi6YCJ5oup57q/6LevXFxcXFxcXCIpLnNlbGVjdCgocmVzKSA9PiB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGlucHV0ID09IFxcXFxcXFwiTGliZ2VuKOaOqOiNkClcXFxcXFxcIikge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcXFxcXCJkb3dubG9hZDovL1xcXFxcXFwiICsgcGRmaChyZXF1ZXN0KFxcXFxcXFwiaHR0cDovL2xpYnJhcnkubG9sL21haW4vXFxcXFxcXCIgKyByZXMubWQ1KSwgXFxcXFxcXCIjZG93bmxvYWQmJmEmJmhyZWZcXFxcXFxcIilcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKGlucHV0ID09IFxcXFxcXFwi55m+5bqm5LqR55uY6L2s5a2YXFxcXFxcXCIpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICQucmVxdWlyZShcXFxcXFxcImFwaVxcXFxcXFwiKS5iYWlkdShyZXMpXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpbnB1dCA9PSBcXFxcXFxcImlwZnPkuIvovb1cXFxcXFxcIikge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gYHg1Oi8vaHR0cHM6Ly9pcGZzLWNoZWNrZXIuMWtidG9vbC5jb20vJHtyZXMuaXBmc19jaWR9YFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoaW5wdXQuaW5jbHVkZXMoXFxcXFxcXCJpcGZzZ3cwMC5zdGFyaXZlcnBhbi5jb21cXFxcXFxcIikpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXFxcXFwiZG93bmxvYWQ6Ly9cXFxcXFxcIiArIGlucHV0ICsgcmVzLmlwZnNfY2lkICsgXFxcXFxcXCI7e1JlZmVyZXJAaHR0cHM6Ly93eC5zdGFyaXZlcnBhbi5jb20vfVxcXFxcXFwiXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXFxcXFwiZG93bmxvYWQ6Ly9cXFxcXFxcIiArIGlucHV0ICsgcmVzLmlwZnNfY2lkXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSwgcmVzKVxcXFxuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBsb2coZS5tZXNzYWdlKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXFxcXFwidG9hc3Q6Ly/op6PmnpDlpLHotKVcXFxcXFxcIlxcXFxuICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgfSwgaXRlbS5pZClcXFxcbiAgICAgICAgICAgIH0pXFxcXG4gICAgICAgIH0pXFxcXG4gICAgfSxcXFxcbiAgICBaaGVscGVyX3Y1OiBmdW5jdGlvbihrdywgcGFnZSkge1xcXFxuICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KFxcXFxcXFwiaHR0cHM6Ly9hcGkudjUuemhlbHBlci5uZXQvYXBpL3NlYXJjaC9cXFxcXFxcIiwge1xcXFxuICAgICAgICAgICAgYm9keTogSlNPTi5zdHJpbmdpZnkoe1xcXFxuICAgICAgICAgICAgICAgIFxcXFxcXFwia2V5d29yZFxcXFxcXFwiOiBrdyxcXFxcbiAgICAgICAgICAgICAgICBcXFxcXFxcInBhZ2VcXFxcXFxcIjogcGFnZSxcXFxcbiAgICAgICAgICAgICAgICBcXFxcXFxcInNlbnNpdGl2ZVxcXFxcXFwiOiBmYWxzZVxcXFxuICAgICAgICAgICAgfSlcXFxcbiAgICAgICAgfSkpLmRhdGFcXFxcbiAgICAgICAgcmVzLmZvckVhY2goaXRlbSA9PiB7XFxcXG4gICAgICAgICAgICBkLnB1c2goe1xcXFxuICAgICAgICAgICAgICAgIHRpdGxlOiBpdGVtLnRpdGxlLFxcXFxuICAgICAgICAgICAgICAgIGRlc2M6IGDigJzigJzigJ3igJ08c21hbGw+5L2c6ICFOiR7aXRlbS5hdXRob3J9IOWHuueJiOekvjoke2l0ZW0ucHVibGlzaGVyP2l0ZW0ucHVibGlzaGVyOlxcXFxcXFwi5pqC5pegXFxcXFxcXCJ9IElTQk46JHtpdGVtLmlzYm4/aXRlbS5pc2JuOlxcXFxcXFwi5pqC5pegXFxcXFxcXCJ9IOWHuueJiOaXtumXtDoke2l0ZW0ueWVhcj9pdGVtLnllYXI6XFxcXFxcXCLmmoLml6BcXFxcXFxcIn0g5paH5Lu25qC85byPOiR7aXRlbS5leHRlbnNpb259IOaWh+S7tuWkp+WwjzokeyQucmVxdWlyZShcXFxcXFxcImFwaVxcXFxcXFwiKS5nZXRGaWxlU2l6ZShpdGVtLmZpbGVzaXplKX08L3NtYWxsPmAsXFxcXG4gICAgICAgICAgICAgICAgdXJsOiAkKCkubGF6eVJ1bGUoKGlkKSA9PiB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHRyeSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KFxcXFxcXFwiaHR0cHM6Ly9hcGkudjUuemhlbHBlci5uZXQvYXBpL2RldGFpbC9cXFxcXFxcIiwge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJvZHk6IEpTT04uc3RyaW5naWZ5KHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcXFxcXCJpZFxcXFxcXFwiOiBpZCxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcXFxcXCJzb3VyY2VcXFxcXFxcIjogXFxcXFxcXCJ6bGlicmFyeVxcXFxcXFwiXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSlcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHNlcnZlcnMgPSAkLnJlcXVpcmUoXFxcXFxcXCJoaWtlcjovL3BhZ2UvYXBpXFxcXFxcXCIpLnNlcnZlcnNcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlcnZlcnMudW5zaGlmdChcXFxcXFxcImlwZnPkuIvovb1cXFxcXFxcIilcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlcnZlcnMudW5zaGlmdChcXFxcXFxcIueZvuW6puS6keebmOi9rOWtmFxcXFxcXFwiKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHJlcy5pbl9saWJnZW4pIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcXFxcXCJMaWJnZW4o5o6o6I2QKVxcXFxcXFwiKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICQoc2VydmVycywgMSwgXFxcXFxcXCLpgInmi6nnur/ot69cXFxcXFxcIikuc2VsZWN0KChyZXMpID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoaW5wdXQgPT0gXFxcXFxcXCJMaWJnZW4o5o6o6I2QKVxcXFxcXFwiKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFxcXFxcImRvd25sb2FkOi8vXFxcXFxcXCIgKyBwZGZoKHJlcXVlc3QoXFxcXFxcXCJodHRwOi8vbGlicmFyeS5sb2wvbWFpbi9cXFxcXFxcIiArIHJlcy5tZDUpLCBcXFxcXFxcIiNkb3dubG9hZCYmYSYmaHJlZlxcXFxcXFwiKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoaW5wdXQgPT0gXFxcXFxcXCLnmb7luqbkupHnm5jovazlrZhcXFxcXFxcIikge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gJC5yZXF1aXJlKFxcXFxcXFwiYXBpXFxcXFxcXCIpLmJhaWR1KHJlcylcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKGlucHV0ID09IFxcXFxcXFwiaXBmc+S4i+i9vVxcXFxcXFwiKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBgeDU6Ly9odHRwczovL2lwZnMtY2hlY2tlci4xa2J0b29sLmNvbS8ke3Jlcy5pcGZzX2NpZH1gXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpbnB1dC5pbmNsdWRlcyhcXFxcXFxcImlwZnNndzAwLnN0YXJpdmVycGFuLmNvbVxcXFxcXFwiKSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcXFxcXCJkb3dubG9hZDovL1xcXFxcXFwiICsgaW5wdXQgKyByZXMuaXBmc19jaWQgKyBcXFxcXFxcIjt7UmVmZXJlckBodHRwczovL3d4LnN0YXJpdmVycGFuLmNvbS99XFxcXFxcXCJcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcXFxcXCJkb3dubG9hZDovL1xcXFxcXFwiICsgaW5wdXQgKyByZXMuaXBmc19jaWRcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9LCByZXMpXFxcXG4gICAgICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHtcXFxcbiAgICAgICAgICAgICAgICAgICA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cXFwifSDlh7rniYjml7bpl7Q6JHtpdGVtLnllYXI/aXRlbS55ZWFyOlxcXFxcXFwi5pqC5pegXFxcXFxcXCJ9IOaWh+S7tuagvOW8jzoke2l0ZW0uZXh0ZW5zaW9ufSDmlofku7blpKflsI86JHskLnJlcXVpcmUoXFxcXFxcXCJhcGlcXFxcXFxcIikuZ2V0RmlsZVNpemUoaXRlbS5maWxlc2l6ZSl9PC9zbWFsbD5gLFxcXFxuICAgICAgICAgICAgICAgIHVybDogJCgpLmxhenlSdWxlKChpZCkgPT4ge1xcXFxuICAgICAgICAgICAgICAgICAgICB0cnkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHNlcnZlcnMgPSBbJ2h0dHBzOi8vdGVzdDEuemxpYi5kb3dubG9hZCcsICdodHRwczovL3Rlc3QyLnpsaWIuZG93bmxvYWQnLCAnaHR0cHM6Ly96bGliLmpnMTIxMjMub25lJ11cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAkKHNlcnZlcnMsIDEsIFxcXFxcXFwi6K+36YCJ5oup5LiL6L2957q/6LevXFxcXFxcXCIpLnNlbGVjdCgoaWQpID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcXFxcXCJkb3dubG9hZDovL1xcXFxcXFwiICsgaW5wdXQgKyBcXFxcXFxcIi9kb3dubG9hZC9cXFxcXFxcIiArIGlkICsgXFxcXFxcXCIvXFxcXFxcXCJcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sIGlkKVxcXFxuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBsb2coZS5tZXNzYWdlKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXFxcXFwidG9hc3Q6Ly/op6PmnpDlpLHotKVcXFxcXFxcIlxcXFxuICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgfSwgaXRlbS5pZClcXFxcbiAgICAgICAgICAgIH0pXFxcXG4gICAgICAgIH0pXFxcXG4gICAgfSxcXFxcbiAgICDpuKDmkak6IGZ1bmN0aW9uKGt3KSB7XFxcXG4gICAgICAgIHZhciBpZCA9IEpTT04ucGFyc2UocG9zdChcXFxcXFxcImh0dHBzOi8vd3d3NS5qaXVtb2RpYXJ5LmNvbS9pbml0X2h1YnMucGhwXFxcXFxcXCIsIHtcXFxcbiAgICAgICAgICAgIGJvZHk6IHtcXFxcbiAgICAgICAgICAgICAgICBxOiBrdyxcXFxcbiAgICAgICAgICAgICAgICByZW1vdGVfaXA6IFxcXFxcXFwiXFxcXFxcXCIsXFxcXG4gICAgICAgICAgICAgICAgdGltZV9pbnQ6IERhdGUucGFyc2UobmV3IERhdGUoKSkgKyBcXFxcXFxcIlxcXFxcXFwiXFxcXG4gICAgICAgICAgICB9XFxcXG4gICAgICAgIH0pKS5pZFxcXFxuICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KFxcXFxcXFwiaHR0cHM6Ly93d3c1LmppdW1vZGlhcnkuY29tL2FqYXhfZmV0Y2hfaHVicy5waHBcXFxcXFxcIiwge1xcXFxuICAgICAgICAgICAgYm9keToge1xcXFxuICAgICAgICAgICAgICAgIGlkOiBpZCxcXFxcbiAgICAgICAgICAgICAgICBzZXQ6IDBcXFxcbiAgICAgICAgICAgIH1cXFxcbiAgICAgICAgfSkpLnNvdXJjZXNcXFxcbiAgICAgICAgcmVzLmZvckVhY2goaXRlbSA9PiB7XFxcXG4gICAgICAgICAgICBpdGVtLmRldGFpbHMuZGF0YS5mb3JFYWNoKGl0ZW0yID0+IHtcXFxcbiAgICAgICAgICAgICAgICBkLnB1c2goe1xcXFxuICAgICAgICAgICAgICAgICAgICB0aXRsZTogXFxcXFxcXCLigJzigJzigJ3igJ1cXFxcXFxcIiArIGl0ZW0yLnRpdGxlLFxcXFxuICAgICAgICAgICAgICAgICAgICBkZXNjOiBcXFxc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1ZVxcXFxuICAgICAgICAgICAgfSkpXFxcXG4gICAgICAgICAgICBpZiAoci5zdGF0dXNDb2RlID09IDIwMCkge1xcXFxuICAgICAgICAgICAgICAgIHZhciByZXMgPSByLmJvZHlcXFxcbiAgICAgICAgICAgICAgICB2YXIgbGlzdCA9IHBkZmEocmVzLCBcXFxcXFxcImJvZHkmJnRyXFxcXFxcXCIpLmZpbHRlcihpdGVtID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgaWYgKGl0ZW0uaW5jbHVkZXMoXFxcXFxcXCJub3dyYXBcXFxcXFxcIikpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBpdGVtXFxcXG4gICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICB9KVxcXFxuICAgICAgICAgICAgICAgIGxpc3QuZm9yRWFjaChpdGVtID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgdmFyIGxpID0gaXRlbS5tYXRjaChuZXcgUmVnRXhwKFxcXFxcXFwiPHRkKC4qPyk8L3RkPlxcXFxcXFwiLCBcXFxcXFxcImdcXFxcXFxcIikpXFxcXG4gICAgICAgICAgICAgICAgICAgIHZhciBkZXNjID0gXFxcXFxcXCLigJzigJzigJ3igJ08c21hbGw+XFxcXFxcXCIgKyBwZGZoKGxpWzFdLCBcXFxcXFxcImEmJlRleHRcXFxcXFxcIilcXFxcbiAgICAgICAgICAgICAgICAgICAgZm9yIChsZXQgaSA9IDM7IGkgPCBsaS5sZW5ndGggLSAzOyBpKyspIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGRlc2MgKz0gXFxcXFxcXCLvvJtcXFxcXFxcIiArIHBkZmgobGlbaV0sIFxcXFxcXFwiVGV4dFxcXFxcXFwiKVxcXFxuICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgIGRlc2MgKz0gXFxcXFxcXCI8L3NtYWxsPlxcXFxcXFwiXFxcXG4gICAgICAgICAgICAgICAgICAgIGQucHVzaCh7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogcGRmaChsaVsyXSwgXFxcXFxcXCJUZXh0XFxcXFxcXCIpLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgZGVzYzogZGVzYyxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogJCgpLmxhenlSdWxlKChsaSkgPT4ge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFxcXFxcImRvd25sb2FkOi8vXFxcXFxcXCIgKyBwZGZoKHJlcXVlc3QocGRmaChsaVs5XSwgXFxcXFxcXCJhJiZocmVmXFxcXFxcXCIpKSwgXFxcXFxcXCIjZG93bmxvYWQmJmEmJmhyZWZcXFxcXFxcIilcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sIGxpKVxcXFxuICAgICAgICAgICAgICAgICAgICB9KVxcXFxuICAgICAgICAgICAgICAgIH0pXFxcXG4gICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgIHRvYXN0KFxcXFxcXFwi6ZWc5YOP5aSx5pWI77yM6YeN5paw5qOA5rWL5LitLi4uXFxcXFxcXCIpXFxcXG4gICAgICAgICAgICAgICAgJC5yZXF1aXJlKFxcXFxcXFwiYXBpXFxcXFxcXCIpLmNoZWNrTGliZ2VuKClcXFxcbiAgICAgICAgICAgIH1cXFxcbiAgICAgICAgfVxcXFxuICAgIH0sXFxcXG4gICAg572R55uYOiBmdW5jdGlvbihrdywgcGFnZSkge1xcXFxuICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KFxcXFxcXFwiaHR0cHM6Ly9hcGkuYm9va3Bhbi5uZXQvYXBpL3NlYXJjaC9cXFxcXFxcIiwge1xcXFxuICAgICAgICAgICAgYm9keTogSlNPTi5zdHJpbmdpZnkoe1xcXFxuICAgICAgICAgICAgICAgIFxcXFxcXFwia2V5d29yZFxcXFxcXFwiOiBrdyxcXFxcbiAgICAgICAgICAgICAgICBcXFxcXFxcInBhZ2VcXFxcXFxcIjogcGFnZSxcXFxcbiAgICAgICAgICAgICAgICBcXFxcXFxcInNlbnNpdGl2ZVxcXFxcXFwiOiBmYWxzZVxcXFxuICAgICAgICAgICAgfSlcXFxcbiAgICAgICAgfSkpLmRhdGFcXFxcbiAgICAgICAgcmVzLmZvckVhY2goaXRlbSA9PiB7XFxcXG4gICAgICAgICAgICBkLnB1c2goe1xcXFxuICAgICAgICAgICAgICAgIHRpdGxlOiBpdGVtLmluZm8sXFxcXG4gICAgICAgICAgICAgICAgZGVzYzogXFxcXFxcXCLigJzigJzigJ3igJ08c21hbGw+XFxcXFxcXCIgKyBpdGVtLnNvdXJjZSArIFxcXFxcXFwiPC9zbWFsbD5cXFxcXFxcIixcXFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoKS5sYXp5UnVsZSgoaWQsIHNvdXJjZSkgPT4ge1xcXFxuICAgICAgICAgICAgICAgICAgICB0cnkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlcyA9IEpTT04ucGFyc2UocG9zdChcXFxcXFxcImh0dHBzOi8vYXBpLmJvb2twYW4ubmV0L2FwaS9kZXRhaWwvXFxcXFxcXCIsIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBib2R5OiBKU09OLnN0cmluZ2lmeSh7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXFxcXFwiaWRcXFxcXFxcIjogaWQsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXFxcXFwic291cmNlXFxcXFxcXCI6IHNvdXJjZVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KSlcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChyZXMuZG93bmxvYWRfbGluaykge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhciBkaWN0ID0ge31cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXMuZG93bmxvYWRfbGluay51bnNoaWZ0KHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbmFtZTogXFxcXFxcXCLljp/nvZHpobVcXFxcXFxcIixcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiByZXMudXJsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSlcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gJChyZXMuZG93bmxvYWRfbGluay5tYXAoZnVuY3Rpb24oaXRlbSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gaXRlbS5uYW1lXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSksIDEsIFxcXFxcXFwi6K+36YCJ5oup5LiL6L2957q/6LevXFxcXFxcXCIpLnNlbGVjdCgobGlua3MpID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGxpbmtzW2xpbmtzLm1hcChmdW5jdGlvbihpdGVtKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gaXRlbS5uYW1lXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pLmluZGV4T2YoaW5wdXQpXS51cmxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LCByZXMuZG93bmxvYWRfbGluaylcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJlcy51cmxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgfSBjYXRjaCAoZSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgbG9nKGUubWVzc2FnZSlcXFxcbiAgICAgICAgICAg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SwgXFxcXFxcXCIubGlzdF9kZXNjX19rSmoxWSYmVGV4dFxcXFxcXFwiKSArIFxcXFxcXFwiPC9zbWFsbD5cXFxcXFxcIixcXFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoKS5sYXp5UnVsZSgodXJsKSA9PiB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFxcXFxcImRvd25sb2FkOi8vXFxcXFxcXCIgKyBwZGZoKHJlcXVlc3QodXJsKSwgXFxcXFxcXCIuZGV0YWlsX2Rvd25sb2FkX2J0bl9fdjdiN2smJmhyZWZcXFxcXFxcIilcXFxcbiAgICAgICAgICAgICAgICB9LCBcXFxcXFxcImh0dHBzOi8vd3d3LmJvb2sxMjMuaW5mb1xcXFxcXFwiICsgcGRmaChpdGVtLCBcXFxcXFxcImEmJmhyZWZcXFxcXFxcIikpXFxcXG4gICAgICAgICAgICB9KVxcXFxuICAgICAgICB9KVxcXFxuICAgIH0sXFxcXG4gICAgYmFpZHU6IGZ1bmN0aW9uKHJlcykge1xcXFxuICAgICAgICB0cnkge1xcXFxuICAgICAgICAgICAgaWYgKCFmaWxlRXhpc3QoXFxcXFxcXCJoaWtlcjovL2ZpbGVzL3J1bGVzL0pvZS9iYWlkdS50eHRcXFxcXFxcIikpIHtcXFxcbiAgICAgICAgICAgICAgICB0b2FzdChcXFxcXFxcIui/mOacqueZu+mZhlxcXFxcXFwiKVxcXFxuICAgICAgICAgICAgICAgIHJldHVybiAkKCkucnVsZSgoKSA9PiB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHNldFJlc3VsdChbe1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiBcXFxcXFxcImh0dHBzOi8vcGFuLmJhaWR1LmNvbS9cXFxcXFxcIixcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiBcXFxcXFxcIng1X3dlYnZpZXdfc2luZ2xlXFxcXFxcXCIsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBkZXNjOiBcXFxcXFxcIjEwMCUmJmZsb2F0XFxcXFxcXCIsXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBleHRyYToge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGpzOiAkLnRvU3RyaW5nKCgpID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHVybCA9IGxvY2F0aW9uLmhyZWZcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHVybC5pbmNsdWRlcyhcXFxcXFxcImh0dHBzOi8vcGFuLmJhaWR1LmNvbS93YXBcXFxcXFxcIikpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGZiYS53cml0ZUZpbGUoXFxcXFxcXCJoaWtlcjovL2ZpbGVzL3J1bGVzL0pvZS9iYWlkdS50eHRcXFxcXFxcIiwgZmJhLmdldENvb2tpZShcXFxcXFxcIlxcXFxcXFwiKSlcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGFsZXJ0KFxcXFxcXFwi5bey6I635Y+W5YiwY29va2ll77yM6L+U5Zue5Y2z5Y+vXFxcXFxcXCIpXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmYmEuYmFjaygpXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KSxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB1YTogTU9CSUxFX1VBLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNhbkJhY2s6IHRydWVcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgfV0pXFxcXG4gICAgICAgICAgICAgICAgfSlcXFxcbiAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgdmFyIGJkc3Rva2VuID0gSlNPTi5w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AgICAgICAgICAgICAgICAgICAgc2l6ZTogcmVzLmZpbGVzaXplICsgXFxcXFxcXCJcXFxcXFxcIixcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYXRoOiBpbnB1dCxcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBibG9ja19saXN0OiBbcmVzLm1kNV0sXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcnR5cGU6IDBcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgfSkpXFxcXG4gICAgICAgICAgICAgICAgICAgIGlmIChyZXMuZXJybm8gPT0gMCkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXFxcXFwidG9hc3Q6Ly/ovazlrZjmiJDlip9cXFxcXFxcIlxcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKHJlcy5lcnJubyA9PSAtOCkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXFxcXFwidG9hc3Q6Ly/ovazlrZjlpLHotKXvvIzlt7Lnu4/kv53lrZjov4fov5nkuKrmlofku7bkuoZcXFxcXFxcIlxcXFxuICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKHJlcy5lcnJubyA9PSAyKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcXFxcXCJ0b2FzdDovL+i9rOWtmOWksei0pe+8jOmUmeivr+eahOi3r+W+hFxcXFxcXFwiXFxcXG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBsb2cocmVzLmVycm5vKVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXFxcXFwidG9hc3Q6Ly/ovazlrZjlpLHotKVcXFxcXFxcIlxcXFxuICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgfSwgYmRzdG9r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ZTogZnVuY3Rpb24oc2l6ZSkge1xcXFxuICAgICAgICBpZiAoc2l6ZSA8PSAwKSB7XFxcXG4gICAgICAgICAgICByZXR1cm4gXFxcXFxcXCJcXFxcXFxcIjtcXFxcbiAgICAgICAgfVxcXFxuICAgICAgICBsZXQgdW5pdEZvcm0gPSBbXFxcXFxcXCJCeXRlXFxcXFxcXCIsIFxcXFxcXFwiS0JcXFxcXFxcIiwgXFxcXFxcXCJNQlxcXFxcXFwiLCBcXFxcXFxcIkdCXFxcXFxcXCIsIFxcXFxcXFwiVEJcXFxcXFxcIl07XFxcXG4gICAgICAgIGZvciAobGV0IGkgPSAwLCBsZW4gPSB1bml0Rm9ybS5sZW5ndGg7IGkgPCBsZW47IGkrKykge1xcXFxuICAgICAgICAgICAgaWYgKHNpemUgPiAxMDI0KSB7XFxcXG4gICAgICAgICAgICAgICAgc2l6ZSAvPSAxMDI0O1xcXFxuICAgICAgICAgICAgICAgIGNvbnRpbnVlO1xcXFxuICAgICAgICAgICAgfSBlbHNlIHtcXFxcbiAgICAgICAgICAgICAgICByZXR1cm4gc2l6ZS50b0ZpeGVkKDIpLnJlcGxhY2UoLyhcXFxcXFxcXC4wMCkkLywgXFxcXFxcXCJcXFxcXFxcIikgKyB1bml0Rm9ybVtpXTtcXFxcbiAgICAgICAgICAgIH1cXFxcbiAgICAgICAgfVxcXFxuICAgICAgICByZXR1cm4gXFxcXFxcXCJFUlJPUjrmlbDlgLzov4flpKdcXFxcXFxcIjtcXFxcbiAgICB9XFxcXG59XFxcIn1dXCIsXCJwcm94eVwiOlwiXCJ9IiwidGl0bGUiOiLlpKflrabniannkIblrp7pqozliJjlm73okKUifQ==
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement