eudora-mac/Include/networksetuplibrary.h

1 line
6.2 KiB
C
Raw Permalink Normal View History

2018-05-23 09:59:15 +00:00
/* Copyright (c) 2017, Computer History Museum All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted (subject to the limitations in the disclaimer below) provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of Computer History Museum nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE GRANTED BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #ifndef NETWORKSETUPLIBRARY_H #define NETWORKSETUPLIBRARY_H /* Copyright (c) 1999 by Qualcomm, Inc. */ /************************************************************************ * Functions to use Apple's Network Setup Library included with Mac OS * 8.5 and beyond. The library is used to determine the TCP/IP connection * method, as well as read in ARA PPP dialing preferences. ************************************************************************/ #if TARGET_CPU_PPC // // define USE_NETWORK_SETUP to compile in Network Setup Library support. // // The Network Setup Library is included with MacOS 8.5 and beyond. Since // 8.5 requires a PPC processor, there's no sense in including this in the // 68K version // // Further, Network Setup is not carbonized. There's no need to include it // in the Carbon build of Eudora, either. // #define USE_NETWORK_SETUP #endif //TARGET_CPU_PPC #define CONFIG_RESOURCE 'ccfg' // indicates which configuration is currently selected #define CONFIG_RESOURCE_ID 1 #define LOADED_RESOURCE 'unld' // == 3 when TCP/IP is not loaded #define PORT_RESOURCE 'port' // resource where the individual configs are stored #define IITF_RESOURCE 'iitf' // current TCP info resouce #define PPP_NAME "\pPPP" // 'port' resource contains this when PPP is selected #define TCP_PREF_FILE_TYPE 'pref' #define TCP_PREF_FILE_CREATOR 'ztcp' #define PPP_PREF_FILE_TYPE 'lzcn' #define PPP_PREF_FILE_CREATOR 'rmot' #define DIAL_RESOURCE 'cdia' #define DIAL_RESOURCE_ID 128 #define NS_LIBRARY_TYPE 'shlb' #define NS_LIBRARY_CREATOR 'ntex' struct TypeAndClassParam { OSType fType; OSType fClass; Boolean found; CfgEntityRef *currentEntity; }; typedef struct TypeAndClassParam TypeAndClassParam; struct TCPiitfPref { UInt8 fActive; InetHost fIPAddress; InetHost fSubnetMask; Str255 fAppleTalkZone; UInt8 fPath[36]; // Pascal string UInt8 fModuleName[31]; // Pascal string UInt32 fFramingFlags; }; typedef struct TCPiitfPref TCPiitfPref; typedef UInt8 TCPv4ConfigMethod; enum { kTCPv4ManualConfig = 0, kTCPv4RARPConfig = 1, kTCPv4BOOTPConfig = 2, kTCPv4DHCPConfig = 3, kTCPv4MacIPConfig = 4 }; typedef UInt16 TCPv4UnloadAttr; enum { kTCPv4ActiveLoadedOnDemand = 1, kTCPv4ActiveAlwaysLoaded = 2, kTCPv4Inactive = 3 }; struct NSHTCPv4ConfigurationDigest { OSType fProtocol; // always kOTTCPv4NetworkConnection for NSHTCPv4ConfigurationDigest Str255 fCon