Bitcoin Forum
December 03, 2016, 01:59:58 PM *
News: Latest stable version of Bitcoin Core: 0.13.1  [Torrent].
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: Sig Ads - Deleted? WTF?  (Read 1247 times)
mizerydearia
Hero Member
*****
Offline Offline

Activity: 574



View Profile
October 13, 2011, 01:01:19 AM
 #1

My Sig Ads thread was deleted?  WTF? o_X

This thread was full of all users signatures. =/  It took quite a while to prepare the data.  Tis disappointing that it was so easily dismissed as spam/deletion-worthy.

https://bitcointalk.org/index.php?topic=20333.0
The policy to not remove anything worked when the forum was small. Now that we have thousands of posts a day, we can't afford 50% of them being junk. The moderators are now instructed to be less tolerant of low-value posts.

Some guidelines:

1. Free speech - you can say anything as long as it is relevant and presented in a calm and polite manner. Swearing, SHOUTING etc. make your post more likely to be removed.
2. No zero value posts or threads, like "SELL SELL SELL"
3. No pointless or uninteresting threads.
4. No referral code spam
5. No NSFW content
1. Okay.
2. Okay.  The thread had some value/significance as it allowed users to see all user's signatures in a single page view (e.g. view all pages - for threads with 25 pages or less)
3. Okay.  See #2.
4. Okay.
5. Okay.

So why was the thread deleted?

Here is the method I used to compile the signatures:

Code:
#!/usr/bin/python
import httplib, logging, os, re, socket, ssl, stat

# Levels: DEBUG, INFO, WARNING, ERROR, CRITICAL
logging.basicConfig(level='DEBUG');log = logging.getLogger(":")

headers = {'User-Agent': 'Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.4) Gecko/2008121819 Gentoo Firefox/3.0.4'}

def writeDataToFile(data, file):
    f = open(file, 'w')
    os.chmod(f.name,stat.S_IREAD | stat.S_IWRITE | stat.S_IRGRP | stat.S_IROTH)
    f.write(data)
    f.close()

for x in range(44000):
    url = "https://bitcointalk.org/index.php?action=profile;u="+str(x)
    url = re.search('(https?)://([^/]*)(.*)', url)
    if url.group(1) == "http": connection = httplib.HTTPConnection(url.group(2), timeout=10)
    elif url.group(1) == "https": connection = httplib.HTTPSConnection(url.group(2), timeout=10)

    try: connection.request("GET", url.group(3), '', headers);response = connection.getresponse()
    except socket.error, e: log.error("socket error:"+url.group()+" "+str(e))
    except socket.timeout, e: log.error("socket timeout:"+url.group()+" "+e.message)
    except ssl.SSLError, e: log.error("ssl error:"+url.group()+" "+e.message)
    except httplib.BadStatusLine, e: log.error("http status code error:"+url.group()+" "+e.message)

    html = response.read()
    if html[283:304] != "An Error Has Occurred":
        #<td colspan="2" width="100%" class="smalltext"><div class="signature"></div></td>
        sightml = '<table width="100%" cellpadding="0" cellspacing="0" border="0" style="table-layout: fixed;">\n+'
        sightml += ' <tr>\n+'
        sightml += ' <td style="padding-bottom: 0.5ex;"><b>Signature:</b></td>\n+'
        sightml += ' </tr><tr>\n+'
        sightml += ' <td colspan="2" width="100%" class="smalltext"><div class="signature">(.*)</div></td>\n+'
        sightml += ' </tr>\n+'
        sightml += ' </table>'
        sig = re.search(sightml, html)
        if sig.group(1) != "":
            print x,sig.group(1)
            writeDataToFile(sig.group(1), 'g2/'+str(x))

And then converting html back to bbcode consisted of executing each of these a few times trying to convert all the children first:

