Restore ObjC1 compatibility
This commit is contained in:
parent
820f0a04d1
commit
8c3b57e107
1 changed files with 6 additions and 3 deletions
|
@ -255,8 +255,9 @@
|
||||||
OFString *name;
|
OFString *name;
|
||||||
OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
|
OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
|
||||||
OFList *CNs = [[self subject] objectForKey: OID_commonName];
|
OFList *CNs = [[self subject] objectForKey: OID_commonName];
|
||||||
|
OFEnumerator *enumerator = [CNs objectEnumerator];
|
||||||
|
|
||||||
for (name in CNs) {
|
while ((name = [enumerator nextObject]) != nil) {
|
||||||
if ([self X509_isAssertedDomain: name
|
if ([self X509_isAssertedDomain: name
|
||||||
equalDomain: domain]) {
|
equalDomain: domain]) {
|
||||||
[pool release];
|
[pool release];
|
||||||
|
@ -274,8 +275,9 @@
|
||||||
OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
|
OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
|
||||||
OFDictionary *SANs = [self subjectAlternativeName];
|
OFDictionary *SANs = [self subjectAlternativeName];
|
||||||
OFList *assertedNames = [SANs objectForKey: @"dNSName"];
|
OFList *assertedNames = [SANs objectForKey: @"dNSName"];
|
||||||
|
OFEnumerator *enumerator = [assertedNames objectEnumerator];
|
||||||
|
|
||||||
for (name in assertedNames) {
|
while ((name = [enumerator nextObject]) != nil) {
|
||||||
if ([self X509_isAssertedDomain: name
|
if ([self X509_isAssertedDomain: name
|
||||||
equalDomain: domain]) {
|
equalDomain: domain]) {
|
||||||
[pool release];
|
[pool release];
|
||||||
|
@ -296,6 +298,7 @@
|
||||||
OFDictionary *SANs = [self subjectAlternativeName];
|
OFDictionary *SANs = [self subjectAlternativeName];
|
||||||
OFList *assertedNames = [[SANs objectForKey: @"otherName"]
|
OFList *assertedNames = [[SANs objectForKey: @"otherName"]
|
||||||
objectForKey: OID_SRVName];
|
objectForKey: OID_SRVName];
|
||||||
|
OFEnumerator *enumerator = [assertedNames objectEnumerator];
|
||||||
|
|
||||||
if (![service hasPrefix: @"_"])
|
if (![service hasPrefix: @"_"])
|
||||||
service = [service stringByPrependingString: @"_"];
|
service = [service stringByPrependingString: @"_"];
|
||||||
|
@ -303,7 +306,7 @@
|
||||||
service = [service stringByAppendingString: @"."];
|
service = [service stringByAppendingString: @"."];
|
||||||
serviceLength = [service length];
|
serviceLength = [service length];
|
||||||
|
|
||||||
for (name in assertedNames) {
|
while ((name = [enumerator nextObject]) != nil) {
|
||||||
if ([name hasPrefix: service]) {
|
if ([name hasPrefix: service]) {
|
||||||
OFString *asserted;
|
OFString *asserted;
|
||||||
asserted = [name substringWithRange: of_range(
|
asserted = [name substringWithRange: of_range(
|
||||||
|
|
Reference in a new issue