Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ sec_rgy_unix_getpwnam(3sec) — DCE 3.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

sec_rgy_unix_getpwnam(3sec)  —  Subroutines

NAME

sec_rgy_unix_getpwnam — Returns a UNIX style passwd entry for account matching the specified name

Synopsis

void sec_rgy_unix_getpwnam (
sec_rgy_handle_t context,
sec_rgy_name_t name,
unsigned32 name_len,
sec_rgy_cursor_t ∗item_cursor,
sec_rgy_unix_passwd_t ∗passwd_entry,
error_status_t ∗status);

Parameters

Input

contextAn opaque handle bound to a registry server.  Use sec_rgy_site_open to acquire a bound handle. 

nameA character string (of type sec_rgy_name_t) containing the name of the person, group, or organization whose name entry is desired. 

name_lenA 32-bit integer representing the length of the name in characters. 

Input/Output

item_cursor
An opaque pointer indicating a specific PGO item entry in the registry database.  The sec_rgy_unix_getpwnam routine returns the PGO item indicated by item_cursor, and advances the cursor to point to the next item in the database.  When the end of the list of entries is reached, the routine returns sec_rgy_no_more_entries.  Use sec_rgy_cursor_reset to refresh the cursor. 

Output

passwd_entry
A UNIX style passwd structure returned with information about the account matching name. 

statusOn successful completion, the routine returns error_status_ok.  Otherwise, it returns an error. 

Description

The sec_rgy_unix_getpwnam routine returns the next UNIX passwd structure that matches the input name.  The structure is in the following form:

typedef struct {
       sec_rgy_unix_login_name_t name;
       sec_rgy_unix_passwd_buf_t passwd;
       signed32 uid;
       signed32 gid;
       signed32 oid;
       sec_rgy_unix_gecos_t gecos;
       sec_rgy_pname_t homedir;
       sec_rgy_pname_t shell;
   }               sec_rgy_unix_passwd_t;

The structure includes the following:

   •The account’s login name. 

   •The account’s password. 

   •The account’s UNIX ID. 

   •The UNIX ID of group and organization associated with the account. 

   •The account’s GECOS information. 

   •The account’s home directory. 

   •The account’s login shell

This call is provided in source code form. 

Files

/usr/include/dce/rgynbase.idl
The idl file from which rgynbase.h was derived. 

Errors

The following describes a partial list of errors that might be returned.  Refer to the OSF DCE Problem Determination Guide for complete descriptions of all error messages. 

sec_rgy bad_data
The name supplied as input was too long.

error_status_ok
The call was successful.

sec_rgy_no_more_entries
The end of the list of entries has been reached.

Related Information

Functions: sec_intro(3sec). 

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026