Virtual Method
CamelSessionget_password
Declaration [src]
gchar*
get_password (
CamelSession* session,
CamelService* service,
const gchar* prompt,
const gchar* item,
guint32 flags,
GError** error
)
Description [src]
This function is used by a CamelService to ask the application and
the user for a password or other authentication data.
service and item together uniquely identify the piece of data the
caller is concerned with.
prompt is a question to ask the user (if the application doesn’t
already have the answer cached). If CAMEL_SESSION_PASSWORD_SECRET
is set, the user’s input will not be echoed back.
If CAMEL_SESSION_PASSWORD_STATIC is set, it means the password returned
will be stored statically by the caller automatically, for the current session.
The authenticator should set error to G_IO_ERROR_CANCELLED if
the user did not provide the information. The caller must g_free()
the information returned when it is done with it.
Parameters
service-
Type:
CamelServiceThe
CamelServicethis query is being made by.The data is owned by the caller of the method. prompt-
Type:
const gchar*Prompt to provide to user.
The data is owned by the caller of the method. The value is a NUL terminated UTF-8 string. item-
Type:
const gchar*An identifier, unique within this service, for the information.
The data is owned by the caller of the method. The value is a NUL terminated UTF-8 string. flags-
Type:
guint32CAMEL_SESSION_PASSWORD_REPROMPT, the prompt should force a repromptCAMEL_SESSION_PASSWORD_SECRET, whether the password is secretCAMEL_SESSION_PASSWORD_STATIC, the password is remembered externally. error-
Type:
GError **The return location for a recoverable error.
The argument can be NULL.If the return location is not NULL, then you must initialize it to aNULLGError*.The argument will be left initialized to NULLby the virtual function if there are no errors.In case of error, the argument will be set to a newly allocated GError; the caller will take ownership of the data, and be responsible for freeing it.