Commit Graph

763 Commits

Author SHA1 Message Date
David Anderson 945a0f9f7a admin web: fixes to cancel_workunits.php 2015-02-13 10:13:47 -08:00
David Anderson 4b918967b8 admin web: appearance tweaks 2015-01-27 13:28:51 -08:00
David Anderson 80d792265b admin web: appearance tweaks 2015-01-27 13:03:23 -08:00
David Anderson fa7ded6751 admin web: typo fix 2015-01-26 10:14:57 -08:00
David Anderson 45f820b30b admin web: add more flexible interface for canceling jobs (from Bernd) 2015-01-23 11:13:44 -08:00
David Anderson 037f1b3eb2 web: fix PHP errors on empty team search; when delete spam team, delete user too 2015-01-09 10:54:05 -08:00
David Anderson c9d67c0a99 web: server status fix
Change the way we see if a web server is running on a host.
Fetch http://host, and check for 2xx or 4xx status.
With this change, new server_status.php works on SETI@home.
2014-12-01 12:51:12 -08:00
David Anderson dc2ecf6837 web: server status fix
remote_server_status.php (script for seeing if remote daemons are running)
did this by ps -C command,
and seeing if the last line of the output contained the command.
This didn't work for SETI@home, because the daemons are symbolic links in bin/.
The command that ps knows about is the file name after resolving the link.
This generally doesn't contain the original command name,
so it would look like no remote daemons are running.

Fix: look up the PID (in pid_host/xxx.pid) and use "ps PID".
This also correctly distinguishes between daemons
that use the same program on the same host.
2014-12-01 12:16:31 -08:00
David Anderson 94ecca5b80 web: more work on server status page
There were a couple of issues:
- the server status page is served from a web server, say X.
  A daemon is "remote" if it runs on a machine other than X.
  This is not the same as having a <host> element in the daemon's
  config.xml entry.
  Add logic to correctly classify daemons as remote or not.
- get rid of the <uldl_host> stuff.
  There can be separate upload and download servers,
  and they are identified by <upload_url> and <download_url>.
  They may or not be remote;
  to decide this, compare the host part of the URL
  with the host part of the project's master URL.
- Hosts are specified with the machine name (e.g. isaac)
  or domain name (isaac.ssl.berkeley.edu).
  Keep track of this distinction.
2014-12-01 00:44:51 -08:00
David Anderson b391e109df web: reimplement server status page to support remote daemons
The server status page was one of the oldest and cruftiest parts of BOINC.
It flew in the face of the model/view/controller paradigm,
and had the kind of convoluted structure that beginning programmers
often produce.
Plus it didn't work with remote daemons.
2014-11-30 20:25:39 -08:00
David Anderson db6592e6fc admin web: fix bug in "delete user" function
Also:
- use "admin_error_page()" instead of "error_page()" in admin pages
- add footer w/ Main Page link to admin pages
- code cleanup in delete user function
2014-10-29 12:25:35 -07:00
David Anderson 267ef49789 delete_spammers.php: add --user_url option
This deletes accounts with a nonempty URL, no hosts and no forum posts.

Also fix typo in util.inc
2014-10-19 00:29:50 -07:00
David Anderson 39a2d6d496 - admin web: more mysqli fixes 2014-10-09 11:19:31 -07:00
David Anderson c0e7da4931 admin web: fix bugs related to mysqli changes 2014-10-09 09:29:05 -07:00
David Anderson 40d68bc688 server: when deleting user, remove related DB records
When deleting a user (from the delete_spammers.php script),
remove records that refer to that user in
private_messages, notify, credit_user, badge_user, and friend tables.

Notes:
- This change eliminates some dangling references,
  but in general a BOINC DB doesn't have referential integrity.
  The code should check for dangling references.
- Functions like BoincUser::delete() should delete a user record,
  not try to remove things that refer to it.
  The function delete_user() (in user.inc) does this.
2014-10-08 12:14:34 -07:00
David Anderson 644690b100 server: add indices for user_submit, user_submit_app tables 2014-10-08 12:13:36 -07:00
David Anderson 964d37b009 web: fix button problem on IE; from Christian 2014-10-07 05:33:39 -07:00
David Anderson 97706bf18d web: tweaks 2014-10-07 04:02:43 -07:00
David Anderson 63ab243996 admin web: call project-defined function admin_index_extra() in main page 2014-10-05 08:15:05 -07:00
David Anderson b1bc33a39b One-click attach: cookie expire time 2014-10-05 01:31:44 -07:00
David Anderson a71ab2796a server: add --teams option to delete_spammers.php
See http://boinc.berkeley.edu/trac/wiki/ProtectionFromSpam#Cleaningupspam
2014-10-04 01:01:25 -07:00
David Anderson 2e127dd963 concierge: see if project is on list 2014-10-04 00:45:24 -07:00
David Anderson e6ecb981b3 web: change CSS usage to partly match Twitter Bootstrap. From Christian Beer. 2014-10-02 12:15:54 -07:00
David Anderson 2ea2077b2b web: change NO_MYSQLI feature to fix recursive-include problems
I seemed to be playing whack-a-mole with problems related to
recursive inclusions of project.inc.
Solve this by changing how the use of mysqli can be inhibited:
instead of defining NO_MYSQL in project, put <no_mysqli/> in config.xml
2014-09-28 12:15:26 -07:00
David Anderson 93f7def3fa web: show badges at bottom of forum-post box 2014-09-24 00:55:03 -07:00
David Anderson 6408766057 admin web: by default don't show deprecated app versions on mgt page 2014-09-21 21:06:31 -07:00
David Anderson 3abed383e5 web PHP code: use mysqli everywhere if available
Change all the PHP code to use _mysql_query() instead of mysql_query()
(and similar for other functions).
_mysql_query() uses the mysqli API if available, else the old API.

