Skip to content

Instantly share code, notes, and snippets.

View jdmaturen's full-sized avatar

jd jdmaturen

View GitHub Profile
@jdmaturen
jdmaturen / gist:3627593
Created September 4, 2012 22:44 — forked from argv0/gist:3627514
Markov Chain Thing I Wrote A Long Time Ago
just write something funny, dufus.
The token system is ridiculous because it makes security weaker, by offering a
larger surface area for attack.
If I had to guess, Salesforce is concerned that users are embedding their
passwords into scripts which could be stolen and used outside the company for
other purposes. Why are users putting their passwords in scripts? I imagine
it's because of the web-centric oauth flow coupled with short oauth token
expiration intervals but THATS a different story.
So *within* an authorized set of IP addresses, the regular password works.
import logging
import gevent
from gevent.queue import Queue
from thrift.server.TServer import TServer
from thrift.transport.TTransport import TTransportException
# In-memory Cassandra-ish thingy... useful for unit tests. Maybe useful for other
# stuff too? No support for SuperColumns, but that should be easy enough to add.
import bisect
import copy
from cassandra.ttypes import NotFoundException, Column, ColumnPath, ColumnOrSuperColumn
class SSTable(object):