1/*++ 2/* NAME 3/* canon_addr 3 4/* SUMMARY 5/* simple address canonicalization 6/* SYNOPSIS 7/* #include <canon_addr.h> 8/* 9/* VSTRING *canon_addr_external(result, address) 10/* VSTRING *result; 11/* const char *address; 12/* 13/* VSTRING *canon_addr_internal(result, address) 14/* VSTRING *result; 15/* const char *address; 16/* DESCRIPTION 17/* This module provides a simple interface to the address 18/* canonicalization service that is provided by the address 19/* rewriting service. 20/* 21/* canon_addr_external() transforms an address in external (i.e. 22/* quoted) RFC822 form to a fully-qualified address (user@domain). 23/* 24/* canon_addr_internal() transforms an address in internal (i.e. 25/* unquoted) RFC822 form to a fully-qualified address (user@domain). 26/* STANDARDS 27/* RFC 822 (ARPA Internet Text Messages). 28/* SEE ALSO 29/* rewrite_clnt(3) address rewriting client interface 30/* LICENSE 31/* .ad 32/* .fi 33/* The Secure Mailer license must be distributed with this software. 34/* AUTHOR(S) 35/* Wietse Venema 36/* IBM T.J. Watson Research 37/* P.O. Box 704 38/* Yorktown Heights, NY 10598, USA 39/*--*/ 40 41/* System library. */ 42 43#include <sys_defs.h> 44 45/* Utility library. */ 46 47#include <vstring.h> 48#include <mymalloc.h> 49 50/* Global library. */ 51 52#include "rewrite_clnt.h" 53#include "canon_addr.h" 54 55/* canon_addr_external - make address fully qualified, external form */ 56 57VSTRING *canon_addr_external(VSTRING *result, const char *addr) 58{ 59 return (rewrite_clnt(REWRITE_CANON, addr, result)); 60} 61 62/* canon_addr_internal - make address fully qualified, internal form */ 63 64VSTRING *canon_addr_internal(VSTRING *result, const char *addr) 65{ 66 return (rewrite_clnt_internal(REWRITE_CANON, addr, result)); 67} 68