Going forward, all PHP code should the DB abstration layer if possible;
else it should use the _mysql_* functions.
2014-09-04 12:00:09 -07:00
David Anderson dc02b627b5 server: add PHP script to decay per-app credit 2014-09-03 22:24:25 -07:00
David Anderson ce8e78e10e web: add script for granting badges based on per-subproject credit totals
See http://boinc.berkeley.edu/trac/wiki/PerAppCredit
2014-08-18 13:48:27 -07:00
David Anderson c4a480be29 XML stats export: fix bug in credit-by-app files 2014-08-18 10:00:59 -07:00
David Anderson 8f0893b140 db_dump: export credit_by_app files in XML stats
It does this by running html/ops/export_credit_by_app.php.
I added a cmdline arg to this script saying where to write the files.
2014-08-17 23:29:41 -07:00
David Anderson 126183ce19 server: add script to export per-app credit data as XML
Add an official notion of "sub-project": see
http://boinc.berkeley.edu/trac/wiki/PerAppCredit
2014-08-15 16:20:40 -07:00
David Anderson dbd2d03a0d server/web: add support for per-application credit
See http://boinc.berkeley.edu/trac/wiki/PerAppCredit
If enabled (by the <credit_by_app> config flag)
validators will maintain on a per-(app, user, credit type) basis,
and same for teams,
in new DB tables credit_user and credit_team.
This info is displayed in the web site, on user and team pages,
using project-supplied functions to generate the HTML.

Note: update_stats doesn't decay the recent-average values
for per-app credit; I'll add this if needed.
2014-08-15 14:01:32 -07:00
David Anderson 3788d0c337 web: code cleanup 2014-08-11 14:57:34 -07:00
David Anderson cd1a12d4f4 web: show badges in more places
Also: improve the badge admin page
Also: zebra-stripe top user and team lists
2014-08-11 09:50:06 -07:00
David Anderson e6b7da8278 admin web: allow changing plan class of app versions 2014-07-25 12:11:23 -07:00
David Anderson b9f0fe0298 admin web: add "assigned jobs" link 2014-07-24 23:42:45 -07:00
David Anderson 3156ea56fd delete spammers script: fix --id_range command 2014-07-23 09:51:02 -07:00
David Anderson 9df6e43863 web: handle the case of missing user records in a few places
The delete-spammers script was creating dangling user references
(although this is now fixed).
Detect these dangling references and clean them up.
2014-07-12 14:32:59 -07:00
David Anderson cb1bb4069a web: be more thorough when deleting users
When deleting a spammer, delete
- forum_logging
- private messages
- notifications

Also, when displaying private messages, check if sender
doesn't exist, and delete if so
2014-07-11 15:20:01 -07:00
David Anderson 41a2b2c658 admin web: fix warning 2014-06-24 09:09:36 -07:00
David Anderson a243e19bdc web: replace lookup_* functions with their DB API equivalents
also:
- fix bug in db_cleanse.php
- replace some uses of deprecated mysql_* API
2014-06-23 18:29:20 -07:00
David Anderson eebfca71d3 delete_spammers script: log start/end times 2014-06-21 09:32:41 -07:00
David Anderson 8ffef379b8 update_forum_activities: handle team forum posts properly 2014-06-18 16:39:12 -07:00
David Anderson 9fbe00a2ff delete_spammers script: tweaks 2014-06-16 16:52:58 -07:00
David Anderson b7478c09c3 delete_spammers: fix comments 2014-06-10 14:03:12 -07:00
David Anderson 780284b9fa delete_spammers tweak 2014-06-10 00:45:45 -07:00
David Anderson d6962a70f0 delete_spammers.php script: add feature for delete forum spammers 2014-06-10 00:39:58 -07:00
David Anderson 4616d1d0c3 mass email scripts: check for PHP_MAILER properly 2014-06-06 15:57:52 -07:00
David Anderson f02c349800 server: add "beta" flag to app versions
Add beta flag to app version table.
If set, send that app version only to users whose prefs allow beta work.
2014-06-05 09:51:01 -07:00