Not logged in. · Lost password · Register
Forum: News and announcements RSS
Security problem with version 1.5.3
Cross-site scripting issue, patch 1.5.3-a released
Avatar
Yves (Administrator) #1
User title: UNB developer & webmaster
Member since Jan 2004 · 3814 posts · Location: Erlangen, Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Subject: Security problem with version 1.5.3
[Deutsche Version folgt.]

Hello everybody.

Bad news today... I was just pointed to a security tracker website that told me about a cross-site scripting problem with the UNB 1.5.3. First I couldn't track it down because the error wasn't reproducible on this and my other productive board. Then I found out that these are not 1.5.3 release but the devel version from the same day. Anyway, somehow a mysterious bug has managed to remain undiscovered for quite a while now. It allows you to inject arbitrary HTML code in thread descriptions which itself isn't a big problem but allows {h,cr}ackers to steal your cookies for the forum you're visiting.

The problem exists in the public.lib.php, function ShowPath(), where the description is not HTML-encoded correctly as it should be. This seems to be the only difference between the release and devel version, both from the same day. The bug is only exploitable by creating a new topic somewhere on the board. If you don't allow guest posting, the user needs to be logged in. Also you'll find a new thread of it. If you have enabled notification of new threads, you'll see the malicious HTML code in the notification message in plaintext, if present.

As an immediate solution for admins, please apply the given patch. Users that are worried about their login data should either disable cookies for this domain (the board will work without them, only no auto-login is available then but you can let your browser do it) or disable JavaScript for the forum (the BBCode buttons won't work then anymore, but the board itself will continue functioning).

The download versions have just been updated. There's also a patch available there that fixes this bug only. Go here for the downloads. The lite version is no longer available for download until version 1.6.

I'm sorry for this issue, I'll continue trying to track down why this could happen. Let's see what UNB's version check can do now to notify most board admins. :) How I hate those evil people telling stuff like this other people and not even me. Please don't kill me for this, it's only the third security issue in 2,5 years, of which two have become public. Just compare this with other software you can find. ;)
♪ ...nanananah, all in all we’re just brilliant thieves, nanananah... ♪♬
Avatar
Yves (Administrator) #2
User title: UNB developer & webmaster
Member since Jan 2004 · 3814 posts · Location: Erlangen, Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Subject: Deutsche Zusammenfassung
Wie mir heute zu Ohren gekommen ist, gibt es eine Sicherheitslücke im UNB 1.5.3. Es handelt sich dabei um einen Cross-Site-Scripting-Fehler, der es u.a. ermöglicht, die Cookies der Board-Besucher auszuspähen. Damit sind dann z.B. die Logindaten eines Benutzers in Erfahrung zu bringen.

Das Problem besteht in der Datei public.lib.php, Funktion ShowPath(), in der die Themenbeschreibung nicht korrekt in HTML konvertiert wird. Der Fehler ist nur ausnutzbar, indem ein neues Thema erstellt wird. Wenn Gäste keine Themen starten dürfen, muss der Angreifer angemeldet sein. Außerdem hinterlässt er eben diesen Thread. Bei aktivierter Benachrichtigung über neue Themen kann man den HTML-Code im Klartext lesen.

Board-Admins sollten schnellstmöglich den verfügbaren Patch installieren. Benutzer können derweil Cookies für diese Domain deaktivieren (das Board funktioniert deshalb weiterhin, nur ist eine automatische Anmeldung nicht mehr möglich, was aber auch der Browser erledigen kann), oder JavaScript für das Forum deaktivieren (dann gehen ein paar Kleinigkeiten nicht mehr, aber nichts ernstes).

Die Downloadversion wurde bereits aktualisiert, außerdem gibt es einen Patch, der genau dieses Problem behebt. Hier geht's zu den Downloads. Die lite-Version ist bis zum Erscheinen der Version 1.6 nicht mehr verfügbar. Die automatische Versionsprüfung sollte den meisten Board-Admins mitteilen, dass eine neuere Version verfügbar ist.
♪ ...nanananah, all in all we’re just brilliant thieves, nanananah... ♪♬
Avatar
andré #3
User title: ratsuchender
Member since Mar 2005 · 124 posts · Location: Erfurt / Germany
Group memberships: Members
Show profile · Link to this post
hallo,
selbst auf die gefahr hin, das ich mich jetzt komplett zum brot mache - aber was zum geier soll ich mit der diff-datei machen....  :anx:

