-
Notifications
You must be signed in to change notification settings - Fork 30
Hashes
147 def make_cookie(self, timestr = None, admin = False):
148 if not self.loaded:
149 self.load()
150 timestr = timestr or time.strftime(‘%Y-%m-%dT%H:%M:%S’)
151 id_time = str(self.id) + ‘,’ + timestr
152 to_hash = ‘,’.join((id_time, self.password, g.SECRET))
153 if admin:
154 tohash += ‘admin’
155 return idtime + ‘,’ + sha.new(tohash).hexdigest()
Pasted from <http://code.reddit.com/browser/r2/r2/models/account.py#L301>
After logging in via POST to www.reddit.com/api/login/, the GET to / (or any regular HTML page) produces a huge uncompressed HTML file (160 kb). Split into 16 kb chunks, divided by unique separators (strings of digits). Contains this piece on the 2nd line (within first 1050 chars of file) :