﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
15268	User.objects.get_or_create has inconsistent behavior	w004dal	nobody	"When I use User.objects.get_or_create(username=u, password=p) it should be syntactic sugar to:

try:
  u = User.objects.get(username=u)
  assert u.password == p
  return u
except User.DoesNotExist:
  return User.objects.create_user(username=u, password=p, email=foo)

Additionally:

User.objects.get_or_create(username=u, password=p) raises a database inconsistency error if 'u' exists with encrypted password 'p'.

If 'u' does not exist in the database, the password is stored in clear text.

This issue seems to coincide with an authentication issue in the administration console. When an admin tries to change the user's password, it is stored in clear text."		closed	contrib.auth	1.2		invalid		w004dal@… w004dal	Unreviewed	0	0	0	0	0	0
