Module Assign NameStore Str Import alias Import alias Import alias Import alias Import alias ImportFrom alias ImportFrom alias alias ImportFrom alias alias ImportFrom alias alias Assign NameStore Str Assign NameStore Str Assign NameStore Str Assign NameStore Num Assign NameStore Num Assign NameStore Str Assign NameStore Str FunctionDef arguments args defaults body Expr Str Return NameLoad decorator_list FunctionDef arguments args defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Return Call AttributeLoad NameLoad attr Dict Str Str Num SubscriptLoad NameLoad Index Str decorator_list FunctionDef arguments args defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Dict Str Str Num SubscriptLoad NameLoad Index Str Assign SubscriptStore SubscriptLoad NameLoad Index Str Index Str BinOpMult Num BinOpAdd Call AttributeLoad NameLoad attr Call AttributeLoad Call AttributeLoad NameLoad attr keyword Num attr Return Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Return Call AttributeLoad NameLoad attr Dict Str Str Str Str Num SubscriptLoad NameLoad Index Str Call AttributeLoad NameLoad attr Str SubscriptLoad NameLoad Index Str decorator_list FunctionDef arguments args defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Return Call AttributeLoad NameLoad attr Dict Str Str SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str decorator_list FunctionDef arguments args defaults body Expr Str Return Str decorator_list FunctionDef arguments args defaults body Expr Str Return Str decorator_list FunctionDef arguments args defaults body Expr Str Return Str decorator_list FunctionDef arguments args defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Dict Str Str Num SubscriptLoad NameLoad Index Str Assign SubscriptStore SubscriptLoad NameLoad Index Str Index Str Str Return Call AttributeLoad NameLoad attr NameLoad decorator_list ClassDef bases NameLoad body FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr Assign AttributeStore AttributeLoad NameLoad attr attr Str Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call NameLoad Call AttributeLoad NameLoad attr ListLoad Str Str Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call NameLoad Expr Call AttributeLoad NameLoad attr Str Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Assign NameStore Call NameLoad keyword NameLoad Expr Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Call NameLoad Expr Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr decorator_list decorator_list
N/A N/A __author__ ben@emailscrubbed.com (Ben Darnell) N/A base64 N/A datetime N/A functools N/A json N/A time tornado options viewfinder.backend.base base_options secrets viewfinder.backend.base.testing BaseTestCase MockAsyncHTTPClient viewfinder.backend.services.itunes_store ITunesStoreClient ITunesStoreError N/A kProductId vf_sub1_month N/A kTransactionId 1000000056588946 N/A kTransactionId2 1000000056589752 N/A kExpirationTime 1349159462.5 N/A kExpirationTime2 1349160962.0 N/A kReceiptData {
    	"signature" = "Am7A11SyaJz20uV1wAKJmzmc2UH1lp3Wc4LJh7kdAUUH7jsEa3USs9XTw0G5jQuwPxcxI5+JcS2CxfUWGA0bnyUlQk0qrGhaNrCq3CRV89b9V0MNSyB6UBAko14wdfZQSXgirkdjJZhtcfJkTLwE/9bJv3DH2/FWNUZmfFkb5IMeAAADVzCCA1MwggI7oAMCAQICCGUUkU3ZWAS1MA0GCSqGSIb3DQEBBQUAMH8xCzAJBgNVBAYTAlVTMRMwEQYDVQQKDApBcHBsZSBJbmMuMSYwJAYDVQQLDB1BcHBsZSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTEzMDEGA1UEAwwqQXBwbGUgaVR1bmVzIFN0b3JlIENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4XDTA5MDYxNTIyMDU1NloXDTE0MDYxNDIyMDU1NlowZDEjMCEGA1UEAwwaUHVyY2hhc2VSZWNlaXB0Q2VydGlmaWNhdGUxGzAZBgNVBAsMEkFwcGxlIGlUdW5lcyBTdG9yZTETMBEGA1UECgwKQXBwbGUgSW5jLjELMAkGA1UEBhMCVVMwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBAMrRjF2ct4IrSdiTChaI0g8pwv/cmHs8p/RwV/rt/91XKVhNl4XIBimKjQQNfgHsDs6yju++DrKJE7uKsphMddKYfFE5rGXsAdBEjBwRIxexTevx3HLEFGAt1moKx509dhxtiIdDgJv2YaVs49B0uJvNdy6SMqNNLHsDLzDS9oZHAgMBAAGjcjBwMAwGA1UdEwEB/wQCMAAwHwYDVR0jBBgwFoAUNh3o4p2C0gEYtTJrDtdDC5FYQzowDgYDVR0PAQH/BAQDAgeAMB0GA1UdDgQWBBSpg4PyGUjFPhJXCBTMzaN+mV8k9TAQBgoqhkiG92NkBgUBBAIFADANBgkqhkiG9w0BAQUFAAOCA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Y2IjsKCSJleHBpcmVzLWRhdGUtZm9ybWF0dGVkIiA9ICIyMDEyLTEwLTAyIDA2OjMxOjAyIEV0Yy9HTVQiOwoJInByb2R1Y3QtaWQiID0gInRlc3Rfc3ViMV9tb250aCI7CgkicHVyY2hhc2UtZGF0ZSIgPSAiMjAxMi0xMC0wMiAwNjoyNjowMiBFdGMvR01UIjsKCSJvcmlnaW5hbC1wdXJjaGFzZS1kYXRlIiA9ICIyMDEyLTEwLTAyIDA2OjI2OjAzIEV0Yy9HTVQiOwoJImJpZCIgPSAiY28udmlld2ZpbmRlci5WaWV3ZmluZGVyIjsKCSJwdXJjaGFzZS1kYXRlLXBzdCIgPSAiMjAxMi0xMC0wMSAyMzoyNjowMiBBbWVyaWNhL0xvc19BbmdlbGVzIjsKCSJxdWFudGl0eSIgPSAiMSI7Cn0=";
    	"environment" = "Sandbox";
    	"pod" = "100";
    	"signing-status" = "0";
    } N/A kVerifyResponseRenewedExpired {
  "status": 21006,
  "receipt": {
    "purchase_date_pst": "2012-10-01 23:26:02 America/Los_Angeles",
    "expires_date": "1349159462502",
    "product_id": "vf_sub1_month",
    "original_transaction_id": "1000000056588946",
    "unique_identifier": "b84eaad25ddc084faecca09c44f7d63ade7a46a2",
    "original_purchase_date_pst": "2012-10-01 23:26:03 America/Los_Angeles",
    "expires_date_formatted_pst": "2012-10-01 23:31:02 America/Los_Angeles",
    "original_purchase_date": "2012-10-02 06:26:03 Etc/GMT",
    "expires_date_formatted": "2012-10-02 06:31:02 Etc/GMT",
    "bvrs": "3",
    "original_purchase_date_ms": "1349159163313",
    "purchase_date": "2012-10-02 06:26:02 Etc/GMT",
    "web_order_line_item_id": "1000000026273315",
    "purchase_date_ms": "1349159162502",
    "item_id": "564959566",
    "bid": "co.viewfinder.Viewfinder",
    "transaction_id": "1000000056588946",
    "quantity": "1"
  },
  "latest_expired_receipt_info": {
    "purchase_date_pst": "2012-10-01 23:51:02 America/Los_Angeles",
    "expires_date": "1349160962000",
    "product_id": "vf_sub1_month",
    "original_transaction_id": "1000000056588946",
    "unique_identifier": "b84eaad25ddc084faecca09c44f7d63ade7a46a2",
    "original_purchase_date_pst": "2012-10-01 23:26:03 America/Los_Angeles",
    "expires_date_formatted_pst": "2012-10-01 23:56:02 America/Los_Angeles",
    "original_purchase_date": "2012-10-02 06:26:03 Etc/GMT",
    "expires_date_formatted": "2012-10-02 06:56:02 Etc/GMT",
    "bvrs": "3",
    "original_purchase_date_ms": "1349159163000",
    "purchase_date": "2012-10-02 06:51:02 Etc/GMT",
    "web_order_line_item_id": "1000000026273346",
    "purchase_date_ms": "1349160662000",
    "item_id": "564959566",
    "bid": "co.viewfinder.Viewfinder",
    "transaction_id": "1000000056589752",
    "quantity": "1"
  }
}
 MakeRenewedExpiredResponse N/A N/A N/A N/A N/A Returns a response for a subscription which expired after at least one
  renewal.
   N/A kVerifyResponseRenewedExpired N/A MakeNewResponse N/A N/A N/A N/A N/A Returns a response for a subscription which has not been renewed
  or expired.  This is the expected case for subscriptions sent up by
  the client.
   N/A reference N/A N/A json loads kVerifyResponseRenewedExpired N/A N/A N/A json dumps N/A status receipt 0 N/A reference N/A receipt N/A MakeFreshResponse N/A N/A N/A N/A N/A Returns a response for a subscription which has an expiration date in
  the future.  Note that the metadata here may be inconsistent, since only
  the expiration date is changed from an old receipt template.
   N/A reference N/A N/A json loads kVerifyResponseRenewedExpired N/A new N/A status receipt 0 N/A reference N/A receipt N/A N/A N/A new N/A receipt N/A expires_date N/A 1000.0 N/A N/A N/A time time N/A N/A N/A N/A datetime timedelta days 28 total_seconds N/A N/A N/A json dumps new N/A MakeRenewedResponse N/A N/A N/A N/A N/A Returns a response with an unexpired renewal. N/A reference N/A N/A json loads kVerifyResponseRenewedExpired N/A N/A N/A json dumps N/A status receipt latest_receipt latest_expired_receipt_info 0 N/A reference N/A receipt N/A N/A base64 b64encode fake encoded receipt N/A reference N/A latest_expired_receipt_info N/A MakeExpiredResponse N/A N/A N/A N/A N/A Returns a response that expired without ever being renewed. N/A reference N/A N/A json loads kVerifyResponseRenewedExpired N/A N/A N/A json dumps N/A status receipt N/A reference N/A status N/A reference N/A receipt N/A MakeBadSignatureResponse N/A N/A N/A N/A N/A Returns a status code indicating an invalid signature. N/A {"status": 21003} N/A MakeServerErrorResponse N/A N/A N/A N/A N/A Returns a status code indicating a (possibly transient) server error. N/A {"status": 21005} N/A MakeSandboxOnProdResponse N/A N/A N/A N/A N/A Returns a status code indicating a sandbox receipt on the production
  iTunes server.
   N/A {"status": 21007} N/A MakeOtherAppResponse N/A N/A N/A N/A N/A Make a response for a valid receipt from another app.

  iTunes just verifies that the receipt was issued by Apple; we need to
  verify that it came from our own app.
   N/A reference N/A N/A json loads kVerifyResponseRenewedExpired N/A new N/A status receipt 0 N/A reference N/A receipt N/A N/A N/A new N/A receipt N/A bid com.angrybirds.AngryBirds N/A N/A N/A json dumps new N/A ITunesStoreTest N/A BaseTestCase N/A setUp N/A N/A self N/A N/A N/A N/A N/A N/A super ITunesStoreTest self setUp N/A N/A N/A options options domain goviewfinder.com N/A N/A N/A secrets InitSecretsForTest N/A VerifyReceipt N/A N/A self response request N/A N/A N/A request_data N/A N/A json loads N/A request body N/A N/A N/A self assertEqual N/A sorted N/A N/A request_data keys N/A password receipt-data N/A response N/A GetResponse N/A N/A self raw_response N/A N/A N/A mock_http N/A MockAsyncHTTPClient N/A N/A N/A mock_http map https://.*\.itunes\.apple\.com/verifyReceipt N/A N/A functools partial N/A self VerifyReceipt raw_response N/A client N/A ITunesStoreClient http_client mock_http N/A N/A N/A client VerifyReceipt kReceiptData N/A self stop N/A response N/A N/A self wait N/A response N/A test_verify_renewed_expired N/A N/A self N/A N/A N/A response N/A N/A self GetResponse N/A MakeRenewedExpiredResponse N/A N/A N/A self assertTrue N/A N/A response IsValid N/A N/A N/A self assertEqual N/A N/A response GetProductId kProductId N/A N/A N/A self assertEqual N/A N/A response GetExpirationTime kExpirationTime2 N/A N/A N/A self assertTrue N/A N/A response IsExpired N/A N/A N/A self assertFalse N/A N/A response IsRenewable N/A N/A N/A self assertEqual N/A N/A response GetOriginalTransactionId kTransactionId N/A N/A N/A self assertEqual N/A N/A response GetRenewalTransactionId kTransactionId2 N/A test_verify_new N/A N/A self N/A N/A N/A response N/A N/A self GetResponse N/A MakeNewResponse N/A N/A N/A self assertTrue N/A N/A response IsValid N/A N/A N/A self assertEqual N/A N/A response GetProductId kProductId N/A N/A N/A self assertEqual N/A N/A response GetExpirationTime kExpirationTime N/A N/A N/A self assertTrue N/A N/A response IsRenewable N/A N/A N/A self assertEqual N/A N/A response GetRenewalData kReceiptData N/A N/A N/A self assertEqual N/A N/A response GetOriginalTransactionId kTransactionId N/A N/A N/A self assertEqual N/A N/A response GetRenewalTransactionId kTransactionId N/A test_verify_renewed N/A N/A self N/A N/A N/A response N/A N/A self GetResponse N/A MakeRenewedResponse N/A N/A N/A self assertTrue N/A N/A response IsValid N/A N/A N/A self assertEqual N/A N/A response GetProductId kProductId N/A N/A N/A self assertEqual N/A N/A response GetExpirationTime kExpirationTime2 N/A N/A N/A self assertTrue N/A N/A response IsRenewable N/A N/A N/A self assertEqual N/A N/A response GetRenewalData fake encoded receipt N/A N/A N/A self assertEqual N/A N/A response GetOriginalTransactionId kTransactionId N/A N/A N/A self assertEqual N/A N/A response GetRenewalTransactionId kTransactionId2 N/A test_verify_expired N/A N/A self N/A N/A N/A response N/A N/A self GetResponse N/A MakeExpiredResponse N/A N/A N/A self assertTrue N/A N/A response IsValid N/A N/A N/A self assertEqual N/A N/A response GetProductId kProductId N/A N/A N/A self assertEqual N/A N/A response GetExpirationTime kExpirationTime N/A N/A N/A self assertTrue N/A N/A response IsExpired N/A N/A N/A self assertFalse N/A N/A response IsRenewable N/A N/A N/A self assertEqual N/A N/A response GetOriginalTransactionId kTransactionId N/A N/A N/A self assertEqual N/A N/A response GetRenewalTransactionId kTransactionId N/A test_verify_bad_signature N/A N/A self N/A N/A N/A response N/A N/A self GetResponse N/A MakeBadSignatureResponse N/A N/A N/A self assertFalse N/A N/A response IsValid N/A test_verify_server_error N/A N/A self N/A N/A N/A response N/A N/A self GetResponse N/A MakeServerErrorResponse N/A N/A N/A self assertRaises ITunesStoreError N/A response IsValid N/A test_verify_other_app N/A N/A self N/A N/A N/A response N/A N/A self GetResponse N/A MakeOtherAppResponse N/A N/A N/A self assertFalse N/A N/A response IsValid N/A N/A