lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date: Thu, 19 Apr 2012 19:55:55 +0200
From: luks <>
Subject: Weak password reset token & code exec in ownCloud

= weak password reset token =

The way how ownCloud generates password reset tokens is highly insecure and
can be used to overtake arbitrary accounts by solely knowing the

file: core/lostpassword/index.php

15 $token = sha1($_POST['user']+uniqId());

due to the usage of the + operator, both operands (strings) are
interpreted as
numerical values
uniqId() is a simple timestamp in its hex representation. this
timestamps starts
with "4f" until 2012-7-13 and is therefore evaluated as a 4

this allows an attacker to trivially predict the generated token and
reset the

= code exec  =

user uploaded files are stored in the /data/<user>/files directory of the
ownCloud webroot. /data is secured by a .htaccess file ("deny from all")
but users can overwrite this setting by uploading a new .htaccess to their
files directory (e.g. "allow from all").

by uploading a php script and circumventing the .htaccess restriction users
are able to execute code by requesting the uploaded script via the
following url:

(uploading of a .htaccess file is obviously only needed on webservers
which support them in the first place).

= Disclosure Timeline =

2012-04-03: contacted the ownCloud team
2012-04-04: fixes
2012-04-19: Disclosure

You can find a metasploit module attached to this email which exploits
these two
vulnerabilities to achieve code execution.

Download attachment "owncloud.rb" of type "application/x-ruby" (4836 bytes)

Full-Disclosure - We believe in it.
Hosted and sponsored by Secunia -

Powered by blists - more mailing lists