Norbert Gruener > AFS-2.4.0 > AFS::KTC_EKEY

Download:
AFS-2.4.0.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
Report a bug
Module Version: 2.4.688   Source   Latest Release: AFS-2.6.1

NAME ^

AFS::KTC_EKEY - Class to handle the AFS structure ktc_encryptionkey

SYNOPSIS ^

  use AFS::KTC_EKEY;
  use AFS::Cell qw(localcell);

  my $key = AFS::KTC_EKEY->ReadPassword('Password:');
  print 'KEY = ', $key->string, " \n";

  my $string = AFS::KTC_EKEY->UserReadPassword('Password:');
  $key = AFS::KTC_EKEY->StringToKey($string, localcell);
  print 'KEY = ', $key->string, " \n";

  $key = AFS::KTC_EKEY->des_string_to_key('aaa');
  print 'KEY = ', $key->string, " \n";

  undef $key;

NOTE: The following lines are 'version 1' style: all names are exported by default. This style is deprecated !!!

  use AFS;              # import all AFS names
  use AFS @AFS::KA;     # import just the ka names
  use AFS @AFS::KTC;    # import just the ktc names

DESCRIPTION ^

This class provides methods to handle the AFS structure ktc_encryptionkey. This structure represents an encryption key which is used in the Kernel Token Cache (KTC). The KTC is part of the Cache Manager. It is used to create ktc_encryptionkey instances.

COMPATIBILITY ^

In version 2, some of the methods have been renamed. All old names and interfaces from version 1 are still available for compatibility, but are deprecated. These cases have been marked in the documentation.

You must not intermix names or interfaces from version 1 with names or interfaces from version 2. You either stick with version 1 or version 2.

     Version 1             Version 2
     -----------------------------------------------------
     ka_ReadPassword       AFS::KTC_EKEY->ReadPassword
     ka_UserReadPassword   AFS::KTC_EKEY->UserReadPassword
     ka_StringToKey        AFS::KTC_EKEY->StringToKey
     ka_des_string_to_key  AFS::KTC_EKEY->des_string_to_key

METHODS ^

CONSTRUCTOR
 
$key = AFS::KTC_EKEY->des_string_to_key(STRING);

The STRING string is converted to a DES encryption key and this key is returned as an AFS::KTC_EKEY object. It calls the AFS system library function 'des_string_to_key'.

NOTE: this form is deprecated !!!

 $key = ka_des_string_to_key(STRING);
$key = AFS::KTC_EKEY->ReadPassword(PROMPT [, VERIFY [, CELL]]);

Prints out a PROMPT and reads a string from the terminal, turning off echoing. If VERIFY (default 0) is set to 1 it requests that the string be entered again and the two strings are compared. CELL defaults to NULL. The string is then converted to a DES encryption key and the encryption key is returned as an AFS::KTC_EKEY object. It calls the AFS system library function 'ka_ReadPassword'.

NOTE: this form is deprecated !!!

 $key = ka_ReadPassword(PROMPT, VERIFY, CELL);
$key = AFS::KTC_EKEY->StringToKey(PASSWD, CELL);

The PASSWD string is converted to a DES encryption key and this key is returned as an AFS::KTC_EKEY object. It calls the AFS system library function 'ka_StringToKey'.

NOTE: this form is deprecated !!!

 $key = ka_StringToKey(PASSWD, CELL);
CLASS METHODS
 
$string = AFS::KTC_EKEY->UserReadPassword(PROMPT [, REASON]);

Prints out a PROMPT and reads a string from the terminal, turning off echoing. This string is returned. On error the error message is returned in REASON. It calls the AFS system library function 'ka_UserReadPassword'.

NOTE: this form is deprecated !!!

 $string = ka_UserReadPassword(PROMPT, REASON);
ATTRIBUTES ACCESS
 
$key->string;

Returns the whole encryption key as a string.

CURRENT AUTHOR ^

Norbert E. Gruener  <nog@MPA-Garching.MPG.de>. 

AUTHOR EMERITUS ^

Roland Schemers  <schemers@slapshot.stanford.edu>. 

COPYRIGHT AND DISCLAIMER ^

 © 2001-2005 Norbert E. Gruener <nog@MPA-Garching.MPG.de>.
 All rights reserved.

 © 1994 Board of Trustees, Leland Stanford Jr. University.
 All rights reserved.

 Most of the explanations in this document are taken from the original
 AFS documentation.

 AFS-3 Programmer's Reference:
 Authentication Server Interface
 Edward R. Zayas
 © 1991 Transarc Corporation.
 All rights reserved.

 IBM AFS Administration Reference
 © IBM Corporation 2000.
 All rights reserved.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

The original module is covered by the following copyright:

Copyright (c) 1994 Board of Trustees, Leland Stanford Jr. University

Redistribution and use in source and binary forms are permitted provided that the above copyright notice and this paragraph are duplicated in all such forms and that any documentation, advertising materials, and other materials related to such distribution and use acknowledge that the software was developed by Stanford University. The name of the University may not be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.

DOCUMENT VERSION ^

Revision $Rev: 687 $