---
title: WWDC2001 Session 310
framework: wwdc
role: article
path: wwdc/wwdc2001-310
---

# WWDC2001 Session 310

## Transcript

Kind: captions Language: en okay well I'm here to talk talk today about the Apple share client in Mac OS 10 and the AFP 3.0 protocol I want to go over what we've done with AFP 3.0 in Mac Mac OS 10 talk about the AFP client implementation and then go over the user authentication module SDK it allows you to write plug-in authentication for Apple share on 10 like to start with a bit of overview of the history and the goals of AFP 3.0 what we've got that's new and go over what we've we've actually accomplished there FP 3.0 is similar to HFS+ in the same way that AFP 2.2 and the earlier versions were similar to HFS so some of the same limitations and things so we we did a FP 300 in order to provide support for HFS+ provide longer names improve the improve the unix-like feel of it of the whole thing and give you support for greater than to gig files long filenames and to improve our localization or multilingual stuff FP 300 is just like all the other AFP versions is a superset of the previous ones we did have four remove protoss support we've added long long Unicode names up to 255 Unicode characters 64-bit file sizes that's somewhere way up in the terabytes instead of this 2gig limit we've got today we've added unix permissions we've added some optimizations to the protocol for long attentions to support directory services much like Kerberos realms and things like that directory service nodes from the dur services folks support for automatically reconnecting if a connection gets broken and we now do things in GMT rather than in seconds since the seconds since the epoch let's say then the basic new data type that we've added is an AFP name it take it's in the get folder of harm's calls and things it's a new path type so it's a one byte path type for bytes of an encoding hint which enables the finder and carbon to display the file name or what have you correctly and two bytes of length and then up to 768 so hundred sixty-five bytes of utf-8 data the things that we've not finished in Mac OS 10 the first at least in the first release is we do not have reconnect support we do not have long attention support and we haven't completely hooked up with directory services to get our full directory service support the AFP version string that we're advertising for AFP 3.0 is AFP x o3 it'll be a stumped the experts question next year so I'll be ready and these this is the list of the calls that we've added we've got the the first three they're the bite range lock read and write or all things added to handle the large the larger file sizes since we've got signed offsets and things like that in there so we had to create some new new calls for that they get off methods and the log and extended are to support directory services allows you to query a directory node for the off of the authorization types that it supports the log and extend it allows you to specify the directory node you're logging into it also allows you to use utf-8 usernames and we use an answer that matter gets sessiontoken and disconnect old session are used by the auto the reconnect code when the Apple share client logs in initially if you're going to be supporting reconnect and have set an appropriate bit they'll ask for a session token which is a way to uniquely identify that specific session from the server and then if that connection breaks and the Apple share client is wishes to attempt to reconnect it will reoffend Kate and then it will send the FP disconnect old session request and handing that token that it got back from the FP get session token call and that will tell the server to release all of the locks all of the files and things that were held by the old held by the old session that is note that is no longer there and that allows hopefully for the client to seamlessly rebuild the resources and things that were they were used by the old session that that had gotten disconnected we've changed a few calls pretty much adding new bitmaps and things like that server info call we've added flag bits to say it supports reconnect and supports the dur services stuff added directory names listed in there get server parms or using utf-8 volume names but they still have the single byte length so what you get is just the encoding change map ID and map name map between user IDs and utf-8 names now as well as just standard pascal names map name is the same thing of the other way get Felder parms also at has it's not on the list here but it's got some bitmap changes as well to support longer file sizes going on going on to the Apple sure client in Mac os10 the basic goal of the project was to provide the same functionalities the Mac OS 9 client and to capitalize on what I promised last year is to have minimal changes in the API is that that you would program to it and you know we've done pretty good the the experience of mounting of volume in Mac OS 10 is a little bit different you've got a lot more ways to mount volumes there's from the finder through the go to server thing you can use the classic chooser aliases work but the login window can also be set up to mount a volume for you you can mount things through the keychain and the auto matter in Mac OS 10 will mount volumes silently for it can be can be set up to mount volume silently for you as you open went open windows and access files and stuff and we've added a lot of international support using the Mac OS 10 internationalization tools in terms of what you see is a developer macca the the Apple share client fits into many layers in the in the 10 world and we've can we have three api's that we're working with at the moment in let's see as you can see we've got some things which live and can be called from carbon as the finder there there's a high level Apple shared client framework there's a core framework that gets called by command-line tools the automounter and things like that then there are some things in kernel space a plugin file system and a socket or the socket interface the user authentication methods sort of straddle the carbon non-carbon line because have a carbon portion which can put up a chai and a non carbon portion for those times when you're not allowed to put up a chai a shared volume enumerator API which was used by nav services in the network browser on Mac OS 9 has got some more calls that allow you to do more things in a more in a more unhc fashion I suppose you create shared volume enumerator from address takes a note e takes the the struct sock adder to to do things rather than a server name at his own mount shared volume on a mount on MP and mounts of volume on a specific point and the change password' call is one that we add it in here all these things need carbon because they can put up a chai if if need mean the other api that's currently available is AFP URLs and you know you you've seen them if you looked at connect two sometimes and they're very similar to ftp urls these urls will allow you to use user name pad username and password to things and in the example here I've got a user name of Leland password of foo at a specific server and a specific volume name you can also all actually going back here forget you can also specify an appletalk one although that's not very useful right now but you've been do it and that's that's pretty much the format same stuff you can specify user authentication method names and there by inserting the auth equals you am name construct into them the example there is it legible for you folks okay is the way to specify guest login and Apple share so that's usually with no user authentication you am the API is pretty simple a way to create one you know if you hand it the fields and it'll spit out a URL weighted way to get rid of one a way to tell if what if the string that you're passing it is the you am a way to parse out the various bits and pieces and a way to mount that URL on a specific on a specific amount point the other API which we will have as a beta SDK as well it's supposed to be up on the website today but it looks like it'll be next week is the user authentication module API I've got a few changes from Mac OS 9 but not many its package packages that packaged as bundles still has the same entry point as the old Mac OS 9 same callbacks and I'll go over what you need to do to port au am from a class 9 and show you an example of doing a port the UAMS on Mac OS 10 our bundles of type you AMX they live in library file systems Apple show authentication they're loaded with the standard CF bundle calls there's nothing really special about them they're not CF plugins I didn't need something that that heavyweight and it contains sub bundles which one of which is the high level one one over to the low level one we need the low level bundle the non-carbon bundle because these things can be loaded without a user context such as by automounter it time or other things like that places where you can't go to the Windows server and put up human interface the biggest API level changes are your hand a destruct sock a tour instead of an OT address we've added a few fields to pass to the UAM the utf-8 username and the user do the directory names session reference numbers now along instead of a short and we're not using the async callbacks because you can do multi-threaded access to this stuff a bundle our you am bundle is you know a is a bundle and it's and you can have inside of it a high level bundle and a low level bundle and those things are pointed to by the info.plist most of the things in the info.plist are from or from the you AMG resource on mac os9 we've got keys for the protocol name the maximum password length the and some and and a dictionary which tells the Apple share client where the high level and low level sub bundles are with an identifier on a path and it also gives you the name of the entry point so you can change that if you want there's also a localized string in there which is the user for user visible name that will appear in the hsm time in the future the entry point is the same entry point as we had on Mac OS 9 takes takes a um argh structure it's very very much a parameter block interface these selectors are just the same as Mac OS 9 the open when the UAM is loaded to login when you request them to log in a close and then selectors for optionally putting up dialogues for the password for the volume selection for changing passwords and selectors for handling you am handling persistent data storage callbacks are the same as in Mac OS 9 call back to get additional information about the client call back to open the session to send the request to close the session all of these things allow you to make e to write a UAM that has no idea what network it's going to because all of that's abstracted out into the in the callbacks in order to port a mac os9 you I am all you have to do is compile your main code and resources into the high-level bundle set up the entry points in the outer by set up the info.plist in the outer bundle and then basically install it further information about this stuff can be found up on the website there's stuff in the developer.apple.com you know the mac OS networking page there's got information on your services and on a FB 3.0 and on the Apple share client API is bid SDK ought to be up sometime next week and if not give me a give me an email DeRosa's Doc's are back up on the site as I said and the other stuff just take a look at the Apple share client dot framework and Apple share client Cortot framework stuff both of these both of the other sessions that might be interesting have already occurred so you'll have to catch them in DVD and further stuff can be directed towards Tom wire you
