diff --git a/checkin_notes b/checkin_notes
index 0cbac426a3..4568ddb954 100755
--- a/checkin_notes
+++ b/checkin_notes
@@ -2356,3 +2356,32 @@ David Nov 9 2002
test_uc.php
tools/
process_result_template.C
+
+David Nov 9 2002
+ - Simplified account creation.
+ Only screen name, email address required; country, zip optional.
+ Only account ID required to log in
+ Removed web password from form;
+ projects can add this if they want.
+ - Change "authenticator" to "account ID" everywhere
+ - made country list appear on account creation form
+
+ todo
+ db/
+ constraints.sql
+ db.h
+ doc/
+ account.html
+ app.html
+ create_project.html
+ participate.html
+ startup.html
+ html_user/
+ renamed create_account.php to create_account_form.php
+ renamed login.php to login_form.php
+ download.php
+ index.php
+ login_action.php
+ util.inc
+ test/
+ test_uc.php
diff --git a/db/constraints.sql b/db/constraints.sql
index 6b43c35dee..6920ef3ee1 100644
--- a/db/constraints.sql
+++ b/db/constraints.sql
@@ -11,6 +11,8 @@ alter table app_version
alter table user
add unique(email_addr);
+alter table user
+ add unique(authenticator);
alter table user
add index ind_tid (teamid);
diff --git a/db/db.h b/db/db.h
index fa1cde7f6b..9dc04528b2 100644
--- a/db/db.h
+++ b/db/db.h
@@ -102,7 +102,7 @@ struct USER {
unsigned int create_time;
char email_addr[256];
char name[256];
- char web_password[256];
+ char web_password[256]; // optional
char authenticator[256];
char country[256];
char postal_code[256];
diff --git a/doc/account.html b/doc/account.html
index 7ac839bd41..e165c84bfd 100644
--- a/doc/account.html
+++ b/doc/account.html
@@ -10,20 +10,17 @@ This involves filling out a form with
An email address.
A public "screen name" (real name or nickname).
-This also serves as your login name for the project's web site.
-
A web password
-(used to log in to the project's web site).
Country (optional)
Postal Code (optional)
-
You will receive an email containing an account ID
+
You will receive an email containing an account key
(a long random string).
Download and install the BOINC client program.
-It will ask for a project URL and an account ID.
+It will ask for a project URL and an account key.
Enter the project's URL,
-cut and paste the account ID from the email.
+cut and paste the account key from the email.
Platforms, applications, and versions
+Applications and versions
-
Platforms, applications, and versions
-
-A platform is a compilation target (Windows/Intel,
-Linux/Intel, MacOS/PPC, etc.).
-Platforms are maintained in the platform table in the BOINC DB,
-and can be created using the add utility.
+
Applications and versions
-An application consists of an executable program,
-perhaps with versions for various platforms.
+An application represents a particular distributed computation;
+it consists of a program (perhaps with versions for different platforms)
+and a set of workunits and results.
A project can operate many applications.
Applications are maintained in the application table in the BOINC DB,
and can be created using the add utility.
@@ -32,13 +28,14 @@ Mac version 304.
Each application has a minimum version.
-When a client is sent work for an application, it is also sent
-the latest application version for its platform.
+When a client is sent work for an application,
+it is also sent the latest application version for its platform.
It is sent work only if this version is the minimum or greater.
Application versions are maintained in the app_version table
-in the BOINC DB, Each entry includes an XML document describing the
+in the BOINC DB.
+Each entry includes an XML document describing the
files that make up the application version:
<file_info> ...
@@ -57,5 +54,5 @@ files that make up the application version:
</file_ref>
</app_version>
-The add utility provides a
-simplified interface for creating application versions.
+Application versions can be created using the
+add utility program.
diff --git a/doc/create_project.html b/doc/create_project.html
index a86423a840..e171553e9a 100644
--- a/doc/create_project.html
+++ b/doc/create_project.html
@@ -1,4 +1,5 @@
Creating a BOINC project
+
Creating a BOINC project
diff --git a/doc/participate.html b/doc/participate.html
index 6759e44dd7..2cf02bf8a9 100644
--- a/doc/participate.html
+++ b/doc/participate.html
@@ -1,3 +1,5 @@
+Participating in BOINC projects
+
Participating in BOINC projects
Joining a project
diff --git a/doc/startup.html b/doc/startup.html
index 7fc2ffc866..0d7c792ec0 100644
--- a/doc/startup.html
+++ b/doc/startup.html
@@ -6,19 +6,19 @@
You can join a second and subsequent projects as follows.
Visit the new project's web site and create an account.
-Note: if you wish, you can use different email, user name or password
+Note: if you wish, you can use different email and name
than those of your first account.
-
Receive an email containing an account ID (a long random string).
-
Run the BOINC
+
Receive an email containing an account key (a long random string).
+
Run the BOINC client, and select the Add Project command.
+Enter the project's URL and your account key.
-
How preferences are stored
+
Where to edit your preferences
Your preferences are stored on BOINC servers.
-When your hosts communicate with a server they get the
-latest preferences, and they pass along these preferences
-to other servers.
+When your hosts communicate with a server they get the latest preferences,
+and they pass along these preferences to other servers.
Thus, when you change your preferences on one project's web site,
these changes will quickly spread to all your hosts,
and to the web sites of all the other projects in which you participate.
diff --git a/html/user/create_account.php b/html/user/create_account.php
deleted file mode 100644
index 51911ef75c..0000000000
--- a/html/user/create_account.php
+++ /dev/null
@@ -1,13 +0,0 @@
-
diff --git a/html/user/create_account_form.php b/html/user/create_account_form.php
new file mode 100644
index 0000000000..f02c05d4c6
--- /dev/null
+++ b/html/user/create_account_form.php
@@ -0,0 +1,69 @@
+
+
+
\n";
- echo "If you are not $user->name or would wish to log in as another user ";
- echo "login here.";
- } else {
- echo "
\n";
- }
+ page_head("Home page");
?>
-
-This distributed computing project is running on the BOINC software platform.
-BOINC is a software platform for public-participation distributed
-computing projects.
-Users are allowed to simultaneously participate in multiple projects
-and to choose how to allocate their resources for each project.
+
What we're doing
+The Astropulse project, based at UC Berkeley,
+uses the idle time of thousands of computers to
+analyze radio telescope signals.
+Astropulse uses BOINC,
+which allows you to participate in multiple
+distributed computing projects at the same time.
-
Joining this project
-First, create an account.
-You will be sent an authenticator
-to the email specified.
-After successfully creating an account,
-download the BOINC client.
-Install and run the client.
-When it asks you for authenticator,
-cut and paste the authenticator from the email.
+
There's already an account with that email address. Click the Back button\n"
- ." on your browser to edit your information, or login to your \n"
- .PROJECT." account.
- Your account has been created successfully.
- In order to run the client you will need a BOINC key.
- A key will be sent to the email address you provided,
- and you can simply copy and paste the key,
- which will be a string of letters and numbers,
- in the location indicated when you run the client.
-
Couldn't create account.
- Please try again later.
\n
- \n";
- }
- }
+ $authenticator = $HTTP_POST_VARS["authenticator"];
+ $email_addr = $HTTP_POST_VARS["email_addr"];
+ $password = $HTTP_POST_VARS["password"];
+ if (strlen($authenticator)) {
+ $query = "select * from user where authenticator='$authenticator'";
+ }
+ $query = sprintf(
+ $query = "select * from user where email_addr='$email_addr'";
+ );
+ $result = mysql_query($query);
+ if ($result) {
+ $user = mysql_fetch_object($result);
+ mysql_free_result($result);
+ }
+ if (!$user) {
+ page_head("Log in");
+ echo "There is no account with the account key or email address you have entered.\n";
+ echo "Click the Back button to try again.\n";
+ } else if (strlen($password)) {
+ page_head("Log in");
+ if ($user->web_password != $HTTP_POST_VARS["existing_password"]) {
+ echo "Bad password.";
}
+ } else {
+ setcookie("auth", $user->authenticator, time()+100000000);
+ page_head("User Page");
+ show_user_page_private($user);
}
page_tail();
?>
diff --git a/html/user/login_form.php b/html/user/login_form.php
new file mode 100644
index 0000000000..3f56fa9715
--- /dev/null
+++ b/html/user/login_form.php
@@ -0,0 +1,21 @@
+
+
+
+ Your account key:
+
+
+
+
+
+
+
+
+
+
";
+
+ page_tail();
+?>
diff --git a/html/user/util.inc b/html/user/util.inc
index 2366255687..b9101cd98e 100644
--- a/html/user/util.inc
+++ b/html/user/util.inc
@@ -21,9 +21,7 @@ define("TITLE_COLOR", " bgcolor=000000 ");
define("TITLE_FONT", " ");
define("BODY_COLOR", " bgcolor=ffffff ");
define("NOLOGIN", "Not logged in. Click here to login.\n");
-define("BADPASS", "The password you entered is incorrect. Click the Back button on your browser to re-enter your password or try again later.");
-define("DIFFPASS", "You've typed two different passwords. Click the Back button on your browser to edit your information, making sure you type the same password in both password fields.");
-define("PROJECT", "Sample project");
+define("PROJECT", "Astropulse");
function get_user_from_cookie() {
@@ -49,7 +47,7 @@ function page_head($title) {
// Put your project title and logo here
- echo "
Sample Project
\n";
+ echo "
".PROJECT."
\n";
echo "
$title
\n";
}
diff --git a/test/test_uc.php b/test/test_uc.php
index 4caa70f13b..d0361f6f74 100644
--- a/test/test_uc.php
+++ b/test/test_uc.php
@@ -9,15 +9,15 @@
$user = new User();
$host = new Host($user);
- // the following is optional
- $app = new App("core_client");
- $app_version = new App_Version($app);
- $project->add_app($app);
- $project->add_app_version($app_version);
-
$app = new App("upper_case");
$app_version = new App_Version($app);
+ // the following is optional (makes client web download possible)
+ $core_app = new App("core client");
+ $core_app_version = new App_Version($core_app);
+ $project->add_app($core_app);
+ $project->add_app_version($core_app_version);
+
$project->add_user($user);
$project->add_app($app);
$project->add_app_version($app_version);
diff --git a/todo b/todo
index 2fa8ab5f5f..5b7ab524e9 100755
--- a/todo
+++ b/todo
@@ -1,4 +1,8 @@
-protection mechanism for project admin web
+use PHP session mechanism instead of our own cookies
+
+use https for login (don't sent account key or password in clear)
+
+protect project admin web pages (htaccess)
Deadline mechanism for results
- use in result dispatching