Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > Mac OS X Development Forums > Mac OS X Development

Reply
 
LinkBack Thread Tools Display Modes
Old 01-13-2011, 06:34 PM   #1 (permalink)
Registered Member
 
Join Date: May 2010
Posts: 186
cacao is on a distinguished road
Default receipt validation

Hi,

did you guys implement receiplt validation?
If so, how?
I know Alan Quatermain's approach and roddi's one. Roddi's approach gives me two error when compiling in my project.

Is it worth the effort to implement receipt validation?
cacao is offline   Reply With Quote
Old 01-14-2011, 11:36 AM   #2 (permalink)
Registered Member
 
ChrisMayer's Avatar
 
Join Date: Aug 2009
Posts: 238
ChrisMayer is on a distinguished road
Default

I chose not to - and here's my reason... all of my popular iOS apps have been cracked and are available for download on various websites, on iOS the process of cracking apps is much tougher than on a desktop system like a Mac.

I honestly believe that my mac apps will be pirated anyway, so I'm not going to bother wasting my time with copy protection methods.
__________________
ChrisMayer is offline   Reply With Quote
Old 01-15-2011, 02:57 AM   #3 (permalink)
Registered Member
 
Join Date: Sep 2009
Posts: 1,018
Tambourin is on a distinguished road
Default

Except that on a mac no need to jailbreak.
So you'll have a piracy rate of 80% instead of 20%.

Take a look at this, a sample xcode project with receipt validation:
https://github.com/roddi/ValidateStoreReceipt
Tambourin is offline   Reply With Quote
Old 01-15-2011, 09:07 AM   #4 (permalink)
Registered Member
 
Join Date: May 2010
Posts: 186
cacao is on a distinguished road
Default

Quote:
Originally Posted by Tambourin View Post
Except that on a mac no need to jailbreak.
So you'll have a piracy rate of 80% instead of 20%.

Take a look at this, a sample xcode project with receipt validation:
https://github.com/roddi/ValidateStoreReceipt
Yes, I tried that one. When I pasted it into my project there were two errors, something about "_cmd" and something about "self". I don't remember the exact output right now.
cacao is offline   Reply With Quote
Old 01-15-2011, 09:27 AM   #5 (permalink)
Registered Member
 
Join Date: May 2010
Posts: 186
cacao is on a distinguished road
Default

Quote:
Originally Posted by cacao View Post
Yes, I tried that one. When I pasted it into my project there were two errors, something about "_cmd" and something about "self". I don't remember the exact output right now.
I get "_cmd undeclared (first use in this function" and "self undeclared (first use in this function)" in the line:
Code:
NSAssert([bundleVersion isEqualToString:[[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleShortVersionString"]], 
			 @"whoops! check the hard-coded CFBundleShortVersionString!");
All I did is just pasting the files into my project and #import "validatereceipt.h"

Last edited by cacao; 01-15-2011 at 09:29 AM.
cacao is offline   Reply With Quote
Old 01-15-2011, 10:56 AM   #6 (permalink)
Registered Member
 
Join Date: May 2010
Posts: 186
cacao is on a distinguished road
Default

Well, I just commented this line out.
How do I test if the validation works?
I installed my app via the installer command but it does not start as it does not contain any receipt in the bundle.
cacao is offline   Reply With Quote
Old 01-15-2011, 11:46 AM   #7 (permalink)
Registered Member
 
Join Date: May 2010
Posts: 186
cacao is on a distinguished road
Default

I now installed it via sudo installer -store -pkg path-to-package -target /
My app is installed in Applications folder. However it exists because of the missing receipt I guess and it does not show a window asking for itunes account.
cacao is offline   Reply With Quote
Old 01-15-2011, 03:01 PM   #8 (permalink)
Registered Member
 
Join Date: Sep 2009
Posts: 1,018
Tambourin is on a distinguished road
Default

check the receipt page from Apple. At the bottom is the sample receipt with an explanation how to save it to your disk.
Tambourin is offline   Reply With Quote
Old 01-15-2011, 05:46 PM   #9 (permalink)
Registered Member
 
Join Date: May 2010
Posts: 186
cacao is on a distinguished road
Default

Thanks for your help!
Quote:
Originally Posted by Tambourin View Post
check the receipt page from Apple. At the bottom is the sample receipt with an explanation how to save it to your disk.
yes, but I think I also have to test with a receipt from the test account or why can I register test accounts? I'm confused.
I don't want to wait a month for my app being rejected because of wrong receipt validation :-(
cacao is offline   Reply With Quote
Old 01-21-2011, 06:42 AM   #10 (permalink)
Registered Member
 
Join Date: Sep 2009
Posts: 1,018
Tambourin is on a distinguished road
Default

Yes you can register a test account and test your app.
The account dialog box is opened when your app does exit with the special return code indicated in the doc.
Tambourin is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 370
7 members and 363 guests
husthlj, illogical, LegionMD, LunarMoon, mer10, Murphy, padsoftware
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,677
Threads: 94,127
Posts: 402,916
Top Poster: BrianSlick (7,990)
Welcome to our newest member, husthlj
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 07:11 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0