• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Mac OS X 10.5.8 update breaks tokenize function in -[NSXMLNode objectsForXQuery:error:]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Mac OS X 10.5.8 update breaks tokenize function in -[NSXMLNode objectsForXQuery:error:]


  • Subject: Re: Mac OS X 10.5.8 update breaks tokenize function in -[NSXMLNode objectsForXQuery:error:]
  • From: Michael Link <email@hidden>
  • Date: Thu, 6 Aug 2009 17:16:44 -0500

After some more investigation I've discovered that XQuery was updated in Mac OS X 10.5.8 as part of a security vulnerability in the PCRE library which it includes.

http://support.apple.com/kb/HT3757 (scroll to bottom of page)

Which also explains why all XQuery functions using regular expressions are also broken. Digging into the PCRE portion of the XQuery code reveals the following PCRE error string after trying to compile a regular expression:

"this version of PCRE is not compiled with PCRE_UTF8 support"

#0 0x0010f430 in pcre_compile
#1 0x00100495 in -[XQueryRegEx initExpr:withFlags:]
#2 0x000ff944 in +[XQueryRegEx regExp:withFlags:]
#3 0x000ce8e3 in fn_tokenize
#4 0x000db9cd in -[XQueryFunctionCall evaluateWithContext:]
#5 0x000f62b5 in -[XQueryExprList evaluateWithContext:]
#6 0x00102a9a in -[XQueryContext evaluateXQuery:constants:contextItem:error:]
#7 0x92201d98 in -[NSXMLNode objectsForXQuery:constants:error:]
#8 0x92303338 in -[NSXMLNode objectsForXQuery:error:]
#9 0x00001d04 in -[Bug7037807 performXQuery:] at Bug7037807.m:40
#10 0x00001c15 in -[Bug7037807 awakeFromNib] at Bug7037807.m:27
#11 0x9310f7f5 in -[NSSet makeObjectsPerformSelector:]
#12 0x910d2d8e in -[NSIBObjectData nibInstantiateWithOwner:topLevelObjects:]
#13 0x910c8fba in loadNib
#14 0x910c891c in +[NSBundle(NSNibLoading) _loadNibFile:nameTable:withZone:ownerBundle:]
#15 0x910c855f in +[NSBundle(NSNibLoading) loadNibFile:externalNameTable:withZone:]
#16 0x910c849d in +[NSBundle(NSNibLoading) loadNibNamed:owner:]
#17 0x910c814c in NSApplicationMain
#18 0x00001ae8 in main at main.m:13


Dump of assembler code for function pcre_compile:
0x0010f3fb <pcre_compile+0>:	push   ëp
0x0010f3fc <pcre_compile+1>:	mov    %esp,ëp
0x0010f3fe <pcre_compile+3>:	sub    $0x28,%esp
0x0010f401 <pcre_compile+6>:	mov    0x18(ëp),êx
0x0010f404 <pcre_compile+9>:	movl   $0x0,0x8(%esp)
0x0010f40c <pcre_compile+17>:	mov    êx,0x14(%esp)
0x0010f410 <pcre_compile+21>:	mov    0x14(ëp),êx
0x0010f413 <pcre_compile+24>:	mov    êx,0x10(%esp)
0x0010f417 <pcre_compile+28>:	mov    0x10(ëp),êx
0x0010f41a <pcre_compile+31>:	mov    êx,0xc(%esp)
0x0010f41e <pcre_compile+35>:	mov    0xc(ëp),êx
0x0010f421 <pcre_compile+38>:	mov    êx,0x4(%esp)
0x0010f425 <pcre_compile+42>:	mov    0x8(ëp),êx
0x0010f428 <pcre_compile+45>:	mov    êx,(%esp)
0x0010f42b <pcre_compile+48>:	call   0x10eb91 <pcre_compile2>
0x0010f430 <pcre_compile+53>:	leave
0x0010f431 <pcre_compile+54>:	ret
End of assembler dump.
(gdb) x/i $eip
0x10f430 <pcre_compile+53>:	leave

(gdb) p *(int*)($ebp + 16)
$26 = -1073745996
(gdb) p *$26
$27 = 1254561
(gdb) x/s $27
0x1324a1 <error_texts+1033>: "this version of PCRE is not compiled with PCRE_UTF8 support"


Did someone forget to turn on a compile flag?

--
Michael
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Mac OS X 10.5.8 update breaks tokenize function in -[NSXMLNode objectsForXQuery:error:] (From: Michael Link <email@hidden>)

  • Prev by Date: Re: Disabling Exposé in SystemUIMode
  • Next by Date: Re: Disabling Exposé in SystemUIMode
  • Previous by thread: Mac OS X 10.5.8 update breaks tokenize function in -[NSXMLNode objectsForXQuery:error:]
  • Next by thread: Two right buttons on UINavigationBar?
  • Index(es):
    • Date
    • Thread