Commit graph

331 commits

Author SHA1 Message Date
Lukas Fleischer
b69f548065 Add a package name blacklist.
Can be used to blacklist package names for normal users. TUs and
developers are not affected. This is especially useful if used together
with a cron job that updates the blacklist periodically, e.g. to reject
packages which are available in the binary repos (FS#12902).

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-02-11 14:43:22 +01:00
Lukas Fleischer
0e0e80aeea Minor bugfix in pkg_change_category().
This cleans up some broken MySQL query introduced by commit 57a5cbfd.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-02-09 08:58:44 +01:00
Dan McGee
7f5af61c88 Drop PackageLocations table and references
We don't need this anymore since all packages managed here are
well...managed here. Rip out all of the places we were using this field,
many of which depended on the magic value '2' anyway.

On the display side of things, we had a column that was always showing
'unsupported' that is now gone, and you can no longer sort by this column.

Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-02-01 12:41:08 +01:00
Lukas Fleischer
da2ebb667b aurjson: Escape wildcards in "LIKE" patterns (fixes FS#18626).
Percent signs ("%") and underscores ("_") are not escaped by
mysql_real_escape_string() and are interpreted as wildcards if combined
with "LIKE", so we need to deal with them separately.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-01-28 16:54:58 +01:00
Lukas Fleischer
389d3a552e Replaced rm_rf() by rm_tree().
Implemented recursive directory deletion in PHP properly without the use
of exec(). This improves security, performance and portability and makes
the code compatible with PHP's Safe Mode as well as with PHP setups that
disable exec() using the "disable_functions" directive.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-01-25 10:45:52 +01:00
Lukas Fleischer
556de318ae Build URLs from package names (fixes FS#15308, FS#19327).
Drop the "URLPath" field from the "Packages" table, build URLs from
package names instead.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-01-24 18:08:29 +01:00
Lukas Fleischer
60edcd04e5 Make external links in comments clickable (FS#20137).
Comments are now split at link boundaries and links are converted
separately. I find this to be a much cleaner way than re-converting
comments that have already been converted using htmlspecialchars(). This
also doesn't require any callback procedure.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-01-19 21:18:45 +01:00
Jacob Bang
53ad66e0a5 Add Danish translation
Signed-off-by: Laszlo Papp <djszapi@archlinux.us>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-12-04 22:58:12 -05:00
Dan Vratil
57a5cbfd88 Auto redirect from confirmation screens.
Finally move comment deletion and category editing into functions and
remove pkgedit.php

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
-Fix indentation
-Fix variable naming conflict $id vs $cid
2010-11-21 03:37:17 -05:00
Lukas Fleischer
eda713032c Add timestamp when a package is flagged out-of-date (FS#20848).
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
- resolve conflict and omit i18n changes.
2010-11-10 14:50:35 -05:00
Loui Chang
7933bbb53f acctfuncs: Make message translatable.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-10-09 08:44:26 -04:00
Viktor Leonhardt
9822b2e99b Fixing XSS vulnerability
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-10-02 11:51:46 -04:00
Loui Chang
a5502f0f8b Version 1.7.0
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-09-19 20:18:18 -04:00
Netanel Shine
b41ecf46b0 Add Hebrew translation.
Signed-off-by: Netanel Shine <netanelshine@gmail.com>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-08-08 17:35:45 -04:00
Denis Kobozev
b22f66b3ee Header and navbar consistent with Arch site redesign
-- Loui Chang
Change is_tu to check_user_privileges
Change div#archdev-navbar style

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-07-23 05:40:15 -04:00
Lukas Fleischer
b5bc6ab742 Confirmation when deleting packages
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-07-01 21:19:18 -04:00
Linas
7e3c624a69 aur.inc: generate_salt() now uses mt_rand()
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-06-16 17:11:10 -04:00
Lukas Fleischer
b18fb08ddc Add sorting by "Voted" and "Notify" fields
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-06-04 18:22:22 -04:00
Denis
290c436046 Support for storing salted passwords
To upgrade existing databases:

ALTER TABLE Users ADD Salt CHAR(32) NOT NULL DEFAULT '';

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-04-17 16:50:24 -04:00
Loui Chang
5b8b0757f4 pkg_comments: Only display 10 comments by default.
Add a mechanism to view all comments.

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-04-15 16:52:55 -04:00
Andrea Scarpino
24599ab6e3 add search only by name
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-04-15 15:26:20 -04:00
Andrea Scarpino
74f22eeb2a remove empty To field (FS#17584)
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-03-29 20:20:40 -04:00
Andrea Scarpino
13cd9591be Turn on package notification for adopted packages
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-03-15 22:20:08 -04:00
Andrea Scarpino
5091b11dad add link to account profile in out-of-date notification
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-03-10 18:58:47 -05:00
Loui Chang
61d0358162 acctfuncs: Fix some whitespace and formatting.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-02-21 08:59:24 -05:00
Loui Chang
c97f558898 Remove useless or redundant code for translations.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-01-09 18:24:53 -05:00
Loui Chang
06e400a2f0 translator.inc: Remove old and deprecated code.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-01-09 00:47:39 -05:00
Athurg Gooth
8eab9ed462 Make DEFAULT_LANG mean the default language for displayed messages.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2010-01-08 17:23:09 -05:00
Loui Chang
4b109cacc1 config.inc.proto: Change default paths to a more logical place.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-12-26 14:27:38 -05:00
Andrea Scarpino
0d35bd577a fix mysql.sock path
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-12-26 14:25:37 -05:00
Evangelos Foutras
6d65997f0c Add uid_from_email(), similar to uid_from_username
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-11-13 16:49:55 -05:00
flamelab
20ae93643f Add Greek Translation
Signed-off-by: flamelab <panosfilip@gmail.com>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-10-27 19:23:15 -04:00
Loui Chang
f40ce2d61b Fix Croatian language code in config.inc.proto.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-10-27 19:15:34 -04:00
Loui Chang
d5b87ec138 Version Bump 1.6.0
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-10-26 13:16:26 -04:00
Loui Chang
92b19e78ac aurjson: Only return an error string if utf8_encode returns an empty string.
This allows 0 and '0' values to pass.

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-10-23 12:35:02 -04:00
Laszlo Papp
87a8298114 Add Croatian translation
Signed-off-by: Laszlo Papp <djszapi@archlinux.us>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-10-01 17:47:54 -04:00
Laszlo Papp
4485907e5b Add Norwegian translation
Signed-off-by: Hans-Kristian Arntzen <maister@archlinux.us>
Signed-off-by: Laszlo Papp <djszapi@archlinux.us>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-10-01 16:47:09 -04:00
Laszlo Papp
deb8595a1f Add Czech translation
Signed-off-by: Daniel Kozák <kozzi11@gmail.com>
Signed-off-by: Laszlo Papp <djszapi@archlinux.us>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-10-01 16:47:04 -04:00
Loui Chang
21e0ff2207 Fix json info output.
Commit 325347a introduced a regression causing an improper database
query.

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-10-01 16:41:22 -04:00
Slobodan Terzic
9260e1c328 Serbian translation for AUR
Signed-off-by: Slobodan Terzic <githzerai06@gmail.com>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-09-28 19:48:51 -04:00
elij
325347a268 Add maintainer search to json interface. Closes FS#15947
Fix for maintainer search ticket: FS#15947
Also http://mailman.archlinux.org/pipermail/aur-dev/2009-September/000892.html

Fixed some problems with selecting the proper data fields in the
original patch. - Loui

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-09-28 15:44:31 -04:00
elij
a6d5cb71a6 fix content-type when sending jsonp
jsonp callback should have a content type of text/javascipt,
since it specifies a callback function wrapping json data,
and is not soley json data.

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-09-28 15:17:07 -04:00
Gergely Imreh
4d1eb4dd7a Fix: FS#15526 non-UTF8 character in rpc output
Currently AUR does not check the uploaded packages, whether they are
correctly in UTF8 encoding. If there are fields (such as $pkgdesc)
that contain such non-UTF8 characters, the rpc interface chokes on
those fields: even if there's data successfully retrieved from the
database, rpc returns "null".
In an effort to make such errors in the PKGBUILDs debugged more easily,
let's force rpc to have more useful output: try to convert non-UTF8
fields to UTF8. If it's a success, good. Partial success (some characters
showing as \uXXXX) is ok. Failure results in error message printed to that
field.

Signed-off-by: Gergely Imreh <imrehg@gmail.com>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-09-16 07:50:44 -04:00
Loui Chang
1bf54a32c4 aurjson: Use call_user_func to call functions.
call_user_func_array is unnecessary.

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-09-14 17:03:50 -04:00
Laszlo Papp
56990b3748 Initial Hungarian Translation
Signed-off-by: Laszlo Papp <djszapi2@gmail.com>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-08-26 20:02:30 -04:00
Sergej Pupykin
3fd08d5715 remove community
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-08-26 00:14:32 -04:00
Dan McGee
46f2798524 Use include_once where applicable
All of these are sourcing function libraries so we don't need to include
them more than once. Things that insert actual HTML into the output were
left calling include().

Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-08-11 13:58:12 -04:00
Loui Chang
cebf4f006e Add Romanian to config.inc.proto and AUTHORS.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-08-02 17:39:04 -04:00
Loui Chang
9f854efe86 Bump version to 1.5.6.4
I forgot to bump the version again!

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-06-25 00:12:50 -04:00
Loui Chang
610733eafd Remove excess whitespace.
Signed-off-by: Loui Chang <louipc.ist@gmail.com>
2009-06-25 00:05:44 -04:00