sorry, das ich hier frage, aber ich habe im board keine antwort gefunden.
vielen dank im voraus

andré
Avatar
Yves (Administrator) #4
User title: UNB developer & webmaster
Member since Jan 2004 · 3814 posts · Location: Erlangen, Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Entweder "google manpage diff" oder "man patch" oder wenn das nicht hilft, schau dir die Datei an und führe die Änderungen an den angegebenen Dateien von Hand durch. Sind ja nur 2 oder 3 Zeilen. Die Zeilen mit - werden entfernt, die mit + dafür eingesetzt. Die Zahlen um die @s rum sind Zeilennummern. Die letzte Lösung wäre ganz einfach das Board neu runterzuladen und die veränderten Dateien hochzuladen.
♪ ...nanananah, all in all we’re just brilliant thieves, nanananah... ♪♬
Avatar
alphanostrum #5
Member since Oct 2004 · 84 posts · Location: Germany/Berlin
Group memberships: Members
Show profile · Link to this post
bei aller hochachtung @yves, mit deiner diff-methode hast du hier aber einer der schwerstmöglichen varianten gewählt um ein fix an den mann/frau zu bringen. ein kleines patch-archiv mit dem hinweis, die enthaltenen datein zu überschreiben hätten es auch getan. ich denke die meisten, die dieses forum benutzen sind nutzer und keine entwickler oder freaks :rolleyes: .
das nur mal so als konstruktive kritik.
only GOD can judge me...
Avatar
Yves (Administrator) #6
User title: UNB developer & webmaster
Member since Jan 2004 · 3814 posts · Location: Erlangen, Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Naja ok, ansonsten kann man ja auch einfach das komplette Archiv runterladen und reinkopieren. Aber ich bastel heut noch ein ZIP zusammen.
♪ ...nanananah, all in all we’re just brilliant thieves, nanananah... ♪♬
Avatar
andré #7
User title: ratsuchender
Member since Mar 2005 · 124 posts · Location: Erfurt / Germany
Group memberships: Members
Show profile · Link to this post
hier ist das update-paeckchen...
The author has attached one file to this post:
update_unb-1.5.3-a.7z 23.6 kBytes
You have no permission to open this file.
jagdfalke #8
Member since Dec 2004 · 78 posts · Location: Sersheim, BaWü, Deutschland
Group memberships: Members
Show profile · Link to this post
@alphanostrum für die Benutzer, die dann eben doch Freaks sind, ist eine diff-Datei aber die mit Abstand einfachste Möglichkeit. Wobei man unter "Freak" hier jemanden zu verstehen hat, der ein paar Linux- oder UNIX-Kommandozeilen-Kenntnisse besitzt.  Deshalb finde ich es sehr gut, dass _unter anderem_ diff-Dateien (aka "patches" in der UNIX-Welt) zur Verfügung gestellt werden. (Aber das dürfte Yves von mir wohl schon wissen :-D)

noch was: AFAICS ist meine 1.5.4-dev, die hier im Einsatz ist, nicht betroffen.

zufällig gefunden, macht sich auch hier ganz gut:

Quote by Yves on 2005-09-15, 11:00:
No. Any development version beginning from the day before 1.5.3 release have this bug fixed, as this forum does, for example.
This post was edited on 2005-09-18, 22:42 by jagdfalke.
Avatar
Yves (Administrator) #9
User title: UNB developer & webmaster
Member since Jan 2004 · 3814 posts · Location: Erlangen, Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Subject: Updated patch
I was informed that the patch I provided wasn't working exactly as I imagined. Not for the actual problem, this is fixed for sure. But the update warning wouldn't disappear anymore. I have just updated the patch and the download archives. Here's what you need to do to make that update warning disappear:

Find bb_lib/version.def.php, replace line
  1. $VERSIONTIME = '20050913';
by
  1. $VERSIONTIME = '20050913-1940';
♪ ...nanananah, all in all we’re just brilliant thieves, nanananah... ♪♬
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Go to forum
This board is powered by the Unclassified NewsBoard software, 20110527-dev, © 2003-2011 by Yves Goergen
Page created in 243.5 ms (137.1 ms) · 91 database queries in 170 ms
Current time: 2012-02-07, 19:44:02 (UTC +01:00)