Skip to content

Instantly share code, notes, and snippets.

Created August 21, 2012 16:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/3416945 to your computer and use it in GitHub Desktop.
Save anonymous/3416945 to your computer and use it in GitHub Desktop.
#!/usr/bin/python
#-*- encoding: Utf-8 -*-
from socket import socket, AF_INET, SOCK_STREAM
# Script pour afficher de l'ascii art sur la tribune.
cookie = 'linuxfr.org_session=xxxxx'
art = '''
##############
## ##
## ###
## ##
# ##
# ##
# ##
# # ##
## ## #
# ## #
# ## #
# ## ##
### ## ### #
########### ## ## ##
# ########### # ##
# ############# ## ##
# ####### ########### ##
# ####### ###### #### #
# ####### ####### ## ##
# ##### ###### ### ###
## ## #### #
# ##
## #
# ####################### #
## # # #
## # # #
## ## # #
## ## # #
## ## ### #
## ######### ##
## ##
### ###
###########
'''.split('\n')
art.reverse()
for i in art:
s = socket(AF_INET, SOCK_STREAM)
s.connect(('88.191.250.176', 80))
data = 'board[message]=<code>' + i + '</code>'
request = 'POST /board HTTP/1.1\r\n'
request += 'Host: linuxfr.org\r\n'
request += 'Referer: http://linuxfr.org/\r\n'
request += 'Content-Length: ' + str(len(data)) + '\r\n'
request += 'Cookie: ' + cookie + '\r\n\r\n'
s.send(request + data)
s.close()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment