Commit Graph

1790 Commits

Author SHA1 Message Date
David Glasser
173d4e46d7 History.md: Mention OAuth support. 2012-10-10 22:27:12 -07:00
David Greenspan
d5ccedf8c1 harness for viewing states of accounts-ui 2012-10-10 22:16:07 -07:00
David Glasser
00eda43420 OAuth login to an existing account now *does* update the services.PROVIDER
field (eg, to refresh access tokens) but does *not* update anything else (which
is effectively a no-op change because in practice the only thing that it
attempted to update was "profile" but because existing fields were not
overridden, this never did anything).

Remove the "extra" argument from createUser and related functions. Add a new
"profile" option to the main options dictionary, interpreted by
defaultCreateUserHook.
2012-10-10 21:55:02 -07:00
David Glasser
65872c3c1c Test for 98111eb. 2012-10-10 21:54:11 -07:00
David Glasser
98111eb6c9 If for some reason your user has no published fields, make sure Meteor.user()
still returns a (trivial) object.
2012-10-10 21:42:39 -07:00
David Glasser
2c6f991228 Ensure that "meteor list" doesn't truncate any package descriptions. 2012-10-10 17:27:00 -07:00
David Glasser
dd9d213a30 First draft of Meteor 0.5.0 release notes. 2012-10-10 17:16:20 -07:00
David Greenspan
4bef61162d fix disabled "Save Configuration" button to not be clickable 2012-10-10 17:06:11 -07:00
David Glasser
3cf7dce666 Privatize the "force" option to Meteor.reconnect (added on the auth branch and
mostly used for manual testing).
2012-10-10 16:57:39 -07:00
David Glasser
59b0b1fbc2 Fixes to Google OAuth configuration instructions (a typo fix, a preliminary step
for your first time, one link changed its name)
2012-10-10 14:30:54 -07:00
David Glasser
f63daf3723 Don't convert Windows newlines to Unix in SHA-256 code.
Add license for SHA-256 code to LICENSE.txt.
2012-10-10 14:11:54 -07:00
David Glasser
a4639df317 Add license for jsbn (used by srp). 2012-10-10 14:11:54 -07:00
Avital Oliver
59eb095b30 accounts-weibo: Minor configuration text change 2012-10-10 13:11:37 -07:00
David Glasser
6f522147bb Fix typo in docs (spotted by: dandv). 2012-10-10 10:48:34 -07:00
Avital Oliver
1c6c2e1398 accounts-ui: order services alphabetically 2012-10-10 00:56:11 -07:00
Avital Oliver
d1e3e2475a accounts-ui: Fix right-hanging dropdowns 2012-10-10 00:25:50 -07:00
David Greenspan
da46549d14 accounts-ui: give type to all input fields 2012-10-10 00:19:25 -07:00
Nick Martin
2b18b89dad Merge branch 'auth' into devel 2012-10-10 00:02:54 -07:00
Avital Oliver
0f50a1ea9b Minor weibo configuration instructions improvement 2012-10-09 23:52:34 -07:00
David Glasser
e38cefbc04 Crash on startup if index creation fails (eg, if you have duplicate data in the
DB).
2012-10-09 23:26:27 -07:00
David Glasser
9b9d07d773 Create indices on all Meteor.users fields on which we do queries.
Rely solely on indices (with some icky error parsing) to generate "user/email
already exists" errors.

Not yet making the ensureIndex API public. Not indexing the tiny
loginServiceConfiguration collection. Indexing tinytest_results.
2012-10-09 23:12:16 -07:00
David Glasser
bbf9ae0c2b Fix Mongo write error handling.
Previously, if we did a Mongo write inside a method and Mongo returned an error
(eg, duplicate key in a unique index), the write fence would never fire and the
client would never quiesce. Now we make sure to fire the write fence (and mark
the collection dirty) even on error.
2012-10-09 23:12:16 -07:00
Nick Martin
5fd3c7ce71 Re-rename 'confirm' to 'verify'. 2012-10-09 22:44:25 -07:00
Nick Martin
5c8c22c9c7 Accounts.createUser on server no longer sends enrollment email. sendXXXEmail functions now have email as an optional argument. 2012-10-09 22:44:25 -07:00
Nick Martin
1311f9d8cc Missing var. 2012-10-09 22:44:24 -07:00
Avital Oliver
002768d72a accounts-ui: Validate username/email on login
This resolves a strange error you get if you sign in with all fields empty
2012-10-09 22:28:31 -07:00
Avital Oliver
a6e71dcde6 accounts-github: better dimensions for popup 2012-10-09 22:14:03 -07:00
Avital Oliver
7757cc0659 accounts-ui: dropdown opens by default to right, unless wrapped in an element with class 2012-10-09 21:52:52 -07:00
Avital Oliver
168be9f059 accounts-ui: default to EMAIL_ONLY 2012-10-09 21:14:47 -07:00
Avital Oliver
b5aa098c89 Minor fix to an older commit 2012-10-09 20:25:29 -07:00
Avital Oliver
4cc5be00c0 Add null support for options in Meteor.loginWithTwitter and Meteor.loginWithWeibo 2012-10-09 20:23:39 -07:00
Avital Oliver
c5044e57cd Allow multiple calls to Accounts.config without overriding settings 2012-10-09 20:18:19 -07:00
Avital Oliver
cbf06a5679 Rename forbidSignups -> forbidClientAccountCreation 2012-10-09 20:13:59 -07:00
Avital Oliver
df622401b4 accounts-ui: redo Accounts.ui.config 2012-10-09 20:11:15 -07:00
Avital Oliver
7d368a3f6e accounts-ui: configure scope for external services 2012-10-09 20:04:19 -07:00
Nick Martin
accd41bddf Remove Accounts.{facebook,github,google}.config. Replace with options in loginWithFacebook. 2012-10-09 20:04:19 -07:00
Avital Oliver
14f975ea30 accounts: introduce accounts-ui configuration, simplify accounts configuration
We no longer pass the requireEmail and requireUserame options in
Accounts.config (which means we also don't validate new users when
they are created -- that should probably be done with a server
analogue of .allow())

Instead, Accounts.ui.config can be passed a newUserWithPasswordHas
option with four distinct UI configurations.
2012-10-09 20:02:52 -07:00
David Glasser
dd77a26acc Rename Accounts.configuration to Accounts.loginServiceConfiguration.
Matches other references to it in the code, and is harder to confuse with
Accounts.config.
2012-10-09 19:18:02 -07:00
David Glasser
78779f3ca4 Don't allow clients to set fields in the createUser method that they can't later
modify with the default Meteor.users update allow rule.

This does mean that it's difficult for trusted server code calling
Accounts.createUser, even with a custom onCreateUser hook, to set values on the
new user that can't also be set by arbitrary clients. For now, server code
needing to do this can just set it with a post-create update; later we might add
another parameter to onCreateUser.
2012-10-09 18:52:15 -07:00
David Greenspan
a61b24bd1c auth dialog CSS includes reset, more resilient 2012-10-09 17:23:51 -07:00
David Glasser
ff359a73c6 Make sure that the client doesn't get confused by an unsub followed immediately
by an identical sub.

Previously, it would fail to subscribe. This confused the meteor.currentUser
subscription in accounts_client.js. Reproduction:

  - Create user X with email (which sends a confirmation email)
  - Log out.
  - Log in as User Y in tab 1.
  - Follow the confirmation link in tab 2. This leaves you logged in
    as User Y.
  - Tab 1's localstorage poller notices that there's a new token and logs in
    with it.
  - After a successful login, Accounts._makeClientLoggedIn unsubs from
    meteor.currentUser and immediately resubs. It thinks there's already an
    existing sub, so it doesn't send the sub message and does immediately call
    the ready callback (which sets userLoaded() to true).
  - The unsub gets sent and the object in Meteor.users() gets depopulated.

Now Meteor.userLoaded() is true but Meteor.user() is empty.
2012-10-09 17:02:01 -07:00
David Greenspan
205a491b5d use CSS star hack 2012-10-09 16:26:10 -07:00
Nick Martin
fbdf164251 Rename email 'validation' to 'confirmation'. 2012-10-09 16:12:45 -07:00
David Greenspan
649b4f5154 give login-buttons DIV display: inline-block 2012-10-09 16:05:56 -07:00
David Greenspan
cd55add975 dialog drop-shadow tweaks 2012-10-09 16:05:12 -07:00
David Glasser
9e09d64831 Prefix all accounts-ui templates other than loginButtons with an underscore.
In the future we may support use of some of the sub-templates directly (eg, we
might expose a "sign in" template and a "create user" template, and keep the
events and links for switching between them on the outer loginButtons) but we
don't yet. This change leaves us open to change the internal details later.
2012-10-09 12:00:25 -07:00
David Glasser
dffed84155 Make Meteor.user() reactive on user-loaded state. Fix #380. 2012-10-09 11:18:03 -07:00
Lloyd Brookes
ae46f89bc2 replaced 'currentInvocation.userId()' with 'currentInvocation.userId' 2012-10-09 15:41:17 +01:00
Avital Oliver
38fb1dfd01 accounts-ui improvements
- additional class on the element with class "login-link-and-dropdown-list"
  with information about which of the three password flows we are in
- a wrapper element around each label/input pair in the password forms
- links to go back to the sign up flow from create account or forgot password
2012-10-08 23:39:48 -07:00
Avital Oliver
200089e1b6 accounts-ui: apply same fonts to dialogs 2012-10-08 23:30:14 -07:00