Code:
for i in g2/*;do iconv -f latin1 < $i > "$i.";mv "$i." "$i";done
sed -i "s|<hr />|[hr]|g" g2/*
sed -i "s|<i>|[i]|g" g2/*
sed -i "s|</i>|[/i]|g" g2/*
sed -i "s|<b>|[b]|g" g2/*
sed -i "s|</b>|[/b]|g" g2/*
sed -i "s|<br />|[br]|g" g2/*
sed -i "s|<sup>|[sup]|g" g2/*
sed -i "s|</sup>|[/sup]|g" g2/*
sed -i "s|<sub>|[sub]|g" g2/*
sed -i "s|</sub>|[/sub]|g" g2/*
sed -i "s|<del>|[s]|g" g2/*
sed -i "s|</del>|[/s]|g" g2/*
sed -i "s|<pre>|[pre]|g" g2/*
sed -i "s|</pre>|[/pre]|g" g2/*
sed -i "s|<tt>|[tt]|g" g2/*
sed -i "s|</tt>|[/tt]|g" g2/*
sed -i "s|<li>|[li]|g" g2/*
sed -i "s|</li>|[/li]|g" g2/*
sed -i "s|<marquee>|[/move]|g" g2/*
sed -i "s|</marquee>|[/move]|g" g2/*
sed -i "s|<table style=\"font: inherit; color: inherit;\">|[table]|g" g2/*
sed -i "s|</table>|[/table]|g" g2/*
sed -i "s|<tr>|[tr]|g" g2/*
sed -i "s|</tr>|[/tr]|g" g2/*
sed -i "s|<td valign=\"top\" style=\"font: inherit; color: inherit;\">|[td]|g" g2/*
sed -i "s|</td>|[/td]|g" g2/*
sed -i "s|<ul style=\"margin-top: 0; margin-bottom: 0;\">|[list]|g" g2/*
sed -i "s|</ul>|[/list]|g" g2/*
sed -i "s/<img src=\"\([^\"]*\)\" alt=\"[^\"]*\" border=\"0\" \/>/[img]\1[\/img]/g" g2/*
sed -i "s/<img src=\"\([^\"]*\)\" alt=\"[^\"]*\" height=\"[^\"]*\" border=\"0\" \/>/[img]\1[\/img]/g" g2/*
sed -i "s/<img src=\"\([^\"]*\)\" alt=\"[^\"]*\" width=\"[^\"]*\" border=\"0\" \/>/[img]\1[\/img]/g" g2/*
sed -i "s/<img src=\"\([^\"]*\)\" alt=\"[^\"]*\" width=\"[^\"]*\" height=\"[^\"]*\" border=\"0\" \/>/[img]\1[\/img]/g" g2/*
sed -i "s|<a href=\"\([^\"]*\)\" target=\"_blank\">\([^<]*\)</a>|[url=\1]\2[/url]|g" g2/*
sed -i "s|<a href=\"\([^\"]*\)\">\([^<]*\)</a>|[url=\1]\2[/url]|g" g2/*
sed -i "s|<span style=\"text-decoration: underline;\">\([^<]*\)</span>|[u]\1[/u]|g" g2/*
sed -i "s|<div align=\"center\">\([^<]*\)</div>|[center]\1[/center]|g" g2/*
sed -i "s|<div align=\"left\">\([^<]*\)</div>|[left]\1[/left]|g" g2/*
sed -i "s|<div align=\"right\">\([^<]*\)</div>|[right]\1[/right]|g" g2/*
sed -i "s|<div class=\"code\"><pre style=\"margin-top: 0; display: inline;\">\([^<]*\)</pre></div>|\[code]\1\[/code\]|g" g2/*   # <-- Change \[ to [
sed -i "s|<span style=\"color: \([^;]*\);\">\([^<]*\)</span>|[color=\1]\2[/color]|g" g2/*
sed -i "s|<div style=\"text-align: right;\">\([^<]*\)</div>|[right]\1[/right]|g" g2/*
sed -i "s|<div class=\"quote\">\([^<]*\)</div>|[quote]\1[/quote]|g" g2/*
sed -i "s|<div class=\"quoteheader\">Quote from: \([^<]*\)</div>\[quote\]|[quote=\1]|g" g2/*
sed -i "s|<div class=\"quoteheader\">Quote</div>||g" g2/*
sed -i "s|<span style=\"background-color: \([^;]*\);\">\([^<]*\)</span>|[glow=\1,2]\2[/glow]|g" g2/*
sed -i "s|<span style=\"font-size: \([^;]*\); line-height: 1.3em;\">\([^<]*\)</span>|[size=\1]\2[/size]|g" g2/*
sed -i "s|<font size=\"\([^\"]*\)\" style=\"line-height: 1.3em;\">\([^\"]*\)</font>|[size=\1]\2[/size]|g" g2/*
sed -i "s|<span style=\"color: \([^;]*\);\">\([^<]*\)</span>|[color=\1]\2[/color]|g" g2/*

And then preparing posts to be under 64,000 (60,000 to be safe because even under 63,000 triggered the 64,000 limit) limit:

Code:
c=1;for i in g2/*;do if test ! -f "y/$c"; then cat $i >> "y/$c";echo -n "[hr]" >> "y/$c";else fs=$(stat -c%s "y/$c");len=$(cat $i|wc -m);ts=$(echo $fs + $len + 4|bc -l);echo $ts; if test $ts -lt 60000;then cat $i >> "y/$c"; echo -n "[hr]" >> "y/$c"; else c=$(echo "$c + 1"|bc);cat $i >> "y/$c";echo -n "[hr]" >> "y/$c";fi;fi;done
[/code]
1480773598
Hero Member
*
Offline Offline

Posts: 1480773598

View Profile Personal Message (Offline)

Ignore
1480773598
Reply with quote  #2

1480773598
Report to moderator
1480773598
Hero Member
*
Offline Offline

Posts: 1480773598

View Profile Personal Message (Offline)

Ignore
1480773598
Reply with quote  #2

1480773598
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1480773598
Hero Member
*
Offline Offline

Posts: 1480773598

View Profile Personal Message (Offline)

Ignore
1480773598
Reply with quote  #2

1480773598
Report to moderator
Bitcoin Oz
Hero Member
*****
Offline Offline

Activity: 700


Wat


View Profile WWW
October 13, 2011, 01:05:56 AM
 #2

You can probably post them on witcoin without the issues  Wink

deslok
Sr. Member
****
Offline Offline

Activity: 448


It's all about the game, and how you play it


View Profile
October 13, 2011, 01:07:09 AM
 #3

They made my phone cry when i opened them earlier Sad

"If we don't hang together, by Heavens we shall hang separately." - Benjamin Franklin

If you found that funny or something i said useful i always appreciate spare change
1PczDQHfEj3dJgp6wN3CXPft1bGB23TzTM
mizerydearia
Hero Member
*****
Offline Offline

Activity: 574



View Profile
October 13, 2011, 01:07:30 AM
 #4

I would like to post them on this forum.  Is posting a compilation of user's signatures on this forum unacceptable?
Phinnaeus Gage
Legendary
*
Offline Offline

Activity: 1302


Bitcoin: An Idea Worth Spending


View Profile
October 13, 2011, 01:09:40 AM
 #5

For one thin BTC I can tell you how to view the thread again.

Not a trick. PM me. You'll love it!

EDIT: Was kidding about charging you.

What I would need is some body text, though.
mizerydearia
Hero Member
*****
Offline Offline

Activity: 574



View Profile
October 13, 2011, 02:44:34 AM
 #6

I can tell you how to view the thread again.  What I would need is some body text, though.

You can make use of any user's signature to obtain body text.

Here's pastebin of old page view: http://pastebin.ca/raw/2089591
Phinnaeus Gage
Legendary
*
Offline Offline

Activity: 1302


Bitcoin: An Idea Worth Spending


View Profile
October 13, 2011, 03:01:56 AM
 #7

What was the title of the thread?

mizerydearia
Hero Member
*****
Offline Offline

Activity: 574



View Profile
October 13, 2011, 03:02:30 AM
 #8

I deleted the replies to the bidding topic because it was off-topic.
The topic itself was deleted by some other mod. Probably because it looked pointless or like automated spam. Try again with some explanatory text. I can give you a copy of the topic if you don't have a copy.

Title was 'Sig Ads'

I shall be recreating it in a few minutes.  It will be a tad bit improved with the character entities fixed.
Phinnaeus Gage
Legendary
*
Offline Offline

Activity: 1302


Bitcoin: An Idea Worth Spending


View Profile
October 13, 2011, 03:10:44 AM
 #9

Got It!

http://www.google.com/search?gcx=c&sourceid=chrome&ie=UTF-8&q=mizerydearia+%22Sig+Ads%22

But, there's a catch--you'll have to wait till tomorrow to be able see the cache on Google. It'll all be there.
Phinnaeus Gage
Legendary
*
Offline Offline

Activity: 1302


Bitcoin: An Idea Worth Spending


View Profile
October 13, 2011, 03:18:33 AM
 #10

If the first post of this thread was deleted, you would be able to see the cache on Google tomorrow.

The following is what is available now. My last post will be available in a couple more minutes.

source: http://www.google.com/search?hl=en&biw=1280&bih=685&tbs=qdr:h&q=+site:bitcointalk.org+bitcointalk

Sig Ads - Deleted? WTF?
https://bitcointalk.org/index.php?topic=47992.0 - Block bitcointalk.org
6 posts - 4 authors - Last post: 27 minutes ago
My Sig Ads thread was deleted? WTF? o_X. This thread was full of all users signatures. =/ It took quite a while to prepare the data. Tis disappointing that it was ...

Hope that helps you out.

Bruno
mizerydearia
Hero Member
*****
Offline Offline

Activity: 574



View Profile
October 13, 2011, 03:47:49 AM
 #11

Thanks, but I still have the source data to easily repost without reproducing the entire compilation of data again.  I'm still working on converting the character entities though.   It's taking a bit longer than I anticipated.

For example:
Code:
grep "&" g2/*|sed "s/&#\([0-9]\+\)/\\\x\1/g"

The \x\1 doesn't evaluate to unicode value for the entity since the \x is evaluated as x first.  I'm still working on figuring out solution (by asking in #sed on freenode ^_^).
Phinnaeus Gage
Legendary
*
Offline Offline

Activity: 1302


Bitcoin: An Idea Worth Spending


View Profile
October 13, 2011, 04:29:19 AM
 #12

Thanks, but I still have the source data to easily repost without reproducing the entire compilation of data again.  I'm still working on converting the character entities though.   It's taking a bit longer than I anticipated.

For example:
Code:
grep "&" g2/*|sed "s/&#\([0-9]\+\)/\\\x\1/g"

The \x\1 doesn't evaluate to unicode value for the entity since the \x is evaluated as x first.  I'm still working on figuring out solution (by asking in #sed on freenode ^_^).

grep "&" g2/*|sed "s/&#\([0-9]\+\)/\\\x\1/g"

Fixed!

mizerydearia
Hero Member
*****
Offline Offline

Activity: 574



View Profile
October 13, 2011, 04:38:17 AM
 #13

grep "&" g2/*|sed "s/&#\([0-9]\+\)/\\\x\1/g"
Fixed!

Fix?  That is the exact same.
Phinnaeus Gage
Legendary
*
Offline Offline

Activity: 1302


Bitcoin: An Idea Worth Spending


View Profile
October 13, 2011, 05:04:53 AM
 #14

grep "&" g2/*|sed "s/&#\([0-9]\+\)/\\\x\1/g"
Fixed!

Fix?  That is the exact same.

LOL! I know. But I had to have a little fun. The truth of the matter is I don't have the slightest idea what all those symbols mean. It was my pleasure, though, to try to help you with your issue. That was sincere.

Bruno
theymos
Administrator
Legendary
*
Offline Offline

Activity: 2492


View Profile
October 13, 2011, 05:26:51 AM
 #15

Code:
grep "&" g2/*|sed "s/&#\([0-9]\+\)/\\\x\1/g"

\x takes hexadecimal ASCII codes, but the entities used by the forum are decimal Unicode codes.

I don't think it can be done with sed s.

1NXYoJ5xU91Jp83XfVMHwwTUyZFK64BoAD
mizerydearia
Hero Member
*****
Offline Offline

Activity: 574



View Profile
October 14, 2011, 09:16:41 AM
 #16

Recreated and bunch of useless spams removed.  Thanks for bearing with me after my initial spam ridden spam.

Yo dawg, I heard you don't liek spam, so I removed spam from your spam so you can avoid spam while you encounter spam.

More spam here
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!