code stringlengths 1 1.49M | vector listlengths 0 7.38k | snippet listlengths 0 7.38k |
|---|---|---|
from progressbar import ProgressBar
from usbmux import usbmux
from util import hexdump, sizeof_fmt
import datetime
import hashlib
import struct
import os
CMD_DUMP = 0
CMD_PROXY = 1
kIOFlashStorageOptionRawPageIO = 0x002
kIOFlashStorageOptionBootPageIO = 0x100
class IOFlashStorageKitClient(object):
... | [
[
1,
0,
0.0101,
0.0101,
0,
0.66,
0,
349,
0,
1,
0,
0,
349,
0,
0
],
[
1,
0,
0.0202,
0.0101,
0,
0.66,
0.0833,
643,
0,
1,
0,
0,
643,
0,
0
],
[
1,
0,
0.0303,
0.0101,
0,
... | [
"from progressbar import ProgressBar",
"from usbmux import usbmux",
"from util import hexdump, sizeof_fmt",
"import datetime",
"import hashlib",
"import struct",
"import os",
"CMD_DUMP = 0",
"CMD_PROXY = 1",
"kIOFlashStorageOptionRawPageIO = 0x002",
"kIOFlashStorageOptionBootPageIO = 0x100",
... |
from construct import *
from structs import next_power_of_two, PAGETYPE_VFL, CEIL_DIVIDE
from vfl import vfl_check_checksum, _vfl_vsvfl_spare_data
"""
https://github.com/iDroid-Project/openiBoot/blob/master/vfl-vsvfl/vsvfl.c
https://github.com/iDroid-Project/openiBoot/blob/master/vfl-vsvfl/includes/vfl/vsvfl.h
... | [
[
1,
0,
0.0052,
0.0052,
0,
0.66,
0,
235,
0,
1,
0,
0,
235,
0,
0
],
[
1,
0,
0.0104,
0.0052,
0,
0.66,
0.2,
466,
0,
3,
0,
0,
466,
0,
0
],
[
1,
0,
0.0155,
0.0052,
0,
0.6... | [
"from construct import *",
"from structs import next_power_of_two, PAGETYPE_VFL, CEIL_DIVIDE",
"from vfl import vfl_check_checksum, _vfl_vsvfl_spare_data",
"\"\"\"\nhttps://github.com/iDroid-Project/openiBoot/blob/master/vfl-vsvfl/vsvfl.c\nhttps://github.com/iDroid-Project/openiBoot/blob/master/vfl-vsvfl/incl... |
from carver import NANDCarver
from construct.core import Struct
from construct.macros import ULInt32, ULInt16, Array, ULInt8, Padding
from pprint import pprint
from structs import SpareData
from util import hexdump
from vfl import VFL
import plistlib
"""
openiboot/plat-s5l8900/ftl.c
openiboot/plat-s5l8900/i... | [
[
1,
0,
0.0045,
0.0045,
0,
0.66,
0,
925,
0,
1,
0,
0,
925,
0,
0
],
[
1,
0,
0.0091,
0.0045,
0,
0.66,
0.0526,
880,
0,
1,
0,
0,
880,
0,
0
],
[
1,
0,
0.0136,
0.0045,
0,
... | [
"from carver import NANDCarver",
"from construct.core import Struct",
"from construct.macros import ULInt32, ULInt16, Array, ULInt8, Padding",
"from pprint import pprint",
"from structs import SpareData",
"from util import hexdump",
"from vfl import VFL",
"import plistlib",
"\"\"\"\nopeniboot/plat-s... |
from construct.core import Struct, Union
from construct.macros import *
#hardcoded iOS keys
META_KEY = "92a742ab08c969bf006c9412d3cc79a5".decode("hex")
FILESYSTEM_KEY = "f65dae950e906c42b254cc58fc78eece".decode("hex")
def next_power_of_two(z):
i = 1
while i < z:
i <<= 1
return i
def ... | [
[
1,
0,
0.012,
0.012,
0,
0.66,
0,
880,
0,
2,
0,
0,
880,
0,
0
],
[
1,
0,
0.0241,
0.012,
0,
0.66,
0.0417,
906,
0,
1,
0,
0,
906,
0,
0
],
[
14,
0,
0.0602,
0.012,
0,
0.6... | [
"from construct.core import Struct, Union",
"from construct.macros import *",
"META_KEY = \"92a742ab08c969bf006c9412d3cc79a5\".decode(\"hex\")",
"FILESYSTEM_KEY = \"f65dae950e906c42b254cc58fc78eece\".decode(\"hex\")",
"def next_power_of_two(z):\n i = 1\n while i < z:\n i <<= 1\n return i",
... |
from construct import *
from zipfile import crc32
GPT_HFS = "005346480000aa11aa1100306543ecac".decode("hex")
GPT_EMF = "00464d450000aa11aa1100306543ecac".decode("hex")
LWVM_partitionRecord = Struct("LWVM_partitionRecord",
String("type", 16),
String("... | [
[
1,
0,
0.0076,
0.0076,
0,
0.66,
0,
235,
0,
1,
0,
0,
235,
0,
0
],
[
1,
0,
0.0152,
0.0076,
0,
0.66,
0.0667,
93,
0,
1,
0,
0,
93,
0,
0
],
[
14,
0,
0.0303,
0.0076,
0,
0... | [
"from construct import *",
"from zipfile import crc32",
"GPT_HFS = \"005346480000aa11aa1100306543ecac\".decode(\"hex\")",
"GPT_EMF = \"00464d450000aa11aa1100306543ecac\".decode(\"hex\")",
"LWVM_partitionRecord = Struct(\"LWVM_partitionRecord\",\n String(\"type\", 16),\n ... |
from crypto.aes import AESdecryptCBC
from firmware.img2 import IMG2
from firmware.img3 import Img3, extract_img3s
from firmware.scfg import parse_SCFG
from hfs.emf import EMFVolume
from hfs.hfs import HFSVolume
from image import NANDImageSplitCEs, NANDImageFlat
from keystore.effaceable import check_effaceable_he... | [
[
1,
0,
0.0023,
0.0023,
0,
0.66,
0,
692,
0,
1,
0,
0,
692,
0,
0
],
[
1,
0,
0.0047,
0.0023,
0,
0.66,
0.0417,
573,
0,
1,
0,
0,
573,
0,
0
],
[
1,
0,
0.007,
0.0023,
0,
0... | [
"from crypto.aes import AESdecryptCBC",
"from firmware.img2 import IMG2",
"from firmware.img3 import Img3, extract_img3s",
"from firmware.scfg import parse_SCFG",
"from hfs.emf import EMFVolume",
"from hfs.hfs import HFSVolume",
"from image import NANDImageSplitCEs, NANDImageFlat",
"from keystore.effa... |
from array import array
from construct.core import Struct, Union
from construct.macros import *
from structs import next_power_of_two, CEIL_DIVIDE, PAGETYPE_VFL
import struct
"""
https://github.com/iDroid-Project/openiBoot/blob/master/plat-s5l8900/includes/s5l8900/ftl.h
https://github.com/iDroid-Project/openiB... | [
[
1,
0,
0.0053,
0.0053,
0,
0.66,
0,
80,
0,
1,
0,
0,
80,
0,
0
],
[
1,
0,
0.0106,
0.0053,
0,
0.66,
0.0909,
880,
0,
2,
0,
0,
880,
0,
0
],
[
1,
0,
0.016,
0.0053,
0,
0.6... | [
"from array import array",
"from construct.core import Struct, Union",
"from construct.macros import *",
"from structs import next_power_of_two, CEIL_DIVIDE, PAGETYPE_VFL",
"import struct",
"\"\"\"\nhttps://github.com/iDroid-Project/openiBoot/blob/master/plat-s5l8900/includes/s5l8900/ftl.h\nhttps://github... |
import os
import struct
import sys
"""
row-by-row dump
page = data + spare metadata + iokit return code + iokit return code 2
"""
class NANDImageFlat(object):
def __init__(self, filename, geometry):
flags = os.O_RDONLY
if sys.platform == "win32":
flags |= os.O_BINARY
... | [
[
1,
0,
0.0116,
0.0116,
0,
0.66,
0,
688,
0,
1,
0,
0,
688,
0,
0
],
[
1,
0,
0.0233,
0.0116,
0,
0.66,
0.1667,
399,
0,
1,
0,
0,
399,
0,
0
],
[
1,
0,
0.0349,
0.0116,
0,
... | [
"import os",
"import struct",
"import sys",
"\"\"\"\nrow-by-row dump\npage = data + spare metadata + iokit return code + iokit return code 2\n\"\"\"",
"class NANDImageFlat(object):\n def __init__(self, filename, geometry):\n flags = os.O_RDONLY\n if sys.platform == \"win32\":\n ... |
from array import array
from construct.core import Struct, Union
from construct.macros import *
from progressbar import ProgressBar
from structs import *
import struct
#https://github.com/iDroid-Project/openiBoot/blob/master/openiboot/ftl-yaftl/yaftl.c
YAFTL_CXT = Struct("YAFTL_CXT",
String("version", 4... | [
[
1,
0,
0.0028,
0.0028,
0,
0.66,
0,
80,
0,
1,
0,
0,
80,
0,
0
],
[
1,
0,
0.0056,
0.0028,
0,
0.66,
0.1111,
880,
0,
2,
0,
0,
880,
0,
0
],
[
1,
0,
0.0084,
0.0028,
0,
0.... | [
"from array import array",
"from construct.core import Struct, Union",
"from construct.macros import *",
"from progressbar import ProgressBar",
"from structs import *",
"import struct",
"YAFTL_CXT = Struct(\"YAFTL_CXT\",\n String(\"version\", 4),\n ULInt32(\"unknCalculatedValue0\"),\n ULInt32(\... |
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# usbmux.py - usbmux client library for Python
#
# Copyright (C) 2009 Hector Martin "marcan" <hector@marcansoft.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Soft... | [
[
1,
0,
0.0854,
0.0041,
0,
0.66,
0,
687,
0,
4,
0,
0,
687,
0,
0
],
[
7,
0,
0.1016,
0.0203,
0,
0.66,
0.1,
0,
0,
1,
0,
0,
0,
0,
0
],
[
1,
1,
0.0976,
0.0041,
1,
0.54,
... | [
"import socket, struct, select, sys",
"try:\n\timport plistlib\n\thaveplist = True\nexcept:\n\thaveplist = False",
"\timport plistlib",
"\thaveplist = True",
"\thaveplist = False",
"class MuxError(Exception):\n\tpass",
"class MuxVersionError(MuxError):\n\tpass",
"class SafeStreamSocket:\n\tdef __init_... |
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# tcprelay.py - TCP connection relay for usbmuxd
#
# Copyright (C) 2009 Hector Martin "marcan" <hector@marcansoft.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free So... | [
[
1,
0,
0.1419,
0.0068,
0,
0.66,
0,
643,
0,
1,
0,
0,
643,
0,
0
],
[
1,
0,
0.1486,
0.0068,
0,
0.66,
0.0417,
646,
0,
1,
0,
0,
646,
0,
0
],
[
1,
0,
0.1554,
0.0068,
0,
... | [
"import usbmux",
"import SocketServer",
"import select",
"from optparse import OptionParser",
"import sys",
"import threading",
"class SocketRelay(object):\n\tdef __init__(self, a, b, maxbuf=65535):\n\t\tself.a = a\n\t\tself.b = b\n\t\tself.atob = \"\"\n\t\tself.btoa = \"\"\n\t\tself.maxbuf = maxbuf\n\t... |
#!/usr/bin/python
from optparse import OptionParser
from hfs.emf import EMFVolume
from util.bdev import FileBlockDevice
import plistlib
def main():
parser = OptionParser(usage="emf_decrypter.py disk_image.bin")
parser.add_option("-w", "--nowrite", dest="write", action="store_false", default=True,
... | [
[
1,
0,
0.0571,
0.0286,
0,
0.66,
0,
323,
0,
1,
0,
0,
323,
0,
0
],
[
1,
0,
0.0857,
0.0286,
0,
0.66,
0.2,
338,
0,
1,
0,
0,
338,
0,
0
],
[
1,
0,
0.1143,
0.0286,
0,
0.6... | [
"from optparse import OptionParser",
"from hfs.emf import EMFVolume",
"from util.bdev import FileBlockDevice",
"import plistlib",
"def main():\n parser = OptionParser(usage=\"emf_decrypter.py disk_image.bin\")\n parser.add_option(\"-w\", \"--nowrite\", dest=\"write\", action=\"store_false\", default=T... |
#HAX
d=open("redsn0w_win_0.9.9b4/redsn0w.exe", "rb").read()
i = d.find("<key>IV</key>")
i = d.rfind("<?xml",0,i)
j = d.find("</plist>", i)
assert i != -1
assert j != -1
open("Keys.plist", "wb").write(d[i:j+8])
| [
[
14,
0,
0.25,
0.0833,
0,
0.66,
0,
355,
3,
0,
0,
0,
453,
10,
2
],
[
14,
0,
0.4167,
0.0833,
0,
0.66,
0.25,
826,
3,
1,
0,
0,
340,
10,
1
],
[
14,
0,
0.5,
0.0833,
0,
0.... | [
"d=open(\"redsn0w_win_0.9.9b4/redsn0w.exe\", \"rb\").read()",
"i = d.find(\"<key>IV</key>\")",
"i = d.rfind(\"<?xml\",0,i)",
"j = d.find(\"</plist>\", i)",
"open(\"Keys.plist\", \"wb\").write(d[i:j+8])"
] |
from construct import RepeatUntil
from construct.core import Struct, Union
from construct.macros import *
from crypto.aes import AESdecryptCBC
from crypto.aeswrap import AESUnwrap
from zipfile import crc32
import struct
Dkey = 0x446B6579
EMF = 0x454D4621
BAG1 = 0x42414731
DONE = 0x444f4e45 #locker sentine... | [
[
1,
0,
0.0145,
0.0145,
0,
0.66,
0,
235,
0,
1,
0,
0,
235,
0,
0
],
[
1,
0,
0.029,
0.0145,
0,
0.66,
0.0667,
880,
0,
2,
0,
0,
880,
0,
0
],
[
1,
0,
0.0435,
0.0145,
0,
0... | [
"from construct import RepeatUntil",
"from construct.core import Struct, Union",
"from construct.macros import *",
"from crypto.aes import AESdecryptCBC",
"from crypto.aeswrap import AESUnwrap",
"from zipfile import crc32",
"import struct",
"Dkey = 0x446B6579",
"EMF = 0x454D4621",
"BAG1 = 0x424147... |
from construct.core import Struct
from construct.macros import *
from construct import RepeatUntil, OneOf
from util import hexdump
SCFGItem = Struct("SCFGItem",
String("tag", 4),
String("data", 16, padchar="\x00")
)
SCFG = Struct("SCFG",
... | [
[
1,
0,
0.037,
0.037,
0,
0.66,
0,
880,
0,
1,
0,
0,
880,
0,
0
],
[
1,
0,
0.0741,
0.037,
0,
0.66,
0.1667,
906,
0,
1,
0,
0,
906,
0,
0
],
[
1,
0,
0.1111,
0.037,
0,
0.66... | [
"from construct.core import Struct",
"from construct.macros import *",
"from construct import RepeatUntil, OneOf",
"from util import hexdump",
"SCFGItem = Struct(\"SCFGItem\",\n String(\"tag\", 4),\n String(\"data\", 16, padchar=\"\\x00\")\n )",
"SCFG = S... |
from construct.core import Struct
from construct.macros import *
IMG2 = Struct("IMG2",
String("magic",4),
ULInt32("block_size"),
ULInt32("images_offset"),
ULInt32("images_block"),
ULInt32("images_length"),
Padding(0x1C),
... | [
[
1,
0,
0.0833,
0.0833,
0,
0.66,
0,
880,
0,
1,
0,
0,
880,
0,
0
],
[
1,
0,
0.1667,
0.0833,
0,
0.66,
0.5,
906,
0,
1,
0,
0,
906,
0,
0
],
[
14,
0,
0.6667,
0.75,
0,
0.66... | [
"from construct.core import Struct",
"from construct.macros import *",
"IMG2 = Struct(\"IMG2\",\n String(\"magic\",4),\n ULInt32(\"block_size\"),\n ULInt32(\"images_offset\"),\n ULInt32(\"images_block\"),\n ULInt32(\"images_length\"),\n ... |
from crypto.aes import AESdecryptCBC
from util import read_file, write_file
from util.ramdiskclient import RamdiskToolClient
import M2Crypto
import struct
import hashlib
import os
import sys
def decryptGID(data):
try:
client = RamdiskToolClient.get()
except:
return None
r = cl... | [
[
1,
0,
0.0034,
0.0034,
0,
0.66,
0,
692,
0,
1,
0,
0,
692,
0,
0
],
[
1,
0,
0.0069,
0.0034,
0,
0.66,
0.0769,
811,
0,
2,
0,
0,
811,
0,
0
],
[
1,
0,
0.0103,
0.0034,
0,
... | [
"from crypto.aes import AESdecryptCBC",
"from util import read_file, write_file",
"from util.ramdiskclient import RamdiskToolClient",
"import M2Crypto",
"import struct",
"import hashlib",
"import os",
"import sys",
"def decryptGID(data):\n try:\n client = RamdiskToolClient.get()\n excep... |
#!/usr/bin/python
import os
import sys
from hfs.emf import EMFVolume
from hfs.journal import do_emf_carving
from util.bdev import FileBlockDevice
if __name__ == "__main__":
if len(sys.argv) < 2:
print "Usage: emf_undelete.py disk_image.bin"
sys.exit(0)
filename = sys.argv[1]
volume = EMFVol... | [
[
1,
0,
0.0769,
0.0385,
0,
0.66,
0,
688,
0,
1,
0,
0,
688,
0,
0
],
[
1,
0,
0.1154,
0.0385,
0,
0.66,
0.2,
509,
0,
1,
0,
0,
509,
0,
0
],
[
1,
0,
0.1538,
0.0385,
0,
0.6... | [
"import os",
"import sys",
"from hfs.emf import EMFVolume",
"from hfs.journal import do_emf_carving",
"from util.bdev import FileBlockDevice",
"if __name__ == \"__main__\":\n if len(sys.argv) < 2:\n print(\"Usage: emf_undelete.py disk_image.bin\")\n sys.exit(0)\n filename = sys.argv[1]... |
from Crypto.Cipher import AES
from hashlib import sha1
from struct import unpack
import os
import re
MBDB_SIGNATURE = 'mbdb\x05\x00'
MASK_SYMBOLIC_LINK = 0xa000
MASK_REGULAR_FILE = 0x8000
MASK_DIRECTORY = 0x4000
def warn(msg):
print "WARNING: %s" % msg
class MBFileRecord(object):
def __i... | [
[
1,
0,
0.0057,
0.0057,
0,
0.66,
0,
663,
0,
1,
0,
0,
663,
0,
0
],
[
1,
0,
0.0114,
0.0057,
0,
0.66,
0.0909,
154,
0,
1,
0,
0,
154,
0,
0
],
[
1,
0,
0.017,
0.0057,
0,
0... | [
"from Crypto.Cipher import AES",
"from hashlib import sha1",
"from struct import unpack",
"import os",
"import re",
"MBDB_SIGNATURE = 'mbdb\\x05\\x00'",
"MASK_SYMBOLIC_LINK = 0xa000",
"MASK_REGULAR_FILE = 0x8000",
"MASK_DIRECTORY = 0x4000",
"def warn(msg):\n print(\"WARNING: %s\" % msg)",
" ... |
from crypto.PBKDF2 import PBKDF2
from crypto.aes import AESdecryptCBC
from util import read_file, write_file, makedirs, readPlist
from util.bplist import BPlistReader
import hashlib
import struct
import glob
import sys
import os
import re
"""
decrypt iOS 3 backup blob (metadata and file contents)
"""
d... | [
[
1,
0,
0.0147,
0.0147,
0,
0.66,
0,
428,
0,
1,
0,
0,
428,
0,
0
],
[
1,
0,
0.0294,
0.0147,
0,
0.66,
0.0833,
692,
0,
1,
0,
0,
692,
0,
0
],
[
1,
0,
0.0441,
0.0147,
0,
... | [
"from crypto.PBKDF2 import PBKDF2",
"from crypto.aes import AESdecryptCBC",
"from util import read_file, write_file, makedirs, readPlist",
"from util.bplist import BPlistReader",
"import hashlib",
"import struct",
"import glob",
"import sys",
"import os",
"import re",
"\"\"\"\ndecrypt iOS 3 back... |
import base64
from datetime import datetime
import getpass
import hashlib
from httplib import HTTPSConnection
import os
import plistlib
from pprint import pprint
import re
import struct
from chunkserver_pb2 import FileGroups
from crypto.aes import AESencryptCBC, AESdecryptCBC, AESdecryptCFB
from icloud_pb... | [
[
1,
0,
0.0031,
0.0031,
0,
0.66,
0,
177,
0,
1,
0,
0,
177,
0,
0
],
[
1,
0,
0.0062,
0.0031,
0,
0.66,
0.037,
426,
0,
1,
0,
0,
426,
0,
0
],
[
1,
0,
0.0093,
0.0031,
0,
0... | [
"import base64",
"from datetime import datetime",
"import getpass",
"import hashlib",
"from httplib import HTTPSConnection",
"import os",
"import plistlib",
"from pprint import pprint",
"import re",
"import struct",
"from chunkserver_pb2 import FileGroups",
"from crypto.aes import AESencryptCB... |
def decode_protobuf_array(data, obj_class):
n = len(data)
i = 0
res = []
while i < n:
(length, i) = _DecodeVarint(data, i)
l3 = obj_class()
l3.ParseFromString(data[i:i+length])
res.append(l3)
i += length
return res
def encode_protobuf_array(res):
... | [
[
2,
0,
0.1034,
0.1897,
0,
0.66,
0,
472,
0,
2,
1,
0,
0,
0,
5
],
[
14,
1,
0.0345,
0.0172,
1,
0.28,
0,
773,
3,
1,
0,
0,
890,
10,
1
],
[
14,
1,
0.0517,
0.0172,
1,
0.28... | [
"def decode_protobuf_array(data, obj_class):\n n = len(data)\n i = 0\n res = []\n while i < n:\n (length, i) = _DecodeVarint(data, i)\n l3 = obj_class()\n l3.ParseFromString(data[i:i+length])",
" n = len(data)",
" i = 0",
" res = []",
" while i < n:\n (len... |
#!/usr/bin/env python
from Crypto.Cipher import AES
from Crypto.Util import strxor
from struct import pack, unpack
def gcm_rightshift(vec):
for x in range(15, 0, -1):
c = vec[x] >> 1
c |= (vec[x-1] << 7) & 0x80
vec[x] = c
vec[0] >>= 1
return vec
def gcm_gf_mult(a, b):
mask = [... | [
[
1,
0,
0.0233,
0.0078,
0,
0.66,
0,
663,
0,
1,
0,
0,
663,
0,
0
],
[
1,
0,
0.031,
0.0078,
0,
0.66,
0.0909,
888,
0,
1,
0,
0,
888,
0,
0
],
[
1,
0,
0.0388,
0.0078,
0,
0... | [
"from Crypto.Cipher import AES",
"from Crypto.Util import strxor",
"from struct import pack, unpack",
"def gcm_rightshift(vec):\n for x in range(15, 0, -1):\n c = vec[x] >> 1\n c |= (vec[x-1] << 7) & 0x80\n vec[x] = c\n vec[0] >>= 1\n return vec",
" for x in range(15, 0, -1)... |
from Crypto.Util import number
CURVE_P = (2**255 - 19)
CURVE_A = 121665
def curve25519_monty(x1, z1, x2, z2, qmqp):
a = (x1 + z1) * (x2 - z2) % CURVE_P
b = (x1 - z1) * (x2 + z2) % CURVE_P
x4 = (a + b) * (a + b) % CURVE_P
e = (a - b) * (a - b) % CURVE_P
z4 = e * qmqp % CURVE_P
a ... | [
[
1,
0,
0.0135,
0.0135,
0,
0.66,
0,
888,
0,
1,
0,
0,
888,
0,
0
],
[
14,
0,
0.0405,
0.0135,
0,
0.66,
0.1667,
147,
4,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.0541,
0.0135,
0,
... | [
"from Crypto.Util import number",
"CURVE_P = (2**255 - 19)",
"CURVE_A = 121665",
"def curve25519_monty(x1, z1, x2, z2, qmqp):\n a = (x1 + z1) * (x2 - z2) % CURVE_P\n b = (x1 - z1) * (x2 + z2) % CURVE_P\n x4 = (a + b) * (a + b) % CURVE_P\n\n e = (a - b) * (a - b) % CURVE_P\n z4 = e * qmqp % CURV... |
from ctypes import *
import sys
if sys.platform == "darwin":
kCCOptionECBMode=2
kCCAlgorithmAES128=0
kCCEncrypt=0
kCCDecrypt=1
Security = cdll.LoadLibrary("/System/Library/Frameworks/Security.framework/Security")
#http://developer.apple.com/library/ios/documentation/System/Conceptual... | [
[
1,
0,
0.0061,
0.0061,
0,
0.66,
0,
182,
0,
1,
0,
0,
182,
0,
0
],
[
1,
0,
0.0123,
0.0061,
0,
0.66,
0.1667,
509,
0,
1,
0,
0,
509,
0,
0
],
[
4,
0,
0.4509,
0.8589,
0,
... | [
"from ctypes import *",
"import sys",
"if sys.platform == \"darwin\":\n kCCOptionECBMode=2\n kCCAlgorithmAES128=0\n kCCEncrypt=0\n kCCDecrypt=1\n\n Security = cdll.LoadLibrary(\"/System/Library/Frameworks/Security.framework/Security\")\n #http://developer.apple.com/library/ios/documentation/Sy... |
import struct
from Crypto.Cipher import AES
"""
http://www.ietf.org/rfc/rfc3394.txt
quick'n'dirty AES wrap implementation
used by iOS 4 KeyStore kernel extension for wrapping/unwrapping encryption keys
"""
def unpack64bit(s):
return struct.unpack(">Q",s)[0]
def pack64bit(s):
return struc... | [
[
1,
0,
0.0143,
0.0143,
0,
0.66,
0,
399,
0,
1,
0,
0,
399,
0,
0
],
[
1,
0,
0.0286,
0.0143,
0,
0.66,
0.1429,
663,
0,
1,
0,
0,
663,
0,
0
],
[
8,
0,
0.0857,
0.0714,
0,
... | [
"import struct",
"from Crypto.Cipher import AES",
"\"\"\"\n http://www.ietf.org/rfc/rfc3394.txt\n quick'n'dirty AES wrap implementation\n used by iOS 4 KeyStore kernel extension for wrapping/unwrapping encryption keys\n\"\"\"",
"def unpack64bit(s):\n return struct.unpack(\">Q\",s)[0]",
" retu... |
from Crypto.Cipher import AES
ZEROIV = "\x00"*16
def removePadding(blocksize, s):
'Remove rfc 1423 padding from string.'
n = ord(s[-1]) # last byte contains number of padding bytes
if n > blocksize or n > len(s):
raise Exception('invalid padding')
return s[:-n]
def AESdecryptCBC(da... | [
[
1,
0,
0.025,
0.025,
0,
0.66,
0,
663,
0,
1,
0,
0,
663,
0,
0
],
[
14,
0,
0.075,
0.025,
0,
0.66,
0.2,
654,
4,
0,
0,
0,
0,
0,
0
],
[
2,
0,
0.1625,
0.15,
0,
0.66,
... | [
"from Crypto.Cipher import AES",
"ZEROIV = \"\\x00\"*16",
"def removePadding(blocksize, s):\n 'Remove rfc 1423 padding from string.'\n n = ord(s[-1]) # last byte contains number of padding bytes\n if n > blocksize or n > len(s):\n raise Exception('invalid padding')\n return s[:-n]",
" 'R... |
#!/usr/bin/env python
import sys, os
from PyQt4 import QtGui, QtCore
from backups.backup4 import MBDB
from keychain.keychain4 import Keychain4
from util.bplist import BPlistReader
from keystore.keybag import Keybag
from util import readPlist
class KeychainTreeWidget(QtGui.QTreeWidget):
def __init__(sel... | [
[
1,
0,
0.0192,
0.0064,
0,
0.66,
0,
509,
0,
2,
0,
0,
509,
0,
0
],
[
1,
0,
0.0256,
0.0064,
0,
0.66,
0.0714,
154,
0,
2,
0,
0,
154,
0,
0
],
[
1,
0,
0.0321,
0.0064,
0,
... | [
"import sys, os",
"from PyQt4 import QtGui, QtCore",
"from backups.backup4 import MBDB",
"from keychain.keychain4 import Keychain4",
"from util.bplist import BPlistReader",
"from keystore.keybag import Keybag",
"from util import readPlist",
"class KeychainTreeWidget(QtGui.QTreeWidget):\n def __init... |
import base64
def chunks(l, n):
return (l[i:i+n] for i in xrange(0, len(l), n))
def RSA_KEY_DER_to_PEM(data):
a = ["-----BEGIN RSA PRIVATE KEY-----"]
a.extend(chunks(base64.b64encode(data),64))
a.append("-----END RSA PRIVATE KEY-----")
return "\n".join(a)
def CERT_DER_to_PEM(data):
... | [
[
1,
0,
0.0625,
0.0625,
0,
0.66,
0,
177,
0,
1,
0,
0,
177,
0,
0
],
[
2,
0,
0.2188,
0.125,
0,
0.66,
0.3333,
284,
0,
2,
1,
0,
0,
0,
2
],
[
13,
1,
0.25,
0.0625,
1,
0.92... | [
"import base64",
"def chunks(l, n):\n return (l[i:i+n] for i in xrange(0, len(l), n))",
" return (l[i:i+n] for i in xrange(0, len(l), n))",
"def RSA_KEY_DER_to_PEM(data):\n a = [\"-----BEGIN RSA PRIVATE KEY-----\"]\n a.extend(chunks(base64.b64encode(data),64))\n a.append(\"-----END RSA PRIVATE ... |
import struct
def tlvToDict(blob):
d = {}
for tag,data in loopTLVBlocks(blob):
d[tag] = data
return d
def tlvToList(blob):
return list(loopTLVBlocks(blob))
def loopTLVBlocks(blob):
i = 0
while i + 8 <= len(blob):
tag = blob[i:i+4]
length = struct.unp... | [
[
1,
0,
0.0526,
0.0526,
0,
0.66,
0,
399,
0,
1,
0,
0,
399,
0,
0
],
[
2,
0,
0.2632,
0.2632,
0,
0.66,
0.3333,
671,
0,
1,
1,
0,
0,
0,
1
],
[
14,
1,
0.2105,
0.0526,
1,
0... | [
"import struct",
"def tlvToDict(blob):\n d = {}\n for tag,data in loopTLVBlocks(blob):\n d[tag] = data\n return d",
" d = {}",
" for tag,data in loopTLVBlocks(blob):\n d[tag] = data",
" d[tag] = data",
" return d",
"def tlvToList(blob):\n return list(loopTLVBloc... |
import plistlib
import struct
import socket
from datetime import datetime
from progressbar import ProgressBar, Percentage, Bar, SimpleProgress, ETA
from usbmux import usbmux
from util import sizeof_fmt
kIOAESAcceleratorEncrypt = 0
kIOAESAcceleratorDecrypt = 1
kIOAESAcceleratorGIDMask = 0x3E8
kIOAESAccele... | [
[
1,
0,
0.0058,
0.0058,
0,
0.66,
0,
592,
0,
1,
0,
0,
592,
0,
0
],
[
1,
0,
0.0116,
0.0058,
0,
0.66,
0.0833,
399,
0,
1,
0,
0,
399,
0,
0
],
[
1,
0,
0.0174,
0.0058,
0,
... | [
"import plistlib",
"import struct",
"import socket",
"from datetime import datetime",
"from progressbar import ProgressBar, Percentage, Bar, SimpleProgress, ETA",
"from usbmux import usbmux",
"from util import sizeof_fmt",
"kIOAESAcceleratorEncrypt = 0",
"kIOAESAcceleratorDecrypt = 1",
"kIOAESAcce... |
from keystore.keybag import Keybag
from keystore.effaceable import EffaceableLockers
from util.ramdiskclient import RamdiskToolClient
import plistlib
COMPLEXITY={
0: "4 digits",
1: "n digits",
2: "n alphanum"
}
def checkPasscodeComplexity(data_volume):
p... | [
[
1,
0,
0.0141,
0.0141,
0,
0.66,
0,
856,
0,
1,
0,
0,
856,
0,
0
],
[
1,
0,
0.0282,
0.0141,
0,
0.66,
0.1429,
912,
0,
1,
0,
0,
912,
0,
0
],
[
1,
0,
0.0423,
0.0141,
0,
... | [
"from keystore.keybag import Keybag",
"from keystore.effaceable import EffaceableLockers",
"from util.ramdiskclient import RamdiskToolClient",
"import plistlib",
"COMPLEXITY={\n 0: \"4 digits\",\n 1: \"n digits\",\n 2: \"n alphanum\"\n }",
"def checkPasscodeComp... |
"""
http://github.com/farcaller/bplist-python/blob/master/bplist.py
"""
import struct
import plistlib
from datetime import datetime, timedelta
class BPListWriter(object):
def __init__(self, objects):
self.bplist = ""
self.objects = objects
def binary(self):
'''binary -> string
... | [
[
8,
0,
0.008,
0.012,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.0159,
0.004,
0,
0.66,
0.2,
399,
0,
1,
0,
0,
399,
0,
0
],
[
1,
0,
0.0199,
0.004,
0,
0.66,
0... | [
"\"\"\"\nhttp://github.com/farcaller/bplist-python/blob/master/bplist.py\n\"\"\"",
"import struct",
"import plistlib",
"from datetime import datetime, timedelta",
"class BPListWriter(object):\n def __init__(self, objects):\n self.bplist = \"\"\n self.objects = objects\n\n def binary(self... |
"""
/**************************************************************
LZSS.C -- A Data Compression Program
***************************************************************
4/6/1989 Haruhiko Okumura
Use, distribute, and modify this program freely.
Please send me your improved versions.
PC-VAN ... | [
[
8,
0,
0.1479,
0.2817,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.2958,
0.0141,
0,
0.66,
0.1429,
80,
0,
1,
0,
0,
80,
0,
0
],
[
1,
0,
0.3099,
0.0141,
0,
0.66,
... | [
"\"\"\"\n/**************************************************************\n LZSS.C -- A Data Compression Program\n***************************************************************\n 4/6/1989 Haruhiko Okumura\n Use, distribute, and modify this program freely.\n Please send me your improved versions.\n P... |
import os
import sys
from util import sizeof_fmt, hexdump
from progressbar import ProgressBar
from crypto.aes import AESdecryptCBC, AESencryptCBC
class FileBlockDevice(object):
def __init__(self, filename, offset=0, write=False):
flag = os.O_RDONLY if not write else os.O_RDWR
if sys.platfo... | [
[
1,
0,
0.007,
0.007,
0,
0.66,
0,
688,
0,
1,
0,
0,
688,
0,
0
],
[
1,
0,
0.0141,
0.007,
0,
0.66,
0.1429,
509,
0,
1,
0,
0,
509,
0,
0
],
[
1,
0,
0.0211,
0.007,
0,
0.66... | [
"import os",
"import sys",
"from util import sizeof_fmt, hexdump",
"from progressbar import ProgressBar",
"from crypto.aes import AESdecryptCBC, AESencryptCBC",
"class FileBlockDevice(object):\n def __init__(self, filename, offset=0, write=False):\n flag = os.O_RDONLY if not write else os.O_RDWR... |
def print_table(title, headers, rows):
widths = []
for i in xrange(len(headers)):
z = map(len, [str(row[i]) for row in rows])
z.append(len(headers[i]))
widths.append(max(z))
width = sum(widths) + len(headers) + 1
print "-"* width
print "|" + title.center... | [
[
2,
0,
0.5345,
0.9655,
0,
0.66,
0,
389,
0,
3,
0,
0,
0,
0,
29
],
[
14,
1,
0.1034,
0.0345,
1,
0.29,
0,
291,
0,
0,
0,
0,
0,
5,
0
],
[
6,
1,
0.2241,
0.1379,
1,
0.29,
... | [
"def print_table(title, headers, rows):\n widths = []\n \n for i in xrange(len(headers)):\n z = map(len, [str(row[i]) for row in rows])\n z.append(len(headers[i]))\n widths.append(max(z))",
" widths = []",
" for i in xrange(len(headers)):\n z = map(len, [str(row[i]) fo... |
import glob
import plistlib
import os
from bplist import BPlistReader
import cPickle
import gzip
def read_file(filename):
f = open(filename, "rb")
data = f.read()
f.close()
return data
def write_file(filename,data):
f = open(filename, "wb")
f.write(data)
f.close()
def ma... | [
[
1,
0,
0.0081,
0.0081,
0,
0.66,
0,
958,
0,
1,
0,
0,
958,
0,
0
],
[
1,
0,
0.0163,
0.0081,
0,
0.66,
0.0455,
592,
0,
1,
0,
0,
592,
0,
0
],
[
1,
0,
0.0244,
0.0081,
0,
... | [
"import glob",
"import plistlib",
"import os",
"from bplist import BPlistReader",
"import cPickle",
"import gzip",
"def read_file(filename):\n f = open(filename, \"rb\")\n data = f.read()\n f.close()\n return data",
" f = open(filename, \"rb\")",
" data = f.read()",
" f.close(... |
#!/usr/bin/python
from optparse import OptionParser
from keystore.keybag import Keybag
from keychain import keychain_load
from keychain.managedconfiguration import bruteforce_old_pass
from util import readPlist
from keychain.keychain4 import Keychain4
import plistlib
def main():
parser = OptionParser(usage="%prog ... | [
[
1,
0,
0.0274,
0.0137,
0,
0.66,
0,
323,
0,
1,
0,
0,
323,
0,
0
],
[
1,
0,
0.0411,
0.0137,
0,
0.66,
0.125,
856,
0,
1,
0,
0,
856,
0,
0
],
[
1,
0,
0.0548,
0.0137,
0,
0... | [
"from optparse import OptionParser",
"from keystore.keybag import Keybag",
"from keychain import keychain_load",
"from keychain.managedconfiguration import bruteforce_old_pass",
"from util import readPlist",
"from keychain.keychain4 import Keychain4",
"import plistlib",
"def main():\n parser = Opti... |
from store import PlistKeychain, SQLiteKeychain
from util import write_file
from util.asciitables import print_table
from util.bplist import BPlistReader
from util.cert import RSA_KEY_DER_to_PEM, CERT_DER_to_PEM
import M2Crypto
import hashlib
import plistlib
import sqlite3
import string
import struct
KSECA... | [
[
1,
0,
0.0042,
0.0042,
0,
0.66,
0,
354,
0,
2,
0,
0,
354,
0,
0
],
[
1,
0,
0.0084,
0.0042,
0,
0.66,
0.0714,
811,
0,
1,
0,
0,
811,
0,
0
],
[
1,
0,
0.0127,
0.0042,
0,
... | [
"from store import PlistKeychain, SQLiteKeychain",
"from util import write_file",
"from util.asciitables import print_table",
"from util.bplist import BPlistReader",
"from util.cert import RSA_KEY_DER_to_PEM, CERT_DER_to_PEM",
"import M2Crypto",
"import hashlib",
"import plistlib",
"import sqlite3",... |
from crypto.aes import AESdecryptCBC
import struct
"""
iOS 4 keychain-2.db data column format
version 0x00000000
key class 0x00000008
kSecAttrAccessibleWhenUnlocked 6
kSecAttrAccessibleAfterFirstUnlock 7
... | [
[
1,
0,
0.0109,
0.0109,
0,
0.66,
0,
692,
0,
1,
0,
0,
692,
0,
0
],
[
1,
0,
0.0217,
0.0109,
0,
0.66,
0.1429,
399,
0,
1,
0,
0,
399,
0,
0
],
[
8,
0,
0.1141,
0.1522,
0,
... | [
"from crypto.aes import AESdecryptCBC",
"import struct",
"\"\"\"\n iOS 4 keychain-2.db data column format\n\n version 0x00000000\n key class 0x00000008\n kSecAttrAccessibleWhenUnlocked 6\n kSecAttrAccessibleAfterFirstUnlock 7\n ... |
"""
0
1:MCSHA256DigestWithSalt
2:SecKeyFromPassphraseDataHMACSHA1
"""
from crypto.PBKDF2 import PBKDF2
import plistlib
import hashlib
SALT1 = "F92F024CA2CB9754".decode("hex")
hashMethods={
1: (lambda p,salt:hashlib.sha256(SALT1 + p)),
2: (lambda p,salt:PBKDF2(p, salt, iterations=1000).read(20))
... | [
[
8,
0,
0.1111,
0.1852,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.2222,
0.037,
0,
0.66,
0.1667,
428,
0,
1,
0,
0,
428,
0,
0
],
[
1,
0,
0.2593,
0.037,
0,
0.66,
... | [
"\"\"\"\n0\n1:MCSHA256DigestWithSalt\n2:SecKeyFromPassphraseDataHMACSHA1\n\"\"\"",
"from crypto.PBKDF2 import PBKDF2",
"import plistlib",
"import hashlib",
"SALT1 = \"F92F024CA2CB9754\".decode(\"hex\")",
"hashMethods={\n 1: (lambda p,salt:hashlib.sha256(SALT1 + p)),\n 2: (lambda p,salt:PBKDF2(p, sal... |
import plistlib
import sqlite3
import struct
from util import readPlist
class KeychainStore(object):
def __init__(self):
pass
def convertDict(self, d):
return d
def returnResults(self, r):
for a in r:
yield self.convertDict(a)
def get_i... | [
[
1,
0,
0.0179,
0.0179,
0,
0.66,
0,
592,
0,
1,
0,
0,
592,
0,
0
],
[
1,
0,
0.0357,
0.0179,
0,
0.66,
0.1667,
790,
0,
1,
0,
0,
790,
0,
0
],
[
1,
0,
0.0536,
0.0179,
0,
... | [
"import plistlib",
"import sqlite3",
"import struct",
"from util import readPlist",
"class KeychainStore(object):\n def __init__(self):\n pass\n \n def convertDict(self, d):\n return d\n \n def returnResults(self, r):",
" def __init__(self):\n pass",
" def conve... |
import sqlite3
from keychain3 import Keychain3
from keychain4 import Keychain4
def keychain_load(filename, keybag, key835):
version = sqlite3.connect(filename).execute("SELECT version FROM tversion").fetchone()[0]
#print "Keychain version : %d" % version
if version == 3:
return Keychain3(fi... | [
[
1,
0,
0.0833,
0.0833,
0,
0.66,
0,
790,
0,
1,
0,
0,
790,
0,
0
],
[
1,
0,
0.1667,
0.0833,
0,
0.66,
0.3333,
748,
0,
1,
0,
0,
748,
0,
0
],
[
1,
0,
0.25,
0.0833,
0,
0.... | [
"import sqlite3",
"from keychain3 import Keychain3",
"from keychain4 import Keychain4",
"def keychain_load(filename, keybag, key835):\n version = sqlite3.connect(filename).execute(\"SELECT version FROM tversion\").fetchone()[0]\n #print \"Keychain version : %d\" % version\n if version == 3:\n ... |
from keychain import Keychain
from crypto.aes import AESdecryptCBC, AESencryptCBC
import hashlib
class Keychain3(Keychain):
def __init__(self, filename, key835=None):
Keychain.__init__(self, filename)
self.key835 = key835
def decrypt_data(self, data):
if data == None:... | [
[
1,
0,
0.0227,
0.0227,
0,
0.66,
0,
466,
0,
1,
0,
0,
466,
0,
0
],
[
1,
0,
0.0455,
0.0227,
0,
0.66,
0.3333,
692,
0,
2,
0,
0,
692,
0,
0
],
[
1,
0,
0.0682,
0.0227,
0,
... | [
"from keychain import Keychain",
"from crypto.aes import AESdecryptCBC, AESencryptCBC",
"import hashlib",
"class Keychain3(Keychain):\n def __init__(self, filename, key835=None):\n Keychain.__init__(self, filename)\n self.key835 = key835\n \n def decrypt_data(self, data):\n i... |
import random
import md5
from django.db import models
from ft_auth.models import OAuthAccessToken
STATUS_CODES = {
1 : 'In Queue (%s ahead of you)',
2 : 'Initial Processing',
3 : 'Importing into Fusion Tables',
4 : 'Complete',
6 : 'Error'
}
class shapeUpload(models.Model):
"""An upload -- includes location ... | [
[
1,
0,
0.0204,
0.0204,
0,
0.66,
0,
715,
0,
1,
0,
0,
715,
0,
0
],
[
1,
0,
0.0408,
0.0204,
0,
0.66,
0.2,
604,
0,
1,
0,
0,
604,
0,
0
],
[
1,
0,
0.0816,
0.0204,
0,
0.6... | [
"import random",
"import md5",
"from django.db import models",
"from ft_auth.models import OAuthAccessToken",
"STATUS_CODES = {\n 1 : 'In Queue (%s ahead of you)',\n 2 : 'Initial Processing',\n 3 : 'Importing into Fusion Tables',\n 4 : 'Complete',\n 6 : 'Error'\n}",
"class shapeUpload(models.Model):\n \"... |
#!/usr/bin/env python
#
# Copyright 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or ... | [
[
1,
0,
0.64,
0.04,
0,
0.66,
0,
341,
0,
1,
0,
0,
341,
0,
0
],
[
1,
0,
0.68,
0.04,
0,
0.66,
0.5,
547,
0,
1,
0,
0,
547,
0,
0
],
[
14,
0,
0.88,
0.28,
0,
0.66,
1,
... | [
"from django.conf.urls.defaults import *",
"from views import *",
"urlpatterns = patterns('',\n\n (r'^upload/$', generic_import),\n url(r'^uploads/(?P<upload_ids>[a-gA-F\\d]*)/$', upload_detail, name=\"upload_detail\"),\n (r'^$', static, {'template':'index.html'}),\n\n)"
] |
from django.conf import settings
from django.conf.urls.defaults import *
from django.contrib import databrowse
from django.contrib import admin
admin.autodiscover()
#from shapeft.custom_admin import editor
#from registration.views import register
urlpatterns = patterns('',
(r'^_admin_/', include(admin.site.url... | [
[
1,
0,
0.0357,
0.0357,
0,
0.66,
0,
128,
0,
1,
0,
0,
128,
0,
0
],
[
1,
0,
0.0714,
0.0357,
0,
0.66,
0.2,
341,
0,
1,
0,
0,
341,
0,
0
],
[
1,
0,
0.1429,
0.0357,
0,
0.6... | [
"from django.conf import settings",
"from django.conf.urls.defaults import *",
"from django.contrib import databrowse",
"from django.contrib import admin",
"admin.autodiscover()",
"urlpatterns = patterns('',\n (r'^_admin_/', include(admin.site.urls)),\n# (r'^editor/(.*)', editor.root),\n (r'^data... |
from django import forms
from django.contrib.auth.models import User
class ContactForm(forms.Form):
name = forms.CharField(max_length=100,
help_text="Full Name", widget=forms.TextInput(attrs={'size':'40'}),required=False)
subject = forms.CharField(max_length=100,
help_text="Subject of ... | [
[
1,
0,
0.0667,
0.0667,
0,
0.66,
0,
294,
0,
1,
0,
0,
294,
0,
0
],
[
1,
0,
0.1333,
0.0667,
0,
0.66,
0.5,
808,
0,
1,
0,
0,
808,
0,
0
],
[
3,
0,
0.6333,
0.8,
0,
0.66,
... | [
"from django import forms",
"from django.contrib.auth.models import User",
"class ContactForm(forms.Form):\n name = forms.CharField(max_length=100,\n help_text=\"Full Name\", widget=forms.TextInput(attrs={'size':'40'}),required=False)\n subject = forms.CharField(max_length=100,\n he... |
from django.conf.urls.defaults import *
from views import *
urlpatterns = patterns('',
(r'^', contact),
(r'^thanks/$', static, {'template':'contact_thanks.html'}),
)
| [
[
1,
0,
0.125,
0.125,
0,
0.66,
0,
341,
0,
1,
0,
0,
341,
0,
0
],
[
1,
0,
0.25,
0.125,
0,
0.66,
0.5,
547,
0,
1,
0,
0,
547,
0,
0
],
[
14,
0,
0.6875,
0.5,
0,
0.66,
... | [
"from django.conf.urls.defaults import *",
"from views import *",
"urlpatterns = patterns('',\n (r'^', contact),\n (r'^thanks/$', static, {'template':'contact_thanks.html'}),\n)"
] |
#r!/usr/bin/env python
#
# Copyright 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or... | [
[
1,
0,
0.3333,
0.0196,
0,
0.66,
0,
128,
0,
1,
0,
0,
128,
0,
0
],
[
1,
0,
0.3529,
0.0196,
0,
0.66,
0.2,
852,
0,
1,
0,
0,
852,
0,
0
],
[
1,
0,
0.3725,
0.0196,
0,
0.6... | [
"from django.conf import settings",
"from django.shortcuts import render_to_response",
"from django.http import HttpResponseRedirect",
"from forms import *",
"def static(request, template):\n return render_to_response(template, RequestContext(request,{}))",
" return render_to_response(template, RequestC... |
#!/usr/bin/env python
#
# Copyright 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or ... | [
[
1,
0,
0.4146,
0.0244,
0,
0.66,
0,
40,
0,
1,
0,
0,
40,
0,
0
],
[
1,
0,
0.439,
0.0244,
0,
0.66,
0.3333,
886,
0,
1,
0,
0,
886,
0,
0
],
[
3,
0,
0.622,
0.2439,
0,
0.66... | [
"from django.db import models",
"from django.contrib.gis.geos import Point",
"class OAuthRequestToken(models.Model):\n \"\"\"OAuth Request Token.\"\"\"\n session_key = models.CharField(max_length=250)\n ft_token = models.CharField(max_length=250)\n ft_token_secret = models.CharField(max_length=250)\... |
#!/usr/bin/env python
#
# Copyright 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or ... | [
[
1,
0,
0.68,
0.04,
0,
0.66,
0,
341,
0,
1,
0,
0,
341,
0,
0
],
[
1,
0,
0.72,
0.04,
0,
0.66,
0.5,
547,
0,
2,
0,
0,
547,
0,
0
],
[
14,
0,
0.9,
0.24,
0,
0.66,
1,
... | [
"from django.conf.urls.defaults import *",
"from views import FTVerify, FTAuthenticate",
"urlpatterns = patterns('',\n\n (r'^FTVerify/$', FTVerify),\n (r'^FTAuthenticate/$', FTAuthenticate),\n\n)"
] |
#!/usr/bin/env python
#
# Copyright 2007 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or ... | [
[
1,
0,
0.1356,
0.0085,
0,
0.66,
0,
688,
0,
1,
0,
0,
688,
0,
0
],
[
1,
0,
0.1441,
0.0085,
0,
0.66,
0.0588,
715,
0,
1,
0,
0,
715,
0,
0
],
[
1,
0,
0.1525,
0.0085,
0,
... | [
"import os",
"import random",
"from datetime import datetime",
"from django.conf import settings",
"from django.shortcuts import render_to_response, get_object_or_404",
"from django.http import HttpResponse, HttpResponseRedirect, HttpResponseForbidden, Http404",
"from django.template import RequestConte... |
#!/usr/bin/env python
from django.core.management import execute_manager
try:
import settings # Assumed to be in the same directory.
except ImportError:
import sys
sys.stderr.write("Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized things.\nYou'll have to ... | [
[
1,
0,
0.1818,
0.0909,
0,
0.66,
0,
879,
0,
1,
0,
0,
879,
0,
0
],
[
7,
0,
0.5,
0.5455,
0,
0.66,
0.5,
0,
0,
1,
0,
0,
0,
0,
2
],
[
1,
1,
0.3636,
0.0909,
1,
0.05,
... | [
"from django.core.management import execute_manager",
"try:\n import settings # Assumed to be in the same directory.\nexcept ImportError:\n import sys\n sys.stderr.write(\"Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized things.\\nYou'll have to run dj... |
from ._OptflowLK import *
| [
[
1,
0,
1,
1,
0,
0.66,
0,
994,
0,
1,
0,
0,
994,
0,
0
]
] | [
"from ._OptflowLK import *"
] |
#====================================================================
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you ... | [
[
1,
0,
0.3514,
0.0135,
0,
0.66,
0,
688,
0,
1,
0,
0,
688,
0,
0
],
[
1,
0,
0.3649,
0.0135,
0,
0.66,
0.1111,
540,
0,
1,
0,
0,
540,
0,
0
],
[
1,
0,
0.3784,
0.0135,
0,
... | [
"import os",
"import re",
"import tempfile",
"import shutil",
"ignore_pattern = re.compile('^(.svn|target|bin|classes)')",
"java_pattern = re.compile('^.*\\.java')",
"annot_pattern = re.compile('import org\\.apache\\.http\\.annotation\\.')",
"def process_dir(dir):\n files = os.listdir(dir)\n for... |
#!/usr/bin/python2.6
#
# Simple http server to emulate api.playfoursquare.com
import logging
import shutil
import sys
import urlparse
import SimpleHTTPServer
import BaseHTTPServer
class RequestHandler(BaseHTTPServer.BaseHTTPRequestHandler):
"""Handle playfoursquare.com requests, for testing."""
def do_GET(self... | [
[
1,
0,
0.0588,
0.0118,
0,
0.66,
0,
715,
0,
1,
0,
0,
715,
0,
0
],
[
1,
0,
0.0706,
0.0118,
0,
0.66,
0.125,
614,
0,
1,
0,
0,
614,
0,
0
],
[
1,
0,
0.0824,
0.0118,
0,
0... | [
"import logging",
"import shutil",
"import sys",
"import urlparse",
"import SimpleHTTPServer",
"import BaseHTTPServer",
"class RequestHandler(BaseHTTPServer.BaseHTTPRequestHandler):\n \"\"\"Handle playfoursquare.com requests, for testing.\"\"\"\n\n def do_GET(self):\n logging.warn('do_GET: %s, %s',... |
#!/usr/bin/python
import os
import subprocess
import sys
BASEDIR = '../main/src/com/joelapenna/foursquare'
TYPESDIR = '../captures/types/v1'
captures = sys.argv[1:]
if not captures:
captures = os.listdir(TYPESDIR)
for f in captures:
basename = f.split('.')[0]
javaname = ''.join([c.capitalize() for c in basena... | [
[
1,
0,
0.1111,
0.037,
0,
0.66,
0,
688,
0,
1,
0,
0,
688,
0,
0
],
[
1,
0,
0.1481,
0.037,
0,
0.66,
0.1429,
394,
0,
1,
0,
0,
394,
0,
0
],
[
1,
0,
0.1852,
0.037,
0,
0.6... | [
"import os",
"import subprocess",
"import sys",
"BASEDIR = '../main/src/com/joelapenna/foursquare'",
"TYPESDIR = '../captures/types/v1'",
"captures = sys.argv[1:]",
"if not captures:\n captures = os.listdir(TYPESDIR)",
" captures = os.listdir(TYPESDIR)",
"for f in captures:\n basename = f.split('... |
#!/usr/bin/python
"""
Pull a oAuth protected page from foursquare.
Expects ~/.oget to contain (one on each line):
CONSUMER_KEY
CONSUMER_KEY_SECRET
USERNAME
PASSWORD
Don't forget to chmod 600 the file!
"""
import httplib
import os
import re
import sys
import urllib
import urllib2
import urlparse
import user
from xml.... | [
[
8,
0,
0.0631,
0.0991,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.1261,
0.009,
0,
0.66,
0.05,
2,
0,
1,
0,
0,
2,
0,
0
],
[
1,
0,
0.1351,
0.009,
0,
0.66,
0.... | [
"\"\"\"\nPull a oAuth protected page from foursquare.\n\nExpects ~/.oget to contain (one on each line):\nCONSUMER_KEY\nCONSUMER_KEY_SECRET\nUSERNAME\nPASSWORD",
"import httplib",
"import os",
"import re",
"import sys",
"import urllib",
"import urllib2",
"import urlparse",
"import user",
"from xml.... |
#!/usr/bin/python
import datetime
import sys
import textwrap
import common
from xml.dom import pulldom
PARSER = """\
/**
* Copyright 2009 Joe LaPenna
*/
package com.joelapenna.foursquare.parsers;
import com.joelapenna.foursquare.Foursquare;
import com.joelapenna.foursquare.error.FoursquareError;
import com.joel... | [
[
1,
0,
0.0201,
0.0067,
0,
0.66,
0,
426,
0,
1,
0,
0,
426,
0,
0
],
[
1,
0,
0.0268,
0.0067,
0,
0.66,
0.0769,
509,
0,
1,
0,
0,
509,
0,
0
],
[
1,
0,
0.0336,
0.0067,
0,
... | [
"import datetime",
"import sys",
"import textwrap",
"import common",
"from xml.dom import pulldom",
"PARSER = \"\"\"\\\n/**\n * Copyright 2009 Joe LaPenna\n */\n\npackage com.joelapenna.foursquare.parsers;\n\nimport com.joelapenna.foursquare.Foursquare;",
"BOOLEAN_STANZA = \"\"\"\\\n } else i... |
#!/usr/bin/python
import logging
from xml.dom import minidom
from xml.dom import pulldom
BOOLEAN = "boolean"
STRING = "String"
GROUP = "Group"
# Interfaces that all FoursquareTypes implement.
DEFAULT_INTERFACES = ['FoursquareType']
# Interfaces that specific FoursqureTypes implement.
INTERFACES = {
}
DEFAULT_CLA... | [
[
1,
0,
0.0263,
0.0088,
0,
0.66,
0,
715,
0,
1,
0,
0,
715,
0,
0
],
[
1,
0,
0.0439,
0.0088,
0,
0.66,
0.0833,
290,
0,
1,
0,
0,
290,
0,
0
],
[
1,
0,
0.0526,
0.0088,
0,
... | [
"import logging",
"from xml.dom import minidom",
"from xml.dom import pulldom",
"BOOLEAN = \"boolean\"",
"STRING = \"String\"",
"GROUP = \"Group\"",
"DEFAULT_INTERFACES = ['FoursquareType']",
"INTERFACES = {\n}",
"DEFAULT_CLASS_IMPORTS = [\n]",
"CLASS_IMPORTS = {\n# 'Checkin': DEFAULT_CLASS_IMP... |
#!/usr/bin/env python
#
# Copyright 2011 Google Inc. All rights reserved.
# Use of this source code is governed by the Apache 2.0
# license that can be found in the LICENSE file.
"""Convenience wrapper for starting a Go tool in the App Engine SDK."""
import argparse
import os
import sys
SDK_BASE = os.path.abspath(os... | [
[
8,
0,
0.14,
0.02,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.18,
0.02,
0,
0.66,
0.1429,
325,
0,
1,
0,
0,
325,
0,
0
],
[
1,
0,
0.2,
0.02,
0,
0.66,
0.2857,... | [
"\"\"\"Convenience wrapper for starting a Go tool in the App Engine SDK.\"\"\"",
"import argparse",
"import os",
"import sys",
"SDK_BASE = os.path.abspath(os.path.dirname(os.path.realpath(__file__)))",
"GOROOT = os.path.join(SDK_BASE, 'goroot')",
"def GetArgsAndArgv():\n \"\"\"Parses command-line argum... |
import os
import sys
from vyperlogix import utils
__pathName = 'data'
__fileNames = {}
__source_files_key = 'source_files'
__data_files_key = 'data_files'
def fileNames():
return __fileNames
def isPackagesFile(fname):
return ( (fname.find(__const_packages_symbol) > -1) and (fname.find(__const_unkn... | [
[
1,
0,
0.0204,
0.0204,
0,
0.66,
0,
688,
0,
1,
0,
0,
688,
0,
0
],
[
1,
0,
0.0408,
0.0204,
0,
0.66,
0.0667,
509,
0,
1,
0,
0,
509,
0,
0
],
[
1,
0,
0.0612,
0.0204,
0,
... | [
"import os",
"import sys",
"from vyperlogix import utils",
"__pathName = 'data'",
"__fileNames = {}",
"__source_files_key = 'source_files'",
"__data_files_key = 'data_files'",
"def fileNames():\n\treturn __fileNames",
"\treturn __fileNames",
"def isPackagesFile(fname):\n\treturn ( (fname.find(__co... |
import psyco
import os
import sys
import globalVars
_open_curly_brace_symbol = '{'
_close_curly_brace_symbol = '}'
def main():
fHand = open(globalVars._unknown_packages_filename,'r')
total_count = 0
clsid_count = 0
for l in fHand.readlines():
total_count += 1
if ((l.find(_open_curly_brace_symbol... | [
[
1,
0,
0.0435,
0.0435,
0,
0.66,
0,
17,
0,
1,
0,
0,
17,
0,
0
],
[
1,
0,
0.087,
0.0435,
0,
0.66,
0.1429,
688,
0,
1,
0,
0,
688,
0,
0
],
[
1,
0,
0.1304,
0.0435,
0,
0.6... | [
"import psyco",
"import os",
"import sys",
"import globalVars",
"_open_curly_brace_symbol = '{'",
"_close_curly_brace_symbol = '}'",
"def main():\n\tfHand = open(globalVars._unknown_packages_filename,'r')\n\ttotal_count = 0\n\tclsid_count = 0\n\tfor l in fHand.readlines():\n\t\ttotal_count += 1\n\t\tif ... |
# -*- coding:utf-8 -*-
'''
Created on 2011-12-18
读入数据文件,将其显示在现有的ODB里,数据文件格式为:
节点编号 Z振级
配置文件中应有:
odbfile=ODB文件的路径
instance=instance的名称
step=插入数据的计算步
frame=frame的帧数
filename=数据文件文件名
@author: WLQ
'''
#处理输入文件
def ParseZdb(filename):
label=[]
zdb=[]
for line in open(filename):
... | [
[
8,
0,
0.1827,
0.3077,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
2,
0,
0.4615,
0.1731,
0,
0.66,
0.0769,
871,
0,
1,
1,
0,
0,
0,
7
],
[
14,
1,
0.4038,
0.0192,
1,
0.45,... | [
"'''\nCreated on 2011-12-18\n\n读入数据文件,将其显示在现有的ODB里,数据文件格式为:\n\n节点编号 Z振级\n\n配置文件中应有:",
"def ParseZdb(filename):\n label=[]\n zdb=[]\n for line in open(filename):\n tmp=line.split()\n if len(tmp)==2:\n label.append(int(tmp[0]))\n zdb.append((float(tmp[1]),))",
" lab... |
# -*- coding:utf-8 -*-
'''
Created on 2011-11-17
@author: WLQ
'''
def txtgen(tem, words):
'Replace Templates.'
items = tem.split('$')
for field in range(int(len(items) / 2)):
name = items[field * 2 + 1]
if name != '':
items[field * 2 + 1] = words[name]
line = ... | [
[
8,
0,
0.0851,
0.1064,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
2,
0,
0.2766,
0.234,
0,
0.66,
0.2,
467,
0,
2,
1,
0,
0,
0,
5
],
[
8,
1,
0.1915,
0.0213,
1,
0.45,
... | [
"'''\nCreated on 2011-11-17\n\n@author: WLQ\n'''",
"def txtgen(tem, words):\n 'Replace Templates.'\n items = tem.split('$')\n for field in range(int(len(items) / 2)):\n name = items[field * 2 + 1]\n if name != '':\n items[field * 2 + 1] = words[name]\n line = ''",
" 'Repl... |
# -*- coding:utf-8 -*-
'''
Created on 2011-9-30
@author: WLQ
'''
import sys,os
from PyQt4 import QtCore as QC
from PyQt4 import QtGui as QG
def tail( f, window=32):
BUFSIZE = 4096
f.seek(0, 2)
bytes = f.tell()
size = window
block = -1
data = []
while size > 0 and bytes > 0:... | [
[
8,
0,
0.0306,
0.051,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.0612,
0.0102,
0,
0.66,
0.1111,
509,
0,
2,
0,
0,
509,
0,
0
],
[
1,
0,
0.0714,
0.0102,
0,
0.66,... | [
"'''\nCreated on 2011-9-30\n\n@author: WLQ\n'''",
"import sys,os",
"from PyQt4 import QtCore as QC",
"from PyQt4 import QtGui as QG",
"def tail( f, window=32):\n BUFSIZE = 4096\n f.seek(0, 2)\n bytes = f.tell()\n size = window\n block = -1\n data = []\n while size > 0 and bytes > 0:",
... |
#! coding:utf8
#该脚本会设置Psiphon3的注册表选项中的是否使用VPN项,以方便两种模式的切换。
import _winreg as reg
key = reg.OpenKey(reg.HKEY_CURRENT_USER, r'Software\Psiphon3', 0, reg.KEY_ALL_ACCESS)
k,t=reg.QueryValueEx(key, "UserSkipVPN")
if k == 0:
reg.SetValueEx(key,"UserSkipVPN",0,t,1)
else:
reg.SetValueEx(key,"UserSkipVPN",0,t,0... | [
[
1,
0,
0.3,
0.1,
0,
0.66,
0,
90,
0,
1,
0,
0,
90,
0,
0
],
[
14,
0,
0.4,
0.1,
0,
0.66,
0.25,
230,
3,
4,
0,
0,
828,
10,
1
],
[
14,
0,
0.5,
0.1,
0,
0.66,
0.5,
... | [
"import _winreg as reg",
"key = reg.OpenKey(reg.HKEY_CURRENT_USER, r'Software\\Psiphon3', 0, reg.KEY_ALL_ACCESS)",
"k,t=reg.QueryValueEx(key, \"UserSkipVPN\")",
"if k == 0:\n reg.SetValueEx(key,\"UserSkipVPN\",0,t,1)\nelse:\n reg.SetValueEx(key,\"UserSkipVPN\",0,t,0)",
" reg.SetValueEx(key,\"UserS... |
#!/usr/bin/python2.5
#
# Copyright 2011 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless require... | [
[
8,
0,
0.1828,
0.0108,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.2043,
0.0108,
0,
0.66,
0.1667,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.2258,
0.0108,
0,
0.66,... | [
"\"\"\"Parser for iCalendar file data.\"\"\"",
"__author__ = \"dwightguth@google.com (Dwight Guth)\"",
"import datetime",
"import logging",
"import vobject",
"import model",
"class Parser(object):\n \"\"\"Parses VTODO components into App Engine datastore entities.\"\"\"\n\n def __init__(self, tasklist... |
#!/usr/bin/python2.5
#
# Copyright 2011 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless require... | [
[
8,
0,
0.2615,
0.0154,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.2923,
0.0154,
0,
0.66,
0.125,
295,
0,
1,
0,
0,
295,
0,
0
],
[
1,
0,
0.3231,
0.0154,
0,
0.66,... | [
"\"\"\"Represents the App Engine model of Google Tasks data in the datastore.\"\"\"",
"from apiclient.oauth2client import appengine",
"from google.appengine.ext import db",
"class Credentials(db.Model):\n \"\"\"Represents the credentials of a particular user.\"\"\"\n credentials = appengine.CredentialsPrope... |
#!/usr/bin/python2.5
#
# Copyright 2011 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless require... | [
[
8,
0,
0.7391,
0.0435,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.8261,
0.0435,
0,
0.66,
0.3333,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.913,
0.0435,
0,
0.66,
... | [
"\"\"\"Google Tasks Porter configuration file.\"\"\"",
"__author__ = \"dwightguth@google.com (Dwight Guth)\"",
"from google.appengine.dist import use_library",
"use_library(\"django\", \"1.2\")"
] |
#!/usr/bin/python2.5
#
# Copyright 2011 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless require... | [
[
8,
0,
0.2,
0.0118,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.2235,
0.0118,
0,
0.66,
0.1667,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.2471,
0.0118,
0,
0.66,
... | [
"\"\"\"Parser for Outlook CSV file data.\"\"\"",
"__author__ = \"dwightguth@google.com (Dwight Guth)\"",
"import csv",
"import datetime",
"import StringIO",
"import model",
"class Parser(object):\n \"\"\"Parses CSV export from Outlook into App Engine datastore entities.\"\"\"\n\n def __init__(self, ta... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
8,
0,
0.054,
0.0185,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.0679,
0.0031,
0,
0.66,
0.0714,
777,
1,
0,
0,
0,
0,
3,
0
],
[
14,
0,
0.0756,
0.0123,
0,
0.66,... | [
"\"\"\"Classes to encapsulate a single HTTP request.\n\nThe classes implement a command pattern, with every\nobject supporting an execute() method that does the\nactuall HTTP request.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"__all__ = [\n 'HttpRequest', 'RequestMockBuilder', 'HttpMoc... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
8,
0,
0.0374,
0.011,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.0462,
0.0022,
0,
0.66,
0.05,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.0505,
0.0022,
0,
0.66,
... | [
"\"\"\"An OAuth 2.0 client\n\nTools for interacting with OAuth 2.0 protected\nresources.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"import copy",
"import datetime",
"import httplib2",
"import logging",
"import urllib",
"import urlparse",
"try: # pragma: no cover\n import simp... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
8,
0,
0.2656,
0.0781,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.3281,
0.0156,
0,
0.66,
0.2,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.3594,
0.0156,
0,
0.66,
... | [
"\"\"\"Utilities for OAuth.\n\nUtilities for making it easier to work with OAuth 2.0\ncredentials.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"import pickle",
"import threading",
"from client import Storage as BaseStorage",
"class Storage(BaseStorage):\n \"\"\"Store and retrieve a s... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
8,
0,
0.1491,
0.0439,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.1842,
0.0088,
0,
0.66,
0.1111,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.2018,
0.0088,
0,
0.66,... | [
"\"\"\"OAuth 2.0 utilities for Django.\n\nUtilities for using OAuth 2.0 in conjunction with\nthe Django datastore.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"import apiclient.oauth2client",
"import base64",
"import pickle",
"from django.db import models",
"from apiclient.oauth2cli... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
8,
0,
0.1204,
0.0292,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.146,
0.0073,
0,
0.66,
0.1111,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.1606,
0.0073,
0,
0.66,
... | [
"\"\"\"Utilities for Google App Engine\n\nUtilities for making it easier to use OAuth 2.0 on Google App Engine.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"import pickle",
"from google.appengine.ext import db",
"from client import Credentials",
"from client import Flow",
"from clie... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
8,
0,
0.0487,
0.0118,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.059,
0.0029,
0,
0.66,
0.05,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.0678,
0.0029,
0,
0.66,
... | [
"\"\"\"Utilities for OAuth.\n\nUtilities for making it easier to work with OAuth.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"import copy",
"import httplib2",
"import logging",
"import oauth2 as oauth",
"import urllib",
"import urlparse",
"from anyjson import simplejson",
"tr... |
#!/usr/bin/python2.4
#
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable l... | [
[
8,
0,
0.0664,
0.0233,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.0831,
0.0033,
0,
0.66,
0.0769,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.0897,
0.0033,
0,
0.66,... | [
"\"\"\"Model objects for requests and responses.\n\nEach API may support one or more serializations, such\nas JSON, Atom, etc. The model classes are responsible\nfor converting between the wire format and the Python\nobject representation.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"import... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
8,
0,
0.2619,
0.0635,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.3175,
0.0159,
0,
0.66,
0.2,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.3492,
0.0159,
0,
0.66,
... | [
"\"\"\"Utilities for OAuth.\n\nUtilities for making it easier to work with OAuth 1.0 credentials.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"import pickle",
"import threading",
"from apiclient.oauth import Storage as BaseStorage",
"class Storage(BaseStorage):\n \"\"\"Store and retr... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
1,
0,
0.2679,
0.0179,
0,
0.66,
0,
629,
0,
1,
0,
0,
629,
0,
0
],
[
1,
0,
0.2857,
0.0179,
0,
0.66,
0.2,
177,
0,
1,
0,
0,
177,
0,
0
],
[
1,
0,
0.3036,
0.0179,
0,
0.6... | [
"import apiclient",
"import base64",
"import pickle",
"from django.db import models",
"class OAuthCredentialsField(models.Field):\n\n __metaclass__ = models.SubfieldBase\n\n def db_type(self):\n return 'VARCHAR'\n\n def to_python(self, value):",
" __metaclass__ = models.SubfieldBase",
" def db_t... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
8,
0,
0.1259,
0.037,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.1556,
0.0074,
0,
0.66,
0.125,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.1704,
0.0074,
0,
0.66,
... | [
"\"\"\"Utilities for Google App Engine\n\nUtilities for making it easier to use the\nGoogle API Client for Python on Google App Engine.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"import pickle",
"from google.appengine.ext import db",
"from apiclient.oauth import OAuthCredentials",
"... |
#!/usr/bin/python2.4
#
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable l... | [
[
8,
0,
0.2639,
0.0694,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.3194,
0.0139,
0,
0.66,
0.1667,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.3611,
0.0139,
0,
0.66,... | [
"\"\"\"Errors for the library.\n\nAll exceptions defined by the library\nshould be defined in this file.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"from anyjson import simplejson",
"class Error(Exception):\n \"\"\"Base error for this module.\"\"\"\n pass",
" \"\"\"Base error for th... |
# Copyright (C) 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | [
[
8,
0,
0.5312,
0.1562,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.6562,
0.0312,
0,
0.66,
0.5,
777,
1,
0,
0,
0,
0,
3,
0
],
[
7,
0,
0.875,
0.2812,
0,
0.66,
... | [
"\"\"\"Utility module to import a JSON module\n\nHides all the messy details of exactly where\nwe get a simplejson module from.\n\"\"\"",
"__author__ = 'jcgregorio@google.com (Joe Gregorio)'",
"try: # pragma: no cover\n import simplejson\nexcept ImportError: # pragma: no cover\n try:\n # Try to import from... |
import _winreg
import struct
import datetime
handle=_winreg.ConnectRegistry(None, _winreg.HKEY_LOCAL_MACHINE)
tzparent=_winreg.OpenKey(handle,
"SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Time Zones")
parentsize=_winreg.QueryInfoKey(tzparent)[0]
localkey=_winreg.OpenKey(handle,
"SYSTEM\\C... | [
[
1,
0,
0.0064,
0.0064,
0,
0.66,
0,
90,
0,
1,
0,
0,
90,
0,
0
],
[
1,
0,
0.0128,
0.0064,
0,
0.66,
0.0714,
399,
0,
1,
0,
0,
399,
0,
0
],
[
1,
0,
0.0192,
0.0064,
0,
0.... | [
"import _winreg",
"import struct",
"import datetime",
"handle=_winreg.ConnectRegistry(None, _winreg.HKEY_LOCAL_MACHINE)",
"tzparent=_winreg.OpenKey(handle,\n \"SOFTWARE\\\\Microsoft\\\\Windows NT\\\\CurrentVersion\\\\Time Zones\")",
"parentsize=_winreg.QueryInfoKey(tzparent)[0]",
"localkey=_w... |
"""Definitions and behavior for vCard 3.0"""
import behavior
import itertools
from base import VObjectError, NativeError, ValidateError, ParseError, \
VBase, Component, ContentLine, logger, defaultSerialize, \
registerBehavior, backslashEscape, ascii
from icalendar import strin... | [
[
8,
0,
0.0033,
0.0033,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.01,
0.0033,
0,
0.66,
0.0333,
122,
0,
1,
0,
0,
122,
0,
0
],
[
1,
0,
0.0133,
0.0033,
0,
0.66,
... | [
"\"\"\"Definitions and behavior for vCard 3.0\"\"\"",
"import behavior",
"import itertools",
"from base import VObjectError, NativeError, ValidateError, ParseError, \\\n VBase, Component, ContentLine, logger, defaultSerialize, \\\n registerBehavior, backslashEscape, ascii... |
"""
hCalendar: A microformat for serializing iCalendar data
(http://microformats.org/wiki/hcalendar)
Here is a sample event in an iCalendar:
BEGIN:VCALENDAR
PRODID:-//XYZproduct//EN
VERSION:2.0
BEGIN:VEVENT
URL:http://www.web2con.com/
DTSTART:20051005
DTEND:20051008
SUMMARY:Web 2.0 Conference
LOCATION:Argen... | [
[
8,
0,
0.12,
0.232,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.248,
0.008,
0,
0.66,
0.1667,
47,
0,
3,
0,
0,
47,
0,
0
],
[
1,
0,
0.256,
0.008,
0,
0.66,
0.3... | [
"\"\"\"\nhCalendar: A microformat for serializing iCalendar data\n (http://microformats.org/wiki/hcalendar)\n\nHere is a sample event in an iCalendar:\n\nBEGIN:VCALENDAR\nPRODID:-//XYZproduct//EN",
"from base import foldOneLine, CRLF, registerBehavior",
"from icalendar import VCalendar2_0",
"from dat... |
"""Translate an ics file's events to a different timezone."""
from optparse import OptionParser
from vobject import icalendar, base
import sys
try:
import PyICU
except:
PyICU = None
from datetime import datetime
def change_tz(cal, new_timezone, default, utc_only=False, utc_tz=icalendar.utc):
for vevent i... | [
[
8,
0,
0.0122,
0.0122,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.0366,
0.0122,
0,
0.66,
0.1,
323,
0,
1,
0,
0,
323,
0,
0
],
[
1,
0,
0.0488,
0.0122,
0,
0.66,
... | [
"\"\"\"Translate an ics file's events to a different timezone.\"\"\"",
"from optparse import OptionParser",
"from vobject import icalendar, base",
"import sys",
"try:\n import PyICU\nexcept:\n PyICU = None",
" import PyICU",
" PyICU = None",
"from datetime import datetime",
"def change_t... |
"""
VObject Overview
================
vobject parses vCard or vCalendar files, returning a tree of Python objects.
It also provids an API to create vCard or vCalendar data structures which
can then be serialized.
Parsing existing streams
------------------------
Streams containing one or many L... | [
[
8,
0,
0.4535,
0.8953,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.9186,
0.0116,
0,
0.66,
0.25,
47,
0,
3,
0,
0,
47,
0,
0
],
[
1,
0,
0.9302,
0.0116,
0,
0.66,
... | [
"\"\"\"\nVObject Overview\n================\n vobject parses vCard or vCalendar files, returning a tree of Python objects.\n It also provids an API to create vCard or vCalendar data structures which\n can then be serialized.\n\n Parsing existing streams",
"import base, icalendar, vcard",
"from base ... |
"""Behavior (validation, encoding, and transformations) for vobjects."""
import base
#------------------------ Abstract class for behavior --------------------------
class Behavior(object):
"""Abstract class to describe vobject options, requirements and encodings.
Behaviors are used for root components l... | [
[
8,
0,
0.0061,
0.0061,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.0183,
0.0061,
0,
0.66,
0.5,
47,
0,
1,
0,
0,
47,
0,
0
],
[
3,
0,
0.5183,
0.9695,
0,
0.66,
... | [
"\"\"\"Behavior (validation, encoding, and transformations) for vobjects.\"\"\"",
"import base",
"class Behavior(object):\n \"\"\"Abstract class to describe vobject options, requirements and encodings.\n \n Behaviors are used for root components like VCALENDAR, for subcomponents\n like VEVENT, and f... |
# Early, and incomplete implementation of -04.
#
import re
import urllib
RESERVED = ":/?#[]@!$&'()*+,;="
OPERATOR = "+./;?|!@"
EXPLODE = "*+"
MODIFIER = ":^"
TEMPLATE = re.compile(r"{(?P<operator>[\+\./;\?|!@])?(?P<varlist>[^}]+)}", re.UNICODE)
VAR = re.compile(r"^(?P<varname>[^=\+\*:\^]+)((?P<explode>[\+\*])|(?P<part... | [
[
1,
0,
0.0204,
0.0068,
0,
0.66,
0,
540,
0,
1,
0,
0,
540,
0,
0
],
[
1,
0,
0.0272,
0.0068,
0,
0.66,
0.0833,
614,
0,
1,
0,
0,
614,
0,
0
],
[
14,
0,
0.0408,
0.0068,
0,
... | [
"import re",
"import urllib",
"RESERVED = \":/?#[]@!$&'()*+,;=\"",
"OPERATOR = \"+./;?|!@\"",
"EXPLODE = \"*+\"",
"MODIFIER = \":^\"",
"TEMPLATE = re.compile(r\"{(?P<operator>[\\+\\./;\\?|!@])?(?P<varlist>[^}]+)}\", re.UNICODE)",
"VAR = re.compile(r\"^(?P<varname>[^=\\+\\*:\\^]+)((?P<explode>[\\+\\*])... |
#!/usr/bin/env python
# Copyright (c) 2010, Google Inc.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistributions of source code must retain the above copyright
# notice, this l... | [
[
8,
0,
0.1818,
0.0267,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.2032,
0.0053,
0,
0.66,
0.2,
777,
1,
0,
0,
0,
0,
3,
0
],
[
3,
0,
0.2219,
0.0107,
0,
0.66,
... | [
"\"\"\"Module to enforce different constraints on flags.\n\nA validator represents an invariant, enforced over a one or more flags.\nSee 'FLAGS VALIDATORS' in flags.py's docstring for a usage manual.\n\"\"\"",
"__author__ = 'olexiy@google.com (Olexiy Oryeshko)'",
"class Error(Exception):\n \"\"\"Thrown If vali... |
"""
Copyright (c) 2003-2010 Gustavo Niemeyer <gustavo@niemeyer.net>
This module offers extensions to the standard python 2.3+
datetime module.
"""
__author__ = "Gustavo Niemeyer <gustavo@niemeyer.net>"
__license__ = "PSF License"
__version__ = "1.5"
| [
[
8,
0,
0.3889,
0.6667,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.7778,
0.1111,
0,
0.66,
0.3333,
777,
1,
0,
0,
0,
0,
3,
0
],
[
14,
0,
0.8889,
0.1111,
0,
0.66... | [
"\"\"\"\nCopyright (c) 2003-2010 Gustavo Niemeyer <gustavo@niemeyer.net>\n\nThis module offers extensions to the standard python 2.3+\ndatetime module.\n\"\"\"",
"__author__ = \"Gustavo Niemeyer <gustavo@niemeyer.net>\"",
"__license__ = \"PSF License\"",
"__version__ = \"1.5\""
] |
"""
Copyright (c) 2003-2005 Gustavo Niemeyer <gustavo@niemeyer.net>
This module offers extensions to the standard python 2.3+
datetime module.
"""
from dateutil.tz import tzfile
from tarfile import TarFile
import os
__author__ = "Gustavo Niemeyer <gustavo@niemeyer.net>"
__license__ = "PSF License"
__all__ = ["setca... | [
[
8,
0,
0.0402,
0.069,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.0805,
0.0115,
0,
0.66,
0.0714,
872,
0,
1,
0,
0,
872,
0,
0
],
[
1,
0,
0.092,
0.0115,
0,
0.66,
... | [
"\"\"\"\nCopyright (c) 2003-2005 Gustavo Niemeyer <gustavo@niemeyer.net>\n\nThis module offers extensions to the standard python 2.3+\ndatetime module.\n\"\"\"",
"from dateutil.tz import tzfile",
"from tarfile import TarFile",
"import os",
"__author__ = \"Gustavo Niemeyer <gustavo@niemeyer.net>\"",
"__li... |
# This code was originally contributed by Jeffrey Harris.
import datetime
import struct
import _winreg
__author__ = "Jeffrey Harris & Gustavo Niemeyer <gustavo@niemeyer.net>"
__all__ = ["tzwin", "tzwinlocal"]
ONEWEEK = datetime.timedelta(7)
TZKEYNAMENT = r"SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones"
TZ... | [
[
1,
0,
0.0111,
0.0056,
0,
0.66,
0,
426,
0,
1,
0,
0,
426,
0,
0
],
[
1,
0,
0.0167,
0.0056,
0,
0.66,
0.0667,
399,
0,
1,
0,
0,
399,
0,
0
],
[
1,
0,
0.0222,
0.0056,
0,
... | [
"import datetime",
"import struct",
"import _winreg",
"__author__ = \"Jeffrey Harris & Gustavo Niemeyer <gustavo@niemeyer.net>\"",
"__all__ = [\"tzwin\", \"tzwinlocal\"]",
"ONEWEEK = datetime.timedelta(7)",
"TZKEYNAMENT = r\"SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Time Zones\"",
"TZKEYNAME9X ... |
"""SocksiPy - Python SOCKS module.
Version 1.00
Copyright 2006 Dan-Haim. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
... | [
[
8,
0,
0.0364,
0.0705,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
8,
0,
0.0841,
0.0205,
0,
0.66,
0.0455,
0,
1,
0,
0,
0,
0,
0,
0
],
[
1,
0,
0.0977,
0.0023,
0,
0.66,
... | [
"\"\"\"SocksiPy - Python SOCKS module.\nVersion 1.00\n\nCopyright 2006 Dan-Haim. All rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n1. Redistributions of source code must retain the above copyright ... |
"""
iri2uri
Converts an IRI to a URI.
"""
__author__ = "Joe Gregorio (joe@bitworking.org)"
__copyright__ = "Copyright 2006, Joe Gregorio"
__contributors__ = []
__version__ = "1.0.0"
__license__ = "MIT"
__history__ = """
"""
import urlparse
# Convert an IRI to a URI following the rules in RFC 3987
#
# The characte... | [
[
8,
0,
0.0318,
0.0545,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.0636,
0.0091,
0,
0.66,
0.0909,
777,
1,
0,
0,
0,
0,
3,
0
],
[
14,
0,
0.0727,
0.0091,
0,
0.66... | [
"\"\"\"\niri2uri\n\nConverts an IRI to a URI.\n\n\"\"\"",
"__author__ = \"Joe Gregorio (joe@bitworking.org)\"",
"__copyright__ = \"Copyright 2006, Joe Gregorio\"",
"__contributors__ = []",
"__version__ = \"1.0.0\"",
"__license__ = \"MIT\"",
"__history__ = \"\"\"\n\"\"\"",
"import urlparse",
"escape_... |
#!/usr/bin/python2.5
#
# Copyright 2011 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless require... | [
[
8,
0,
0.2208,
0.013,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.2468,
0.013,
0,
0.66,
0.1667,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.2727,
0.013,
0,
0.66,
... | [
"\"\"\"Custom model properties for the App Engine datastore.\"\"\"",
"__author__ = \"dwightguth@google.com (Dwight Guth)\"",
"import datetime",
"import pickle",
"from google.appengine.ext import db",
"class TimeDeltaProperty(db.Property):\n \"\"\"A datastore property for a datetime.timedelta object.\"\"\... |
#!/usr/bin/python2.5
#
# Copyright 2011 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless require... | [
[
8,
0,
0.1242,
0.0327,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.1503,
0.0065,
0,
0.66,
0.25,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.1634,
0.0065,
0,
0.66,
... | [
"\"\"\"Generic Uploader for Apiary API data.\n\nThis module contains code to take an arbitrary set of datastore objects and\nupload them to an Apiary API\n\"\"\"",
"__author__ = \"dwightguth@google.com (Dwight Guth)\"",
"from google.appengine.ext import db",
"PREVIOUS_ARGUMENT = object()",
"class Uploader(o... |
#!/usr/bin/python2.5
#
# Copyright 2011 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless require... | [
[
8,
0,
0.0704,
0.0185,
0,
0.66,
0,
0,
1,
0,
0,
0,
0,
0,
0
],
[
14,
0,
0.0852,
0.0037,
0,
0.66,
0.1429,
777,
1,
0,
0,
0,
0,
3,
0
],
[
1,
0,
0.0926,
0.0037,
0,
0.66,... | [
"\"\"\"Generic Parser for Apiary API data.\n\nThis module contains code to take an arbitrary type of python data from an\nApiary API and convert it into entities in the datastore.\n\"\"\"",
"__author__ = \"dwightguth@google.com (Dwight Guth)\"",
"import datetime",
"import logging",
"from google.appengine.ap... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.