PageRenderTime 24ms CodeModel.GetById 14ms app.highlight 5ms RepoModel.GetById 1ms app.codeStats 1ms

/indra/newview/llloginhandler.h

https://bitbucket.org/lindenlab/viewer-beta/
C++ Header | 57 lines | 17 code | 9 blank | 31 comment | 0 complexity | d18b3b747ff553bb780c010693a97c16 MD5 | raw file
 1/** 
 2 * @file llloginhandler.h
 3 * @brief Handles filling in the login panel information from a SLURL
 4 * such as secondlife:///app/login?first=Bob&last=Dobbs
 5 *
 6 * $LicenseInfo:firstyear=2008&license=viewerlgpl$
 7 * Second Life Viewer Source Code
 8 * Copyright (C) 2010, Linden Research, Inc.
 9 * 
10 * This library is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU Lesser General Public
12 * License as published by the Free Software Foundation;
13 * version 2.1 of the License only.
14 * 
15 * This library is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
18 * Lesser General Public License for more details.
19 * 
20 * You should have received a copy of the GNU Lesser General Public
21 * License along with this library; if not, write to the Free Software
22 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
23 * 
24 * Linden Research, Inc., 945 Battery Street, San Francisco, CA  94111  USA
25 * $/LicenseInfo$
26 */
27#ifndef LLLOGINHANDLER_H
28#define LLLOGINHANDLER_H
29
30#include "llcommandhandler.h"
31#include "llsecapi.h"
32
33class LLLoginHandler : public LLCommandHandler
34{
35 public:
36	// allow from external browsers
37	LLLoginHandler() : LLCommandHandler("login", UNTRUSTED_ALLOW) { }
38	/*virtual*/ bool handle(const LLSD& tokens, const LLSD& query_map, LLMediaCtrl* web);
39
40	// Fill in our internal fields from a SLURL like
41	// secondlife:///app/login?first=Bob&last=Dobbs
42	bool parseDirectLogin(std::string url);
43
44	// Web-based login unsupported
45	//LLUUID getWebLoginKey() const { return mWebLoginKey; }
46
47	LLPointer<LLCredential> loadSavedUserLoginInfo();  
48	LLPointer<LLCredential> initializeLoginInfo();
49
50private:
51	void parse(const LLSD& queryMap);
52
53};
54
55extern LLLoginHandler gLoginHandler;
56
57#endif