irc.py
| ( | |
| (lambda | |
| r,s,l,g:(g .signal | |
| (g.SIGTERM, g.default_int_handler | |
| ),exec("try:\n b.C()""\nexcept Key" | |
| "boardInterr""upt:\n b.Q()" | |
| ,{"b":type("h",(),dict(__init__ | |
| =lambda M,S,P,C:M.__dict__ | |
| .update(dict(R=(S,P),H | |
| =C,N="hollow%d"%r.randint | |
| (1,99),O=s.socket() | |
| ,A=0,B=0)),S=lambda M,t:( | |
| print(">>>",t,flush=1),M. | |
| O.sendall((t+"\r\n").encode | |
| ())),G=lambda M,t:t.split(" :" | |
| ,1)[1]if" :"in t else"",Q=lambda M:exec("try:\n M.S" | |
| "('QUIT :by""e')\nexcept"" Exception"":\n 0\ntry:\n"" getattr(M" | |
| ",'D',0)and"" M.D.close""()\n M.O.cl""ose()\nexce""pt Excepti" | |
| "on:\n 0",{"M":M}),C=lambda M:(M.O.connect(M.R),setattr | |
| (M,"O",l.create_default_context().wrap_socket(M.O,server_hostname | |
| =M.R[0])),setattr(M,"D",M.O.makefile("r",encoding="utf-8" | |
| )),M.S("CAP LS 302"),M.S("NICK %s"%M.N),M.S("USER %s 0 * :%s" | |
| %(M.N,M.N)),M.P()),P=lambda M:list(map(lambda u:(lambda | |
| L:(print("<<<",L,flush=1),M.S("PONG :%s"%M.G(L))if L. | |
| startswith("PING")else(lambda p:(M.S("CAP END"),setattr | |
| (M,"A",1))if len(p)>1 and p[1]=="CAP"and not M.A else(setattr | |
| (M,"N","hollow%d"%r.randint(1,99)),M.S("NICK %s"%M.N))if len | |
| (p)>1 and p[1]=="433"else M.S("JOIN %s"%M.H)if len(p)> | |
| 1 and p[1]=="001"else(M.S("PRIVMSG %s :say yes to heaven ♡" | |
| %M.H),setattr(M,"B",1))if len(p)>1 and p[1]=="366" | |
| and not M.B else 0)(L.split())))(u.strip()),M.D)) | |
| ))("irc.libera.chat",6697,"#lanadelrey")}))[-1 | |
| ])(__import__("random"),__import__("socket"),__import__ | |
| ("ssl"),__import__("signal")) | |
| ) |
评论
?
参与讨论