We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent df764ae commit 674731dCopy full SHA for 674731d
iReSign/iReSign/iReSignAppDelegate.m
@@ -411,6 +411,16 @@ - (void)checkEntitlementsFix:(NSTimer *)timer {
411
412
- (void)doEntitlementsEdit
413
{
414
+ //macOS 10.12 bug: /usr/bin/security appends a junk line at the top of the XML file.
415
+ if ([entitlementsResult containsString:@"SecPolicySetValue"])
416
+ {
417
+ NSRange newlineRange = [entitlementsResult rangeOfString:@"\n"];
418
+ if(newlineRange.location != NSNotFound) {
419
+ entitlementsResult = [entitlementsResult substringFromIndex:newlineRange.location];
420
+ }
421
422
+ //end macOS 10.12 bug fix.
423
+
424
NSDictionary* entitlements = entitlementsResult.propertyList;
425
entitlements = entitlements[@"Entitlements"];
426
NSString* filePath = [workingPath stringByAppendingPathComponent:@"entitlements.plist"];
0 commit comments