key_secretkey_is_set Subroutine

Purpose

Determines whether a key is set for the effective UID of the calling process.

Library

Network Services Library (libnsl.a)

Syntax

#include <rpc/rpc.h>
int key_secretkey_is_set (void)

Description

The key_secretkey_is_set subroutine belongs to the secure remote procedure call (RPC) category. The subroutine is an interface subroutine to the keyserver daemon. The keylogin command fetches the key for the effective UID of the calling process and stores the key in the keyserv daemon. This subroutine is thus used to determine whether the keyserv daemon contains the key for the effective UID of the calling process.

Return Values

Item Description
1 The key is stored in the keyserver daemon.
0 The key is not stored in the keyserver daemon.

Examples

#include <rpc/rpc.h>
int main()
{
  if (key_secretkey_is_set() != 1) {
  fprintf(stderr,"key_secretkey_is_set() failed");
  exit(1);
  }

  return 0;
}