Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 海阔视界规则分享,当前分享的是:小程序¥home_rule_v2¥base64://@Zlib Pro@eyJsYXN0X2NoYXB0ZXJfcnVsZSI6IiIsInRpdGxlIjoiWmxpYiBQcm8iLCJhdXRob3IiOiJKb2UiLCJ1cmwiOiJoaWtlcjovL2VtcHR5IiwidmVyc2lvbiI6NSwiY29sX3R5cGUiOiJtb3ZpZV8zIiwiY2xhc3NfbmFtZSI6IiIsInR5cGUiOiJyZWFkIiwiY2xhc3NfdXJsIjoiIiwiYXJlYV9uYW1lIjoiIiwiYXJlYV91cmwiOiIiLCJzb3J0X25hbWUiOiIiLCJ5ZWFyX25hbWUiOiIiLCJzb3J0X3VybCI6IiIsInllYXJfdXJsIjoiIiwiZmluZF9ydWxlIjoianM6XG5sZXQgbGF5b3V0ID0gW107XG5sYXlvdXQucHVzaCh7XG4gICAgY29sX3R5cGU6IFwiYmlnX2JsYW5rX2Jsb2NrXCJcbn0pO1xubGF5b3V0LnB1c2goe1xuICAgIGNvbF90eXBlOiBcImJpZ19ibGFua19ibG9ja1wiXG59KTtcbmxheW91dC5wdXNoKHtcbiAgICBjb2xfdHlwZTogXCJiaWdfYmxhbmtfYmxvY2tcIlxufSk7XG5sYXlvdXQucHVzaCh7XG4gICAgY29sX3R5cGU6IFwiYmlnX2JsYW5rX2Jsb2NrXCJcbn0pO1xuXG5sYXlvdXQucHVzaCh7XG4gICAgdGl0bGU6ICc8aDEgc3R5bGU9XCJ0ZXh0LWFsaWduOiBjZW50ZXI7XCI+PGJpZz48Zm9udCBjb2xvcj1cIiNGRUJENkZcIj5abGliIFBybzwvZm9udD48L2JpZz48YnI+PHNtYWxsPjxmb250IGNvbG9yPVwiI0ZCNkM3M1wiPuS4i+S5puWlveW4ruaJizwvZm9udD48L3NtYWxsPjwvaDE+JyxcbiAgICBjb2xfdHlwZTogXCJyaWNoX3RleHRcIlxufSk7XG5sYXlvdXQucHVzaCh7XG4gICAgY29sX3R5cG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jaC9cXFwiLCB7XFxuICAgICAgICAgICAgYm9keTogSlNPTi5zdHJpbmdpZnkoe1xcbiAgICAgICAgICAgICAgICBcXFwia2V5d29yZFxcXCI6IGt3LFxcbiAgICAgICAgICAgICAgICBcXFwicGFnZVxcXCI6IHBhZ2UsXFxuICAgICAgICAgICAgICAgIFxcXCJzZW5zaXRpdmVcXFwiOiBmYWxzZVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICB9KSkuZGF0YVxcbiAgICAgICAgcmVzLmZvckVhY2goaXRlbSA9PiB7XFxuICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgdGl0bGU6IGl0ZW0udGl0bGUsXFxuICAgICAgICAgICAgICAgIGRlc2M6IGDigJzigJzigJ3igJ08c21hbGw+5L2c6ICFOiR7aXRlbS5hdXRob3J9IOWHuueJiOekvjoke2l0ZW0ucHVibGlzaGVyP2l0ZW0ucHVibGlzaGVyOlxcXCLmmoLml6BcXFwifSBJU0JOOiR7aXRlbS5pc2JuP2l0ZW0uaXNibjpcXFwi5pqC5pegXFxcIn0g5Ye654mI5pe26Ze0OiR7aXRlbS55ZWFyP2l0ZW0ueWVhcjpcXFwi5pqC5pegXFxcIn0g5paH5Lu25qC85byPOiR7aXRlbS5leHRlbnNpb259IOaWh+S7tuWkp+WwjzokeyQucmVxdWlyZShcXFwiYXBpXFxcIikuZ2V0RmlsZVNpemUoaXRlbS5maWxlc2l6ZSl9PC9zbWFsbD5gLFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoKS5sYXp5UnVsZSgoaWQpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHRyeSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlcyA9IEpTT04ucGFyc2UocG9zdChcXFwiaHR0cHM6Ly9hcGkueWxpYnJhcnkub3JnL2FwaS9kZXRhaWwvXFxcIiwge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBib2R5OiBKU09OLnN0cmluZ2lmeSh7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcXFwiaWRcXFwiOiBpZCxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJzb3VyY2VcXFwiOiBcXFwiemxpYnJhcnlcXFwiXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSkpXFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHNlcnZlcnMgPSAkLnJlcXVpcmUoXFxcImhpa2VyOi8vcGFnZS9hcGlcXFwiKS5zZXJ2ZXJzXFxuICAgICAgICAgICAgICAgICAgICAgICAgc2VydmVycy51bnNoaWZ0KFxcXCJpcGZz5LiL6L29XFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcIueZvuW6puS6keebmOi9rOWtmFxcXCIpXFxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHJlcy5pbl9saWJnZW4pIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2VydmVycy51bnNoaWZ0KFxcXCJMaWJnZW4o5o6o6I2QKVxcXCIpXFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAkKHNlcnZlcnMsIDEsIFxcXCLpgInmi6nnur/ot69cXFwiKS5zZWxlY3QoKHJlcykgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoaW5wdXQgPT0gXFxcIkxpYmdlbijmjqjojZApXFxcIikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXCJkb3dubG9hZDovL1xcXCIgKyBwZGZoKHJlcXVlc3QoXFxcImh0dHA6Ly9saWJyYXJ5LmxvbC9tYWluL1xcXCIgKyByZXMubWQ1KSwgXFxcIiNkb3dubG9hZCYmYSYmaHJlZlxcXCIpXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoaW5wdXQgPT0gXFxcIueZvuW6puS6keebmOi9rOWtmFxcXCIpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAkLnJlcXVpcmUoXFxcImFwaVxcXCIpLmJhaWR1KHJlcylcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpbnB1dCA9PSBcXFwiaXBmc+S4i+i9vVxcXCIpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBgeDU6Ly9odHRwczovL2lwZnMtY2hlY2tlci4xa2J0b29sLmNvbS8ke3Jlcy5pcGZzX2NpZH1gXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcImRvd25sb2FkOi8vXFxcIiArIGlucHV0ICsgcmVzLmlwZnNfY2lkXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgICAgICB9LCByZXMpXFxuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgbG9nKGUubWVzc2FnZSlcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcInRvYXN0Oi8v6Kej5p6Q5aSx6LSlXFxcIlxcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB9LCBpdGVtLmlkKVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICB9KVxcbiAgICB9LFxcbiAgICBaaGVscGVyX3Y1OiBmdW5jdGlvbihrdywgcGFnZSkge1xcbiAgICAgICAgdmFyIHJlcyA9IEpTT04ucGFyc2UocG9zdChcXFwiaHR0cHM6Ly9hcGkudjUuemhlbHBlci5uZXQvYXBpL3NlYXJjaC9cXFwiLCB7XFxuICAgICAgICAgICAgYm9keTogSlNPTi5zdHJpbmdpZnkoe1xcbiAgICAgICAgICAgICAgICBcXFwia2V5d29yZFxcXCI6IGt3LFxcbiAgICAgICAgICAgICAgICBcXFwicGFnZVxcXCI6IHBhZ2UsXFxuICAgICAgICAgICAgICAgIFxcXCJzZW5zaXRpdmVcXFwiOiBmYWxzZVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICB9KSkuZGF0YVxcbiAgICAgICAgcmVzLmZvckVhY2goaXRlbSA9PiB7XFxuICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgdGl0bGU6IGl0ZW0udGl0bGUsXFxuICAgICAgICAgICAgICAgIGRlc2M6IGDigJzigJzigJ3igJ08c21hbGw+5L2c6ICFOiR7aXRlbS5hdXRob3J9IOWHuueJiOekvjoke2l0ZW0ucHVibGlzaGVyP2l0ZW0ucHVibGlzaGVyOlxcXCLmmoLml6BcXFwifSBJU0JOOiR7aXRlbS5pc2JuP2l0ZW0uaXNibjpcXFwi5pqC5pegXFxcIn0g5Ye654mI5pe26Ze0OiR7aXRlbS55ZWFyP2l0ZW0ueWVhcjpcXFwi5pqC5pegXFxcIn0g5paH5Lu25qC85byPOiR7aXRlbS5leHRlbnNpb259IOaWh+S7tuWkp+WwjzokeyQucmVxdWlyZShcXFwiYXBpXFxcIikuZ2V0RmlsZVNpemUoaXRlbS5maWxlc2l6ZSl9PC9zbWFsbD5gLFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoKS5sYXp5UnVsZSgoaWQpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHRyeSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlcyA9IEpTT04ucGFyc2UocG9zdChcXFwiaHR0cHM6Ly9hcGkudjUuemhlbHBlci5uZXQvYXBpL2RldGFpbC9cXFwiLCB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJvZHk6IEpTT04uc3RyaW5naWZ5KHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJpZFxcXCI6IGlkLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgXFxcInNvdXJjZVxcXCI6IFxcXCJ6bGlicmFyeVxcXCJcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KSlcXG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgc2VydmVycyA9ICQucmVxdWlyZShcXFwiaGlrZXI6Ly9wYWdlL2FwaVxcXCIpLnNlcnZlcnNcXG4gICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcImlwZnPkuIvovb1cXFwiKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlcnZlcnMudW5zaGlmdChcXFwi55m+5bqm5LqR55uY6L2s5a2YXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzLmluX2xpYmdlbikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJzLnVuc2hpZnQoXFxcIkxpYmdlbijmjqjojZApXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICQoc2VydmVycywgMSwgXFxcIumAieaLqee6v+i3r1xcXCIpLnNlbGVjdCgocmVzKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpbnB1dCA9PSBcXFwiTGliZ2VuKOaOqOiNkClcXFwiKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcImRvd25sb2FkOi8vXFxcIiArIHBkZmgocmVxdWVzdChcXFwiaHR0cDovL2xpYnJhcnkubG9sL21haW4vXFxcIiArIHJlcy5tZDUpLCBcXFwiI2Rvd25sb2FkJiZhJiZocmVmXFxcIilcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpbnB1dCA9PSBcXFwi55m+5bqm5LqR55uY6L2s5a2YXFxcIikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuICQucmVxdWlyZShcXFwiYXBpXFxcIikuYmFpZHUocmVzKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2UgaWYgKGlucHV0ID09IFxcXCJpcGZz5LiL6L29XFxcIikge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGB4NTovL2h0dHBzOi8vaXBmcy1jaGVja2VyLjFrYnRvb2wuY29tLyR7cmVzLmlwZnNfY2lkfWBcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwiZG93bmxvYWQ6Ly9cXFwiICsgaW5wdXQgKyByZXMuaXBmc19jaWRcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sIHJlcylcXG4gICAgICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBsb2coZS5tZXNzYWdlKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwidG9hc3Q6Ly/op6PmnpDlpLHotKVcXFwiXFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH0sIGl0ZW0uaWQpXFxuICAgICAgICAgICAgfSlcXG4gICAgICAgIH0pXFxuICAgIH0sXFxuICAgIFpoZWxwZXJfdjQ6IGZ1bmN0aW9uKGt3LCBwYWdlKSB7XFxuICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KFxcXCJodHRwczovL2FwaS5taWJvb2tzLnRrL2FwaS9zZWFyY2gvXFxcIiwge1xcbiAgICAgICAgICAgIGJvZHk6IEpTT04uc3RyaW5naWZ5KHtcXG4gICAgICAgICAgICAgICAgXFxcImtleXdvcmRcXFwiOiBrdyxcXG4gICAgICAgICAgICAgICAgXFxcInBhZ2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V0dXJuIFxcXCJkb3dubG9hZDovL1xcXCIgKyBpbnB1dCArIFxcXCIvZG93bmxvYWQvXFxcIiArIGlkICsgXFxcIi9cXFwiXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSwgaWQpXFxuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgbG9nKGUubWVzc2FnZSlcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcInRvYXN0Oi8v6Kej5p6Q5aSx6LSlXFxcIlxcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB9LCBpdGVtLmlkKVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICB9KVxcbiAgICB9LFxcbiAgICDnvZHnm5g6IGZ1bmN0aW9uKGt3LCBwYWdlKSB7XFxuICAgICAgICB2YXIgcmVzID0gSlNPTi5wYXJzZShwb3N0KFxcXCJodHRwczovL2FwaS5ib29rcGFuLm5ldC9hcGkvc2VhcmNoL1xcXCIsIHtcXG4gICAgICAgICAgICBib2R5OiBKU09OLnN0cmluZ2lmeSh7XFxuICAgICAgICAgICAgICAgIFxcXCJrZXl3b3JkXFxcIjoga3csXFxuICAgICAgICAgICAgICAgIFxcXCJwYWdlXFxcIjogcGFnZSxcXG4gICAgICAgICAgICAgICAgXFxcInNlbnNpdGl2ZVxcXCI6IGZhbHNlXFxuICAgICAgICAgICAgfSlcXG4gICAgICAgIH0pKS5kYXRhXFxuICAgICAgICByZXMuZm9yRWFjaChpdGVtID0+IHtcXG4gICAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgICAgICB0aXRsZTogaXRlbS5pbmZvLFxcbiAgICAgICAgICAgICAgICBkZXNjOiBcXFwi4oCc4oCc4oCd4oCdPHNtYWxsPlxcXCIgKyBpdGVtLnNvdXJjZSArIFxcXCI8L3NtYWxsPlxcXCIsXFxuICAgICAgICAgICAgICAgIHVybDogJCgpLmxhenlSdWxlKChpZCwgc291cmNlKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICB0cnkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhciByZXMgPSBKU09OLnBhcnNlKHBvc3QoXFxcImh0dHBzOi8vYXBpLmJvb2twYW4ubmV0L2FwaS9kZXRhaWwvXFxcIiwge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBib2R5OiBKU09OLnN0cmluZ2lmeSh7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBcXFwiaWRcXFwiOiBpZCxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFxcXCJzb3VyY2VcXFwiOiBzb3VyY2VcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICAgICAgICAgICAgICB9KSlcXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzLmRvd25sb2FkX2xpbmspIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGRpY3QgPSB7fVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXMuZG93bmxvYWRfbGluay51bnNoaWZ0KHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5hbWU6IFxcXCLljp/nvZHpobVcXFwiLFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiByZXMudXJsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAkKHJlcy5kb3dubG9hZF9saW5rLm1hcChmdW5jdGlvbihpdGVtKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gaXRlbS5uYW1lXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pLCAxLCBcXFwi6K+36YCJ5oup5LiL6L2957q/6LevXFxcIikuc2VsZWN0KChsaW5rcykgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGxpbmtzW2xpbmtzLm1hcChmdW5jdGlvbihpdGVtKSB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGl0ZW0ubmFtZVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSkuaW5kZXhPZihpbnB1dCldLnVybFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9LCByZXMuZG93bmxvYWRfbGluaylcXG4gICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmVzLnVybFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBsb2coZS5tZXNzYWdlKVxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwidG9hc3Q6Ly/op6PmnpDlpLHotKVcXFwiXFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH0sIGl0ZW0uaWQsIGl0ZW0uc291cmNlKVxcbiAgICAgICAgICAgIH0pXFxuICAgICAgICB9KVxcbiAgICB9LFxcbiAgICBiYWlkdTogZnVuY3Rpb24ocmVzKSB7XFxuICAgICAgICB0cnkge1xcbiAgICAgICAgICAgIGlmICghZmlsZUV4aXN0KFxcXCJoaWtlcjovL2ZpbGVzL3J1bGVzL0pvZS9iYWlkdS50eHRcXFwiKSkge1xcbiAgICAgICAgICAgICAgICB0b2FzdChcXFwi6L+Y5pyq55m76ZmGXFxcIilcXG4gICAgICAgICAgICAgICAgcmV0dXJuICQoKS5ydWxlKCgpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHNldFJlc3VsdChbe1xcbiAgICAgICAgICAgICAgICAgICAgICAgIHVybDogXFxcImh0dHBzOi8vcGFuLmJhaWR1LmNvbS9cXFwiLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbF90eXBlOiBcXFwieDVfd2Vidmlld19zaW5nbGVcXFwiLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGRlc2M6IFxcXCIxMDAlJiZmbG9hdFxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAganM6ICQudG9TdHJpbmcoKCkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHVybCA9IGxvY2F0aW9uLmhyZWZcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICh1cmwuaW5jbHVkZXMoXFxcImh0dHBzOi8vcGFuLmJhaWR1LmNvbS93YXBcXFwiKSkge1xcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGZiYS53cml0ZUZpbGUoXFxcImhpa2VyOi8vZmlsZXMvcnVsZXMvSm9lL2JhaWR1LnR4dFxcXCIsIGZiYS5nZXRDb29raWUoXFxcIlxcXCIpKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGFsZXJ0KFxcXCLlt7Lojrflj5bliLBjb29raWXvvIzov5Tlm57ljbPlj69cXFwiKVxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGZiYS5iYWNrKClcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSksXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVhOiBNT0JJTEVfVUEsXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNhbkJhY2s6IHRydWVcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgICAgICB9XSlcXG4gICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICB2YXIgYmRzdG9rZW4gPSBKU09OLnBhcnNlKHJlcXVlc3QoXFxcImh0dHBzOi8vcGFuLmJhaWR1LmNvbS9hcGkvZ2V0dGVtcGxhdGV2YXJpYWJsZT9maWVsZHM9WyUyMmJkc3Rva2VuJTIyXVxcXCIsIHtcXG4gICAgICAgICAgICAgICAgICAgIGhlYWRlcnM6IHtcXG4gICAgICAgICAgICAgICAgICAgICAgICBDb29raWU6IHJlcXVlc3QoXFxcImhpa2VyOi8vZmlsZXMvcnVsZXMvSm9lL2JhaWR1LnR4dFxcXCIpXFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH0pKS5yZXN1bHQuYmRzdG9rZW5cXG4gICAgICAgICAgICAgICAgdmFyIHJlcyA9IEpTT04ucGFyc2UocG9zdChcXFwiaHR0cHM6Ly9wYW4uYmFpZHUuY29tL3Jlc3QvMi4wL3hwYW4vZmlsZT9tZXRob2Q9Y3JlYXRlJmJkc3Rva2VuPVxcXCIgKyBiZHN0b2tlbiwge1xcbiAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1xcbiAgICAgICAgICAgICAgICAgICAgICAgIENvb2tpZTogcmVxdWVzdChcXFwiaGlrZXI6Ly9maWxlcy9ydWxlcy9Kb2UvYmFpZHUudHh0XFxcIilcXG4gICAgICAgICAgICAgICAgICAgIH0sXFxuICAgICAgICAgICAgICAgICAgICBib2R5OiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgc2l6ZTogcmVzLmZpbGVzaXplICsgXFxcIlxcXCIsXFxuICAgICAgICAgICAgICAgICAgICAgICAgcGF0aDogXFxcIi/nlLXlrZDkuaYvXFxcIiArIHJlcy50aXRsZSArIFxcXCIuXFxcIiArIHJlcy5leHRlbnNpb24sXFxuICAgICAgICAgICAgICAgICAgICAgICAgYmxvY2tfbGlzdDogW3Jlcy5tZDVdLFxcbiAgICAgICAgICAgICAgICAgICAgICAgIHJ0eXBlOiAwXFxuICAgICAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIH0pKVxcbiAgICAgICAgICAgICAgICBpZiAocmVzLmVycm5vID09IDApIHtcXG4gICAgICAgICAgICAgICAgICAgIHJlZnJlc2hQYWdlKClcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBcXFwidG9hc3Q6Ly/ovazlrZjmiJDlip9cXFwiXFxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgICAgICBsb2cocmVzLmVycm5vKVxcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXCJ0b2FzdDovL+i9rOWtmOWksei0pVxcXCJcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIH1cXG4gICAgICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgICAgICBsb2coZS5tZXNzYWdlKVxcbiAgICAgICAgICAgIHJldHVybiBcXFwidG9hc3Q6Ly/ovazlrZjlpLHotKVcXFwiXFxuICAgICAgICB9XFxuICAgIH1cXG59XCJ9XSIsImljb24iOiJodHRwczovL2xhbm1laWd1b2ppYW5nLmNvbS90dWJpYW8va2UvMzgucG5nIiwicHJveHkiOiIifQ==
Add Comment
Please, Sign In to add comment