atomicity in electronic commerce

22
Atomicity in Electronic Commerce J. D. Tygar January 1996 CMU-CS-96-112 School of Computer Science Carnegie Mellon University Pittsburgh, PA 15213 This research was partially supported by the Department of Defense (ARPA contracts F33615-C-1465, F19628- 93-C-0913), IBM, the Information Networking Institute, Motorola, National Science Foundation (under Presidential Young Investigator Grant CCR-8858087and Cooperative Agreement No. IRI-9411299), TRW, the US Postal Service, and Visa International. Appendix A is drawn from a report that was additionally supported by ARPA contract F19628-95-C-0018. The views and conclusions contained in this document are those of the authors and should not be interpreted as representing the official policies, either expressed or implied, of the U.S. Government or any part thereof, the Advanced Research Projects Agency, the National Science Foundation, or any other research sponsor. Carnegie Mellon University Computer Science technical report CMU-CS-96-112

Upload: others

Post on 12-Sep-2021

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Atomicity in Electronic Commerce
Page 2: Atomicity in Electronic Commerce

(including both Internet and private services such asCompuserve, America On Line, Prodigy, etc.)

For yet another measure, visit the WWW site

http://www.yahoo.com

, and see the tens ofthousands of electronic storefronts available.

There are many efforts to build electroniccommerce systems. Here are some representativeorganizations making major electronic commerceefforts (by no means comprehensive):

• CMU (NetBill)

• Cybercash

• Digicash

• DEC (Millicent)

• First Virtual

• FSTC (E-check)

• IBM (iKP)

• Mastercard (SEPP)

• Microsoft and Visa (STT)

• Open Market

• Netscape (SSL)

• US Postal Service

(This list is very fluid. For example, at the time thatthis paper is being written [December 1995] there arediscussions about developing a merged protocol fromSTT and SEPP; statements that I make about thesystems being developed today are likely to becomeoutdated as the systems evolve. Any bibliographiclisting of references is will rapidly become dated, but[30] is a nice summary of most of this work.)

Concepts from the PODC community are usedheavily in electronic commerce. Concepts that need tobe mastered to properly handle electronic commerceinclude:

• atomic transactions

• cryptographically secure protocols

• secure computation

• safe voting

• high reliability

This paper is concerned with the first property,atomic transactions. I will discuss a variety of types ofelectronic commerce. After giving a discussion onatomicity, I will consider the atomic properties ofseveral electronic commerce protocols. I will then

discuss the development of two highly atomic protocols:the NetBill protocol and cryptographic postage indicia.

Because this paper is based on an expositorylecture, my tone throughout is informal. I am afraid thatyou will not find formal definitions of types ofelectronic commerce atomicity below; indeed, Iconsider the formulation of those formal definitions anopen problem (see Section 6). For those who crave moredetails presented in a more formal manner, Section 8(Appendix A) contains a technical exposition of theNetBill protocol; [10] is the best reference for a formalexposition of cryptographic postage indicia.

Note that throughout the text I use male pronouns torefer to merchants and female pronouns to refer tocustomers.

2. Electronic Commerce Properties

How can we characterize electronic commerceprotocols. There are a variety of properties that we candescribe; this paper focuses on atomicity but, becauseproperties often interact in a variety of non-trivial ways,it important to review several properties.

2.1. Atomicity

Atomicity allows us to logically link multiple operationsso that either all of them are executed or none of themare. For example, in transaction processing, one mayexecute a sequence of code as follows:

<begin-transaction>state-changing operation 1;state-changing operation 2;. . .state-changing operation

n

;<end-transaction>

When this block of operations is executed, all of thestate-changing operations from 1 to

n,

inclusive will beexecuted or the state of the system will be as if none ofthem had been executed.

Why would atomicity every fail to occur? Well, ifthe transactions are being executed in a distributedenvironment on multiple processors, then one of theprocessors executing a state-changing operation orcommunication between two processors executing state-changing operations may fail. In that case, it may beimpossible to complete the entire block of state-changing operations. In these cases, it is necessary toroll-back the processors to a state consistent with thetransaction have never been begun in the first place.

Atomic transactions form the cornerstone ofmodern transaction processing theory. (Nancy Lynch

Page 3: Atomicity in Electronic Commerce

and her fellow researchers have written an encyclopedicbook about atomic transactions [13]; a tremendousresource for those implementing atomic transactionprocessing systems is the standard textbook [9]; for athorough review of powerful roll-back methods in thecontext of computer security and electronic commerce,see [25], [26], and [27].) The “A” in

ACID Transactions

stands for “atomic”, no non-atomic distributedtransaction system would ever be tolerated by customersof data processing.

However, as we shall see below, the story is quitedifferent in the world of electronic commerce protocols.Most of the proposed protocols are not atomic. Forexample, if I interrupt a communication between amerchant and a customer, I can often throw anelectronic commerce protocol, into an ambiguous state.Money or electronic cash tokens may be copied (withdifferent parties each believing that it has the true, validcopy) or destroyed.

I define three levels of atomicity to protectelectronic commerce protocols.

2.1.1. Money Atomicity

Money atomic protocols effect the transfer of fundsfrom one party to another without the possibility of thecreation or destruction of money.

For example, a cash transaction is usually moneyatomic (unless the possibility exists of counterfeiting ordestruction of money).

This is a basic level of atomicity that eachelectronic commerce protocol should satisfy.

2.1.2. Goods Atomicity

Goods-atomic protocols are money atomic, and alsoeffect an exact transfer of goods for money. That is, if Ibuy a good using a goods-atomic protocol, I will receivethe good if and only if the money is transferred. Fornetwork protocols, goods atomicity is especiallyimportant for information goods. There must be nopossibility that I can pay without getting the goods, orget the goods without paying. (Anyone who has had aninterrupted file transfer while downloading informationon the Internet is aware of the importance of goodsatomicity.)

For example, a cash-on-delivery parcel delivery is agood real-world approximation to an electroniccommerce protocol. I get the parcel exactly when I havepaid the delivery agent.

Goods atomicity is an important property that eachelectronic commerce protocol intended for informationgoods should satisfy.

2.1.3. Certified Delivery

Certified delivery protocols are money atomic andgoods atomic protocols that also allow both a merchantand a customer to prove exactly which goods weredelivered. If I buy a document entitled “How to make amillion dollars fast on the Internet” and receive anelectronic copy of some unrelated or garbage material, Iwill want to complain to an authority. To rapidly resolvethe question, both the merchant and the customer willwant to be able to prove the exact contents of what wasdelivered.

For example, a certified delivery protocolcorresponds to a cash-on-delivery parcel delivery wherethe contents of the parcel is opened in front of a trustedthird-party who immediately records in an indestructibleform the exact contents of the parcel.

Certified delivery protocols are helpful forscenarios where merchants and customers may beuntrusted. Today, there is no effective way to distinguisha large trusted WWW merchant from a fly-by-nightimpressive electronic storefront that actually connects toa shop that contains a fraudulent operation.

2.2. Anonymity

Some people want to keep their purchases private. Theydo not want to have third-parties (or even merchants)know their identity. This concern may arise because thecustomer is buying a good of questionable social value(e.g., pornography); or because the customer does notwant to have his name added to a marketing or mailinglist; or for illegal reasons (e.g., to evade taxes); orsimply because the customer personally values privacy.

Although most paper money contains serialnumbers, cash transactions can often have anonymousproperties. Serial numbers are rarely traced andrecorded, and if I buy something from a merchant whodoes not know me or from a vending machine, mypurchase is often effectively anonymous.

David Chaum has been the most influentialadvocate of anonymous electronic commerce protocols.He has written a number of highly influential papers ontopics such as “anonymous digital cash”, these in turnhave inspired all electronic commerce researchers.Modern researchers have improved his protocols; arepresentative sophisticated example of the currentversion of his protocols can be found in [4].

Here is the way these protocols work:

a) a customer withdraws money from the bank,receiving a cryptographic token which can be usedas money;

Page 4: Atomicity in Electronic Commerce

b) the customer applies a cryptographic transforma-tion to the money that still allows a merchant tochecks its validity, but make it impossible to tracethe customer’s identity;

c) the customer spends the money with the merchant.(in doing so, she applies a further cryptographictransformation so that the merchant’s identity isused in the data);

d) the merchant checks to make sure that he has notreceived the token previously;

e) the merchant sends the goods to the customer;

f) at a later point, the merchant deposits his electronictokens at the bank; and

g) the bank checks the tokens for uniqueness; the iden-tities of the customers remain anonymous except inthe case when a customer had double-spent atoken—if a token was double-spent, the identity ofthe customer is revealed and the network police arenotified of attempted counterfeiting.

Now consider when a communication failurehappens around step (c). The customer has no way ofknowing if a merchant has received her token or not.The customer has two options:

• The customer can return her electronic token to thebank (or spend it on a different merchant.) If shedoes this, and the merchant actually received hertoken, then when the merchant cashes in the token,the customer’s anonymity will be revealed. Evenworse, the customer will be likely to be accused offraud.

• The customer can take no action, failing to returnher token. If she does this, and the merchant neverreceived her token, then she is in danger of losingher money. She will have never received the goodshe attempted to purchase, and she will be unable touse her money.

In either case, money atomicity breaks down.In many countries, most anonymous transactions

are illegal. For example, in the United States, the MoneyLaundering Act (12 USC §1829) requires that electroniccommerce systems should both

• promptly report any transaction over $3000 (this isthe figure effective January 1, 1996; prior to that,the limit was $10,000)

• store a copy of any transaction over $100.

These requirements have not been tested in courtfor digital cash systems. However, it is clear that it is

arguable that, as currently proposed, digital cashsystems may be illegal.

I also note that it is often possible to achieve alimited form of anonymity by having a proxy agentcomplete purchases for the customer. In this case, thetransaction may be easily traced to the proxy agent,which keeps private the identity of the true customer.

2.3. Security

Can we trust anyone in cyberspace? Communicationscan be easily intercepted, messages can be inserted, andthe absolute identity of other parties may be uncertain.Clearly, security will be important for any electroniccommerce protocol.

By contemporary standards, the current form ofcredit cards, which reveal a customer’s identity andcharge numbers to a merchant and to anyone who canobtain a copy of the receipt, would be unlikely to beaccepted if they were introduced newly today.

Many electronic commerce systems depend onsome ultimate, trusted authority. For example, NetBilldepends on the trustworthiness of a central server.However, even in the case where one uses a trustedserver, one can minimize the effects of the securityfailures of that server. For example, in NetBill, detailedcryptographically-unforgeable records are kept so that ifthe central server was ever corrupted, it would bepossible to unwind all corrupted actions and restore anylost money.

2.4. Transaction size

The average credit card transaction has typically beenestimated to be on the order of $50. Depending on thearrangements made with a bank, a merchant paydapproximately 30¢ plus 2% of the purchase price foreach and every transaction. For many telephone or mailorder businesses, the actual rate is closer to 50¢ plus2.25%.

If one is engaging in a transaction that is only worth10¢ or even 1¢, the standard credit card rates woulddominate the cost of the item. Thus, a number of partieshave proposed support for

microtransactions

ortransactions less than $1. (By no means is 1¢ theminimum transaction value of interest; Mark Manasse’selectronic commerce system is named Millicent [14].)

Both NetBill and cryptographic postage indicia aremotivated by the idea of supporting microtransactions.Some of the design decisions made for those systemscan only be understood by the microtransactionrequirement. However, a detailed discussion ofmicrotransactions is beyond the scope of this paper.

Page 5: Atomicity in Electronic Commerce

(For those who are curious: the key idea behindmost microtransaction protocols is to aggregate manysmall transactions charged using specially optimizedprotocols; then charge the aggregated total as a largevalue transaction. This idea is a beautiful application ofprotocol nesting. For a discussion of microtransactionsin NetBill, see [23]; for a completely different approach,see [14].)

3. Non-atomic Electronic Commerce Proto-cols

3.1. Digicash

Digicash uses an anonymous digital cash protocol. Asdiscussed in Section 2.2, digital cash protocols are notmoney atomic; indeed, in the event of communicationfailure, they can fail to be anonymous as well. Finally,digital cash protocols use several rather computationallyintensive cryptographic operations and are thus quiteexpensive. I estimate that the real cost of processing asingle digital cash transaction would be on the order of$1 per transaction; Digicash reportedly has relativelyhigh fees, suggesting that this expectation is correct.Digicash in its current form is not useful formicrotransactions.

3.2. First Virtual

First Virtual allows users to freely buy goods. FirstVirtual then uses e-mail to confirm each and everytransaction with the customer. Setting aside theacceptability of flooding a user with e-mail forpurchases in this way, this model clearly preservesmoney atomicity, although it clearly fails goodsatomicity (since the customer can buy an item withoutpaying for it.) First Virtual apparently considers goodsatomicity to be relatively unimportant. (Indeed, FirstVirtual takes a dim view of communications securityand encryption in any form; in [3], they argue thatcommunications security is “irrelevant” and theydismiss electronic commerce designers who postponedeployment of their systems to perfect strong securityguarantees.)

First Virtual’s system can easily be a target of fraudand atomicity failures. It is somewhat better than digitalcash, but inferior to other electronic commerce systems.

Ultimately, First Virtual translates each electroniccommerce transaction into a credit card transaction,making First Virtual in its current form of limited valuefor microtransactions. (First Virtual suggests usingaggregation, but they can not aggregate across differentmerchants in a single credit card transaction.)

3.3. SSL

The Secure Socket Layer (SSL) approach sets up asecure communication channel (using cryptography) totransfer a customer’s credit card number to themerchant. This approach is equivalent to reading yourcredit card number over the phone to a merchant using asecure telephone connection.

This approach offers money atomicity to the extentthat credit card transactions are money atomic.However, its security properties are less clear; forexample, since a (potentially unscrupulous) merchanthas the customer’s credit card number, he can use it tocommit fraud. (Merchant fraud is one of the mostserious problems facing the credit card industry [31].Lyndon LaRouche is a well-known example of a personwho committed merchant credit card fraud.)

Goods atomicity is not addressed by SSL.In its current form SSL is clearly of limited value

for microtransactions.

3.4. STT/SEPP/iKP

STT (Visa/Microsoft), SEPP (Mastercard), and the iKPfamily of protocols (IBM) are examples of a securecredit-card based protocols. Each of these protocols areslightly different, but they have a common structure: thecustomer digitally signs (using, for example, public keycryptography) a purchase request together with a priceand then encrypts the request in a bank’s public key.Similarly, the merchant prepares and submits a salesrequest with a price for the bank. The bank compares thepurchase and sales request — if the prices match, thebank charges the customer’s account and instructs themerchant to complete the sale.

Like SSL, this approach offers money atomicity tothe extent that credit card transactions are moneyatomic. However, the security properties of STT

et al

are superior since they prevent merchant fraud. Goods atomicity is not addressed by STT

et al

.In their current form STT

et al

are clearly of limitedvalue for microtransactions.

4. NetBill

My co-researchers and I developed NetBill to provideall three levels of atomic transactions. Here, I give abroad sketch of the NetBill format and some rougharguments of why it satisfies all three atomicityconditions: money atomicity, goods atomicity, andcertified delivery. However, to keep my explanationsimple, I do not cover the details of the protocol, leavingthat for Appendix A (Section 8). For example, I do notdiscuss here how NetBill protects against message

Page 6: Atomicity in Electronic Commerce

replay, communication security, or various timingattacks.

The NetBill protocol is between three parties: acustomer, a merchant, and the NetBill server. Think of aNetBill account held by a customer as equivalent to avirtual electronic credit card account.

Here is the outline of the NetBill protocol

a) The customer requests a price from the merchantfor some goods. (This step is necessary because theprice of a good may depend on the identity of thecustomer; for example, a student ACM membermay qualify for a discount on some items)

b) The merchant makes an offer to the customer

c) The customer tells the merchant that she accepts theoffer.

d) The merchant sends the information goodsrequested encrypted by key

K

.

e) The customer prepares an electronic purchase order(EPO) containing a digitally signed value for:<price, cryptographic-checksum of encryptedgoods, time-out>. The customer sends the signedEPO to the merchant

f) The merchant countersigns the EPO. The merchantalso signs the value of

K

. The merchant sends bothvalues to the NetBill server.

g) The NetBill server checks the signature andcounter-signature on the EPO. It then checks thecustomer’s account to ensure that sufficient fundsexist to approve the transaction, and also checksthat the time-out value in the EPO has not expired.Assuming that all is OK, the NetBill server trans-fers price funds from the customer’s account to themerchant’s account. It stores

K,

and the crypto-graphic-checksum of the encrypted goods. It thenprepares a signed receipt that includes the value

K.

It sends this receipt to the merchant.

h) The merchant records the receipt, and forwards it tothe customer (who can then decrypt her encryptedgoods.)

This protocol thus transfers an encrypted copy ofthe information goods, and records the decryption key inescrow at the NetBill server. Now let us see how thisprotocol provides various types of atomicity protection.

Money atomicity:

all funds transfers occur at theNetBill server, and since the NetBill server uses a localatomic database to store fund values, no money can becreated or destroyed.

Goods atomicity:

if the protocol fails as a result ofcommunications failure or processor failure before the

NetBill server atomically processes the transaction instep (g), then no money changes hands, and thecustomer never receives the decryption key — he gainsno access to the encrypted information goods. On theother hand, if step (g) succeeds, then both the merchantand NetBill server will record the value of

K.

Normally,these values would be forwarded back to the customeras a result of step (h), but if something goes wrong, thecustomer can obtain

K

from either the merchant orNetBill server at any time.

Certified delivery:

since we have goods atomicity,we know that the customer received something inexchange for money. Now, suppose that the customerclaims that he receives goods different from what sheordered. Then, since NetBill server has a cryptographicchecksum of the encrypted goods that is countersignedby both the customer and the merchant, the customercan present her encrypted goods to a judge and verifythat she has not tampered with the goods. Now, since amerchant-signed value of

K

is stored at both thecustomer and the merchant, the judge can decrypt thegoods and determine whether the goods were asadvertised as not.

Thus NetBill presents an example of a highly-atomic electronic commerce protocol. We havecurrently built an alpha version of NetBill at CarnegieMellon (in conjunction with our development andoperations partners, Mellon Bank and VisaInternational), and we hope to prove that NetBill is notonly highly-atomic but that it has the performance,scalability, and efficiency to handle a large number ofmicrotransactions

5. Cryptographic Postage Indicia

Is it possible to achieve money atomicity without usinga central server? Yes, one way to do this is to use securehardware. For example, FIPS 140-1 [16] specifiessupport for tamper-proof and tamper-resistant devicesthat can store information and perform processing tasks.These devices are secure in the sense that any attempt topenetrate them will result in erasure of all informationstored inside them. We could use this to store anelectronic wallet; when a charge is made, the electronicwallet withdraws funds.

We call these tamper-proof devices

secure-coprocessors

.Now the design of such a system is not easy [32],

and there are quite a few risks associated with customerapproval of transactions [8]. However, with carefuldesign it can be made to work.

My research group has been working with the USPostal Service to develop standards for PC-generatedlaser printed indicia for postage meters. These are

Page 7: Atomicity in Electronic Commerce

designed to meet the needs of the Postal ServiceInformation-Based Indicia Program [29].

As Figure 3 shows, it is trivial to copy traditionalindicia using a scanner and a computer. It is equally easyto forge dates and postage values on counterfeitedindicia. (Note: if you ever decide to take up the life acriminal and forge indicia, make sure to add smudges tothe indicia —indicia that are reproduced too clearly caneasily be recognized as forged.)

Using a secure coprocessor, it is easy to store anaccount balance for postal customers. This accountbalance is decremented whenever postage is printed.Now, the secure coprocessor prepares acryptographically signed message that containsenvelope data (sender address, receiver address, datesent, and sequence number). This information is thenprinted on the envelope using an efficient datarepresentation such as PDF-417 [11]. Figure 3 showsLincoln’s Gettysburg address encoded in PDF 417. PDF417 normally encodes 400 bytes per square inch.

When mail is received at a postal sorting facility,the data block is checked to see if they match theaddress used for sorting, and to verify the uniqueness ofthe sequence number. (Note that all mail to givenaddress will be processed by a single sorting station.)Indicia remain valid for six months. (The US PostalService claims to deliver more than 90% of all first class

Figure 1: Traditional indicia are easy to copy.

Figure 2: PDF 417 encoding of Abraham Lincoln’s Gettysburg Address.

mail within three days of being sent and more than 99%in seven days. Thus, six months would appear to be agenerous bound for mail delivery.) The database storedat a local sorting station can regularly be purged ofentries with a date older than six months

If an adversary attempts to break money atomicityby forging indicia, he must do one of two things:

• copy existing indicia, which then will only be validfor the encrypted delivery address, and will becaught at the sorting station; or

• attempt to find the value used to digitally sign thecryptographic indicia, which will require openingthe secure coprocessor, erasing all the vulnerabledata within.

For a more technical exposition on securecoprocessors, see [10], [32], and [33].

6. Open Problems

The field of electronic commerce has many openproblems. Here are some of my favorites:

• What is the relationship between atomicity and ano-nymity? Can they be mutually compatible?

• What is the relationship between atomicity andsecurity? Can they be separated?

• What other atomicity models exist in electroniccommerce (besides money atomicity, goods atomic-ity, and certified delivery)? Is there a generalschema?

• What is the minimum number of messageexchanges necessary in an atomic purchase?

• What atomic electronic commerce mechanisms canbe built for multiple banks or billing servers?

• Can atomicity be used for continuously deliveredinformation (such as continual stock marketupdates) or very large objects (such as video pro-grams)?

• Can we give a formal definition for atomicity?

• How can we prove that a protocol is atomic?

• Is it possible to express atomic properties in termsof model checking?

• Can we extend electronic commerce models to auc-tions? Can we make them efficient and fair?

• Can we extend electronic commerce models to auc-tion markets, such as stock markets?

Page 8: Atomicity in Electronic Commerce

• Can we protect redistributed information or resell-ing of information? (This is the so-called superdis-tribution of Mori and Kawahara [15].)

• Can we devise effective

digital watermarks

thatclearly indicate the purchaser of illegally pirated orredistributed information?

• How can we represent and enforce electronic con-tracts governing the use, distribution, and paymentconditions for information goods and software?

• Can we make a fault-tolerant version of electroniccommerce protocols that remain stable even whenbanks fail? (The results of T. Rabin and Ben-Or[20] seem to be appropriate here.)

• Can we build systems to allow anonymous charita-ble contributions? Can we extend them to allowdocumentation so that one can take a tax credit?

• What is the minimum level microtransaction thatcan be supported in electronic commerce? The min-imum level atomic microtransaction?

• We can express money as tokens or as entries in aserver (see [5]) — is there anyway to express a for-mal equivalence between these two methods?

7. Acknowledgments and Further Sources of Information

Bennet Yee has been my primary collaborator forelectronic commerce work. All of the work describedregarding secure coprocessors and cryptographicpostage indicia is joint work with Bennet. Bennet and Ijointly observed that Chaum-like digital cash protocolsfail to work properly if communications are interrupted,prompting this line of work. Bennet is always a pleasureto work with; I owe him a tremendous intellectual debt.Portions of our work previously appeared in [32] and[33].

Nevin Heintze contributed to the later developmentof cryptographic postage indicia as represented in [10].

Ali Bahreman began thinking about certifieddelivery mechanisms while working on his master’sthesis at CMU in the context of certified electronic mail;together, we came up with several initial protocolsdescribed in [1].

Ben Cox, Tom Wagner, and I first thought ofbuilding on Ali’s protocols for a practical electroniccommerce protocol in the course of Ben and Tom’sbrilliant project in my distributed systems class inSpring 1994. Their project introduced the notion ofcertified delivery electronic commerce protocols. At thesame time, Carnegie Mellon’s Information NetworkingInstitute, under the direction of Marvin Sirbu, had been

pursuing an “internet billing server.” All parties quicklyrecognized the superiority of the protocol developed byBen, Tom, and I; and that protocol became the basis ofthe newly named NetBill project.

Marvin Sirbu and I then became the principalinvestigators in building the NetBill system. Our basicpresentation of NetBill’s properties is contained in [23].Marvin and I, together with a joint student Jean Camp,made a preliminary distinction between moneyatomicity and goods atomicity in [5], although thatpaper is flawed and did not properly distinguish betweencertified delivery and goods atomicity.

Michael Rabin gave me many helpful suggestionsthroughout this project. All of his advice and ideas wereimportant, but I especially appreciated his enthusiasticencouragement during the early stages of this research.

Maurice Herlihy and Mark Tuttle gave me usefulfeedback on a preliminary version of the presentationthat inspired this paper.

Sean Smith and David Johnson have had manyimportant conversations with me on the topic of atomictransactions and rollback.

Students and colleagues at CMU have given me anumber of specific useful suggestions for this research.In additions to those named above, I would like to thankThomas Alexandre, Brad Chen, Howard Gobioff, MikeHarkavy, Mahadev Satyanarayanan, Alfred Spector,Jiawen Su, Jeannette Wing, and Hao-Chi Wong.

More information on NetBill can be found at

http://www.ini.cmu.edu/netbill/

.More information on cryptographic postage indicia

and secure coprocessors can be found at

http://www.cs.cmu.edu/afs/cs/project/dyad/www/

.

8. Appendix A

My description above of the NetBill protocol was, asnoted, only an informal description. Below I present amore formal description of the protocol, excerpted andrevised from [7]. This is a revision of material originallywritten by me together with Benjamin Cox and MarvinSirbu, and I gratefully thank them for permission toreprint this material here.

8.1. The NetBill Transaction Model

The NetBill transaction model involves three parties:the customer, the merchant and the NetBill transactionserver. A transaction involves three phases: pricenegotiation, goods delivery, and payment. Forinformation goods which can be delivered over thenetwork, the NetBill protocol links goods delivery andpayment into a single atomic transaction.

Page 9: Atomicity in Electronic Commerce

In a NetBill transaction, the customer and merchantinteract with each other in the first two phases; theNetBill server is not involved until the payment phase,when the merchant submits a transaction request. Thecustomer contacts the NetBill server directly only in thecase of communications failure or when requestingadministrative functions. Figure 3 shows therelationships among parties in a NetBill transaction.

8.1.1. Transaction Objectives

For a NetBill transaction, we have the following set ofobjectives. (Similar versions of objectives (a)–(d) belowcan be found in [2].)

a) Only authorized customers can charge against aNetBill account.

b) The customer and merchant must agree on the itemto be purchased and the price to be charged.

c) A customer can optionally protect her identity frommerchants.

d) Customers and merchants are provided with proofof transaction results from NetBill.

In addition, we have the following objectives to supportprice negotiation and goods delivery.

e) There is an offer and acceptance negotiation phasebetween customer and merchant.

f) A customer may present credentials identifying heras entitled to special pricing or treatment.

g) A customer receives the information goods she pur-chases if and only if she is charged (and thus themerchant is paid) for the goods.

Customer Merchant

NetBill

Figure 3: Parties in a NetBill Transaction.

Transaction Protocol

Auxiliary Messages

h) A customer may need approval from a fourth(access control) party before the NetBill server willallow a transaction.

Finally, we add as a general objective for all phases ofthe purchase process:

i) The privacy and integrity of communications isprotected from observation or alteration by externalparties.

To achieve these goals, the NetBill protocol provides forstrong authentication and privacy, atomic payment anddelivery protocols, and a flexible access control system.

In the price negotiation phase, the customerpresents evidence of her identity, and (optionally)supplemental credentials, and requests a price quote onan item. The customer may also include a bid for theitem. The merchant responds with a price offer.

In the second phase, the customer accepts ordeclines the offer. In the case of information goods,acceptance constitutes an order for network delivery.The merchant provisionally delivers the goods, underencryption, but withholds the key.

Key delivery is linked to completion of the thirdphase, the payment protocol. In this phase, the customerconstructs, and digitally signs, an electronic paymentorder (or

EPO

) and sends it to the merchant. Themerchant appends the key to the EPO and

endorses

(digitally signs) the EPO, forwarding it to the NetBillserver. The NetBill server returns a digitally signedreceipt, which includes the key, to the merchant, whoforwards a copy to the customer.

8.2. The Transaction Protocol

We use the notation “X

Y” to indicate that

X

sendsthe specified message to

Y

. The basic protocol consistsof eight steps, which are:

1. C

M Price request

2. M

C Price quote

3. C

M Goods request

4. M

C Goods, encrypted with a key

K

5. C

M Signed Electronic Payment Order

6. M

N Endorsed EPO (including

K

)

7. N

M Signed result (including

K

)

8. M

C Signed result (including

K

)

Page 10: Atomicity in Electronic Commerce

Objective (a) from Section 8.1.1 is realized becausethe customer must be authenticated to NetBill before theEPO (generated in step 5) will be accepted (in step 6).

Objective (b) is achieved because the relevantinformation is included in the EPO which must besigned by the customer in step 5 and endorsed by themerchant in step 6.

Section 8.3.2 presents a mechanism implementingobjective (c).

Objective (d) is realized through the digitallysigned receipt from NetBill in step 7.

Objective (e) is achieved by the exchange in steps 1and 2 of the protocol.

Section 8.4.1 presents a solution implementingobjective (f).

Objective (g) is realized by the exchange in steps 4–8, which we call

certified delivery

. The customer firstgets a version of the goods encrypted with a key

K

. Thegoods are also cryptographically checksummed. In thisway, the customer uses the checksum to confirm that shereceived the goods without transmission error. Thecustomer returns the checksum to the merchant togetherwith other information, and that message is forwarded tothe NetBill server. The key

K

that is needed to decryptthe goods is registered with the NetBill server and alsosent to the customer (step 8). The exchange in steps 4–8provides protection to the customer against fraud by themerchant. For example, suppose there is a discrepancybetween what the customer ordered and what themerchant delivered. The customer can easilydemonstrate the discrepancy to a third party (such as ajudge). The customer has NetBill’s receipt (step 7,forwarded in step 8) indicating what was ordered, theamount charged and the key

K

reported to NetBill by themerchant. The customer also has registered with NetBillthe checksum of the encrypted goods. Thus if the goodsare faulty (

e.g.,

purchased software doesn’t run), it iseasy to demonstrate that the problem lies with the goodsas sent and not with any subsequent alteration. Thiscertified delivery technique also protects the merchantby requiring the customer to pay and the payment toclear through the NetBill server before the customergets the use of the goods.

Section 8.4.2 presents a solution for objective (h).Objective (i) is realized by encrypting

communications between all pairs of parties andproviding integrity checks on those messages.

8.2.1. Notation

We use the following notation to denote cryptographicoperations.

X

and

Y

always represent communicatingparties.

K

always represents a cipher key. The protocolis a sequence of messages exchanged among three

parties:

C

, the customer;

M

, the merchant; and

N

, theNetBill server.

T

XY

(Identity) A Kerberos ticket proving to

Y

that

X

is named by

Identity

, and establishing a session key

XY

shared between them.

CC(

Message

) A cryptographic checksum of

Message

, using an algorithm such as the Secure Hash Algo-rithm (SHA) hash function pre-sented in [17].

E

K

(

Message

)

Message

, encrypted by a sym-metric cipher using key

K

. The key

K

may be denoted as

XY

, meaning that it is known only to parties

X

and

Y

. The encrypted message implicitly includes a nonce.

E

X-PUB(Message) Message, encrypted in party X’s public key using the RSA cryp-tosystem as presented in [21].

EX-PRI(Message) Message, encrypted in party Y’s private key using RSA.

[Message]X Message, clearsigned by X using RSA public key cryptog-raphy. Clearsigning is imple-mented by forming Message, Timestamp, EX-PRI(CC(Mes-sage, Timestamp)). This is com-putationally efficient and allows any party to read the Message text without needing X’s public key. The clearsigned item implicitly includes a nonce.

[Message]X-DSA Message, signed and times-tamped by X using the Digital Signature Algorithm (DSA) as described in [18].

Page 11: Atomicity in Electronic Commerce

8.2.2. The Price Request Phase

This section assumes possession of tickets; the methodfor obtaining tickets is shown in Section 8.3. TheIdentity item may actually be a pseudonym, as shown inSection 8.3.2.

These two steps represent a request/responsemessage pair in which the customer requests a pricequote of the merchant. The customer presents anidentifying ticket (the identity presented may be apseudonym; see Section 8.3.2 for details onpseudonyms) to the merchant, along with some optionalcredentials establishing her membership in groupswhich may make her eligible for a discount. (We discussthese credentials in Section 8.4.1.)

The customer passes parameters indicating ProductRequest Data (PRD, an arbitrary stream of application-specific data which the customer and merchant use tospecify the goods) and some flags. These RequestFlagsare the customer’s indication of her request for thedisposition of the transaction (i.e., delivery instructions;see Section 8.2.5.1 for different transaction options).

The customer may also optionally include a Bid,indicating to the merchant a price she may be willing topay for the item.

The Transaction ID, TID, is optional in step 1. Steps1 and 2 may be repeated as needed until the customerand merchant can agree on a price; the TID is present toindicate to the merchant that this is a repeated request.

The merchant stores the PRD for later use indelivering the goods, generates a new set ofRequestFlags based on its response to the customer’sRequestFlags, and generates a price quote and a TID (ifone was not supplied in step 1) to identify thistransaction in later steps. The TID is not globally

{Message}X Message, encrypted for X using RSA public key cryptography. For computational efficiency, this is implemented by forming EK(Message), EX-PUB(K). The encrypted message implicitly includes a nonce.

1. C ⇒ M TCM(Identity), ECM(Credentials, PRD, Bid, RequestFlags, TID)

2. M ⇒ C ECM(ProductID, Price, Request-Flags, TID)

unique; it is used only by the customer and merchant tomaintain context between them.

The ProductID returned by the merchant in step 2 isa human-readable product description that will appearon the customer’s NetBill statement.

8.2.3. The Goods Delivery Phase

Once the customer and merchant have negotiated a pricefor the goods in question, the customer directs themerchant to deliver the goods by supplying the TID thatwas used in the price request phase:

The merchant generates a unique symmetric cipherkey K, encrypts the goods using this key and sends theencrypted goods to the customer, along with acryptographic checksum computed on the encryptedgoods, so that the customer will immediately detect anydiscrepancy before proceeding. The merchant also sendsan Electronic Payment Order ID, or EPOID, with thegoods.

The EPOID is a globally unique identifier whichwill be used in the NetBill server’s database to uniquelyidentify this transaction. It consists of three fields: a fieldidentifying the merchant, a timestamp marking the timeat the end of goods delivery, and a serial number toguarantee uniqueness.

The specification that the EPOID must be globallyunique is used to prevent replay attacks, in whichunscrupulous merchants reuse customers’ old signedpayment instructions. The timestamp portion of theEPOID is used to expire stale transactions; it must begenerated at the end of goods delivery because thedelivery (especially for very large goods) may takelonger than the payment expiration time.

Because the goods are delivered encrypted in step4, the customer cannot use them. The key K needed todecrypt the goods will be delivered in the paymentphase, which follows.

8.2.4. The Payment Phase

After the encrypted goods are delivered, the customersubmits payment to the merchant in the form of a signedElectronic Payment Order, or EPO. At any time beforethe signed EPO is submitted, a customer may abort thetransaction and be in no danger of its being completedagainst her will. The submission of the signed EPOmarks the “point of no return” for the customer.

3. C ⇒ M TCM(Identity), ECM(TID)

4. M ⇒ C EK(Goods), ECM(CC(EK(Goods)), EPOID)

Page 12: Atomicity in Electronic Commerce

An EPO consists of two sections, a clear partcontaining transaction information which is readable bythe merchant and the NetBill server, and an encryptedpart containing payment instructions which is readableonly by the NetBill server. The clear part of the EPOincludes:

• The customer’s (possibly pseudonymous) identity

• The human-readable Product ID (from step 2)

• The negotiated price (from step 2)

• The merchant’s identity

• The cryptographic checksum of the encryptedgoods, to forestall debate over the content of thegoods or whether they were received completelyand correctly

• The cryptographic checksum of the ProductRequest Data (from step 1), to forestall debate overthe details of the order

• The cryptographic checksum of the customer’saccount number with an account verification nonce,so that the merchant may verify that any suppliedcredentials (see Section 8.4.1) were used correctly

• The globally-unique EPOID

The encrypted part of the EPO includes:

• A ticket proving the customer’s true identity

• Any required authorization tokens (see Section8.4.2)

• The customer’s NetBill account number

• The account verification nonce

• A customer memo field

The EPO is a tuple:

Identity,ProductID,Price,M,CC(EK(Goods)),CC(PRD),CC(CAcct, AcctVN),EPOID,TCN(TrueIdentity),ECN(Authorization,

CAcct,AcctVN,CMemo)

Henceforth, we use the terminology EPO to denotethis tuple.

After the customer presents the signed EPO to themerchant, the merchant endorses it and forwards theendorsed EPO to the NetBill server. The endorsed EPOadds the merchant’s account number, the merchant’smemo field, and the goods decryption key, as well as themerchant’s signature:

[[EPO]C, MAcct, MMemo, K]M

At any time before the endorsed EPO is submittedto the NetBill server, the merchant may abort thetransaction and be in no danger of its being completedagainst his will. The submission of the endorsed EPOmarks the “point of no return” for the merchant.

The phase containing the submission andendorsement of the EPO is denoted:

Upon receipt of the signed and endorsed EPO, theNetBill server makes a decision about the transactionand returns the result to the merchant, who in turnforwards it to the customer.

The NetBill server makes its decision based onverification of the signatures, the privileges of the usersinvolved, the customer’s account balance, and theuniqueness and freshness of the EPOID. It then issues areceipt containing the result code, the identities of theparties, the price and description of the goods, theEPOID, and the key K needed to decrypt the goods. Thereceipt is digitally signed by the NetBill server, usingthe Digital Signature Algorithm (DSA). The receipt isdenoted:

Result, Identity, Price, ProductID, M, K, EPOID

For this step, DSA is used rather than RSA becauseof its relative performance. While RSA signatures maybe verified quickly, they are time-consuming to create;DSA signatures, on the other hand, may be createdquickly. By using RSA for customer and merchantsignatures and DSA for NetBill signatures, we may shiftsome computing load away from the NetBill server.

Some of the resulting burden on the merchant canbe lifted by recognizing that, from a business riskperspective, it may be sufficient for a merchant to verifyonly a random sample of receipts signed by the NetBillserver. Since integrity and authenticity are assured bythe symmetric key encryption protocol, onlyaccountability is at stake.

This receipt is returned to the merchant, along withan indication of the customer’s new account balance

5. C ⇒ M TCM(Identity), ECM([EPO]C)

6. M ⇒ N TMN(M), EMN([[EPO]C, MAcct, MMemo, K]M)

Page 13: Atomicity in Electronic Commerce

(encrypted so that only she may read it). The EPO ID isrepeated in the customer-specific data to ensure that themerchant cannot replay data from an earlier transaction.

The Flags included in the customer-specific dataindicate simple messages from the NetBill server to thecustomer; for example, that the account balance hasreached a “low-water mark” and should be replenishedsoon.

In step 8, the merchant responds to the request fromthe customer in step 5, forwarding the messagesreturned by the NetBill server in step 7.

8.2.5. Status Query Exchange

In the event of communications failure after step 5 ofthe protocol, the customer or merchant may be unawareof the transaction’s status. (Before step 5, the transactionmay be aborted with no difficulty, as no parties have yetsignaled their commitment.) The system supports astatus query exchange for delivery of this information.

The request and response proceed as one of thefollowing exchanges, assuming the information isavailable. In each case, an alternate response is possible,indicating that the queried party does not have therequested information (possibly indicating why).

• The merchant requests the transaction status fromthe NetBill server:

• The customer requests the transaction status fromthe merchant:

7. N ⇒ M EMN([Receipt]N-DSA, ECN(EPOID, CAcct, Bal, Flags))

8. M ⇒ C ECM([Receipt]N-DSA, ECN(EPOID, CAcct, Bal, Flags))

1. M ⇒ N TMN(M), EMN(EPOID)

2. N ⇒ M EMN([Receipt]N-DSA, ECN(EPOID, CAcct, Bal, Flags))

1. C ⇒ M TCM(Identity), ECM(EPOID)

2. M ⇒ C ECM([Receipt]N-DSA, ECN(EPOID, CAcct, Bal, Flags))

• The customer requests the transaction status fromthe NetBill server:

• The customer requests the transaction status fromthe merchant for a Non-NetBill transaction (seeSection 8.2.5.1):

8.2.5.1. Handling Zero-Priced Goods

We anticipate that many NetBill transactions will be forsubscription goods; i.e., goods for which the customer’smarginal price is zero. With zero-priced goods, fraud isless important, and so we make several refinements tomake our protocol more efficient in these cases.

First, we include a flag in the RequestFlags field ofthe price request (step 1) informing the merchant “If theprice for this product is zero, treat this message as anautomatic request for the goods.”

Zero-priced transactions do not need to go throughthe NetBill server, as long as both parties agree. We canput another flag in the RequestFlags that informs themerchant “I require a NetBill receipt for thistransaction.” If this flag is present, the merchant mustsubmit the transaction to the NetBill server, even if theprice is zero. (The merchant may also decide to submit azero-price transaction to the NetBill server.)

A customer or merchant may want to use theNetBill server on a zero-priced transaction if theyrequire a signed receipt from a third party confirmingthe transaction. While subscription goods may notrequire a receipt, a merchant may decide to put a zero-priced purchase through NetBill in a “buy ten, get onefree” situation so as to be able to prove that he actuallyprovided the free item.

The merchant may change his price quotedepending on this flag; if NetBill charges the merchantfor billing services, the merchant may want to recoverthis cost if the customer requests a NetBill receipt forwhat might otherwise be a zero-priced transaction.

Combinations of these flags allow us to supportfour basic types of zero-price delivery:

1. C ⇒ N TCN(TrueIdentity), ECN(EPOID)

2. N ⇒ C ECN([Receipt]N-DSA,EPOID, CAcct, Bal, Flags)

1. C ⇒ M TCM(Identity), ECM(EPOID)

2. M ⇒ C ECM(Result, K)

Page 14: Atomicity in Electronic Commerce

8.2.5.2. Type I: Zero-Price Certified Deliv-ery

This protocol eliminates the separate product requestphase. Because steps 2 and 4 from the original protocolare combined, we indicate that by making steps 2 and 4into a single step labeled 2/4.

8.2.5.3. Type II: Certified Delivery without NetBill Server

This protocol improves on Type I by further eliminatingthe call to the NetBill server. With this modification, thepayment phase becomes little more than anacknowledgment.

8.2.5.4. Type III: Verified Delivery

This protocol is nearly the same as the Type II protocol,except that the goods are encrypted in the shared sessionkey CM. This bypasses the certified deliverymechanism, allowing the customer’s software to beginstreaming the goods to a viewer rather than being

1. C ⇒ M TCM(Identity), ECM(Credentials, PRD, Bid, RequestFlags, TID)

2/4. M ⇒ C ECM(ProductID, Price(=0), RequestFlags, TID), EK(Goods), ECM(CC(EK(Goods)), EPOID)

5. C ⇒ M TCM(Identity), ECM([EPO]C)

6. M ⇒ N TMN(M), EMN([[EPO]C, MAcct, MMemo, K]M)

7. N ⇒ M EMN([Receipt]N-DSA, ECN(EPOID, CAcct, Bal, Flags))

8. M ⇒ C ECM([Receipt]N-DSA, ECN(EPOID, CAcct, Bal, Flags))

1. C ⇒ M TCM(Identity), ECM(Credentials, PRD, Bid, RequestFlags, TID)

2/4. M ⇒ C ECM(ProductID, Price(=0), RequestFlags, TID), EK(Goods), ECM(CC(EK(Goods)), EPOID)

5. C ⇒ M TCM(Identity), ECM(EPOID, CC(EK(Goods)))

8. M ⇒ C ECM(Result, K)

obliged to wait until all the goods have been deliveredbefore receiving the key.

8.2.5.5. Type IV: Unverified Delivery

This protocol improves on Type III by eliminating theacknowledgment of goods delivery in the paymentphase if the merchant does not need it.

8.3. Identities and Authentication

When a customer creates a NetBill account, she receivesa unique User ID and generates the RSA public key pairassociated with that User ID. This key pair is certifiedby NetBill, and is used for signatures and authenticationwithin the system. (See [12] for a discussion of publickey certification.)

Section 8.2.4 showed how these signatures will beused in the payment phase of the protocol. However, ourprotocol also uses Kerberos tickets. The NetBilltransaction protocol involves several phases, for pricenegotiation, goods delivery, and payment; only the lastof these phases requires nonrepudiable signatures.Instead of using public key cryptography for messageauthentication and encryption throughout the NetBillsystem, we use symmetric cryptography because itoffers significant performance advantages.

We use the public key cryptography infrastructureto alleviate problems with traditional symmetric-keyKerberos (see [28]):

Kerberos uses a two-level ticket scheme; toauthenticate oneself to a Kerberos service, one mustobtain a service ticket, which establishes a sharedsymmetric session key between the client and server,and establishes that the Kerberos Ticket Granting Server

1. C ⇒ M TCM(Identity), ECM(Credentials, PRD, Bid, RequestFlags, TID)

2/4. M ⇒ C ECM(ProductID, Price(=0), RequestFlags, TID, Goods, CC(Goods), EPOID)

5. C ⇒ M TCM(Identity), ECM(EPOID, CC(Goods))

8. M ⇒ C ECM(Result)

1. C ⇒ M TCM(Identity), ECM(Credentials, PRD, Bid, RequestFlags, TID)

2/4. M ⇒ C ECM(ProductID, Price(=0), RequestFlags, TID, Goods, CC(Goods))

Page 15: Atomicity in Electronic Commerce

believes the client’s identity. To obtain a service ticket, aclient must first obtain a ticket-granting ticket (or TGT),which proves the client’s identity to the Ticket GrantingServer. A client obtains a TGT via request from a KeyDistribution Center, or KDC.

The Kerberos KDC/TGT arrangement introducestwo significant problems that we may alleviate usingpublic key cryptography. First, because it maintains ashared symmetric cipher key with every principal in thesystem, it is an attractive target for attack; recoveringfrom compromise of the KDC requires establishing newshared keys with all users of the system. Second, a KDCand TGT will be a communications or processingbottleneck if a large number of users present a heavytraffic load.

To eliminate the Ticket Granting Server, we replacethe TGT with a public key certificate, allowing eachservice to act as its own Ticket Granting Server. That is,a user presents a service ticket request encrypted with acertified public key (we call this a Public Key-basedTGT, or PKTGT), and receives in response a symmetric-cipher-based service ticket. This service ticket isidentical in form to a Kerberos service ticket. The KeyDistribution Center is replaced by a key repository. Theprotocol for a customer to obtain a service ticket for amerchant M is as follows (before this step occurs, thecustomer requests the merchant’s public key certificateover any available channel—such as an unsecuredremote procedure call):

This model preserves the efficiency of symmetricciphers for most communication and repeatedauthentication, and isolates the computational expenseof public key cryptography to initial authenticationbetween parties. We refer to this model as “Public KeyKerberos,” or “PK Kerberos.”

In the NetBill system, a customer obtains Kerberostickets for the NetBill transaction server at thebeginning of a session and obtains Kerberos tickets formerchants as she needs them. Merchant servers willcontinually maintain their own tickets for the NetBilltransaction server.

8.3.1. Key Repository

Private keys are large, so users cannot be expected toremember them. Permanently storing private keys at auser’s workstation poses security risks and restricts theuser’s electronic commerce activities to a singleworkstation. NetBill uses a key repository to optionally

1. C ⇒ M [{Identity, M, Timestamp, K}M]C

2. M ⇒ C EK(TCM(Identity), CM)

store customers’ private keys. These keys are encryptedby a symmetric key derived from a passphrase knownonly to the customer.

8.3.1.1. Key Validation and Revocation Cer-tificates

We use a public key certificate scheme (like thatpresented in [12]) to bind User IDs to keys, with NetBillas the certifying authority. NetBill generates a certificatewhen a customer first proves her identity and beginsusing NetBill.

However, allowing merchants, as services, to granttheir own tickets based on these certificates poses aproblem: NetBill is no longer involved in ticket-granting, and cannot prevent a ticket from being issuedto a user with a compromised key. NetBill needs toinvalidate compromised keys as quickly as possible.

NetBill maintains a Certificate Revocation List(CRL) at its server. When a key is compromised, theowner creates a Revocation Certificate and places it inthe key repository along with her key. Any party cancheck that a given key has not been compromised byexamining the revocation list.

Initially, it would seem that it is necessary for thecustomer and merchant to contact the server to checkCRLs on each transaction. However, it is possible toeliminate this check by allowing the NetBill transactionserver to do it when it processes the paymenttransaction. By delaying the CRL check to late in theprotocol, we introduce some minor risks. Customers andmerchants may disclose information such as theirpreference for particular items or special prices to boguspeers, but there is no financial risk.

8.3.2. Pseudonyms

Some customers want to disguise their identities.NetBill provides two pseudonym methods to protect theprivacy of the customer’s identity: a per-transactionmethod that uses a unique pseudonym for eachtransaction, and a per-merchant method that uses aunique pseudonym for each customer-merchant pair.(See [6] for a full discussion of privacy protection withpseudonyms.) The per-merchant pseudonym is usefulfor customers who wish to maintain a consistentpseudonymous identity to qualify for frequent-buyerdiscounts.

These pseudonym schemes are implemented byintroducing a pseudonym-granting server, P, to createpseudonymous PKTGTs for the customer. The protocolfor obtaining and using a pseudonymous PKTGT is asfollows. The customer obtains the pseudonymous

Page 16: Atomicity in Electronic Commerce

PKTGT in steps 1–2, and uses it with a merchant insteps 3–4 exactly as she would use a normal PKTGT:

The protocol is the same for both kinds ofpseudonyms; the desired type of pseudonym (per-merchant or per-transaction) is indicated in the Typefield in step 1. The extra message [TrueIdentity, M,Pseudonym, Timestamp]P in step 2 is the customer’sreceipt proving that she was using the pseudonymPseudonym with the named merchant at the timeindicated. This may be useful to the customer inconjunction with the receipt received in step 8 of thetransaction (which contains only the pseudonym) tolater prove that she was involved in the transaction.

8.4. Credentials and Authorizations

In [19], Neuman presents a system of using restrictedproxies for authorization. A restricted proxy is a ticketgiving the bearer authority to perform certain operationsnamed in the ticket. NetBill uses a similar construct toimplement credentials to prove group membership (toallow merchants to provide discounts to special groups)and to implement access control mechanisms.

8.4.1. Credentials for Group Membership

An organization can provide a credential server whichissues credential proxies proving membership in agroup. In this case, the credential server is asserting afact (membership in a group) about which it isauthoritative. For example, an auto club may provide acredential server which issues credentials to themembers of the club; merchants who offer discounts tothe club’s members will accept these credentials asproof of membership. The protocol for obtaining acredential (assuming the customer has already obtaineda service ticket for the credential server) from acredential server, G, is as follows:

1. C ⇒ P [{TrueIdentity, M, Timestamp, K1, Type}P]C

2. P ⇒ C EK1(K2, [{Pseudonym, M, Times-tamp, K2}M]P, [TrueIdentity, M, Pseudonym, Timestamp]P)

3. C ⇒ M [{Pseudonym, M, Timestamp, K2}M]P

4. M ⇒ C EK2(TCM(Pseudonym), CM)

Credentials obtained in this manner are presented tomerchants in the price request phase of the transactionprotocol, step 1.

A credential issued to a customer may beunrestricted, or it may optionally be restricted for use ona specific account (for example, in order to preventcorporate employees from taking advantage ofcorporate discounts for personal purchases). This isaccomplished by passing the account number to thegroup server as part of the request. If the accountnumber is appropriate for this group, the credential willbe issued. The credential contains a cryptographicchecksum of the account number and an “AccountVerification Nonce,” which is also returned to thecustomer along with the credential.

This nonce is a pseudorandom number ensuringthat merchants can neither determine which differentcustomers (or the same customer in repeated sessions)are using the same account nor easily verify guesses ofthe customer’s account number. The nonce is passedalong to the NetBill server in the encrypted part of theEPO so that the NetBill server can verify that thechecksum passed to the merchant (for his comparison tothe credential) corresponds to the account numberactually being used.

The Detail field allows a credential server toinclude additional information in a format specific to thecredential server. This would allow, for example, amultiple-journal subscription credential server to issue asingle credential for all subscribers, using the Detailfield to specify which journal subscriptions the customerholds.

Credentials can also be used by cooperatingmerchants to restrict information access. In this way,merchants only sell to approved customers: those whocan present a certain credential. This offers a solutionfor merchants who, for example, can restrict distributionof sensitive documents only to individuals whosecredentials verify a need-to-know.

8.4.2. Access Control Mechanism

As noted in [19], proxies can implement access control.An account owner (such as a parent) may have arestriction on the account such that no purchases can be

1. C ⇒ G TCG(Identity), ECG(Group, CAcct)

2. G ⇒ C ECG([Group, Detail, Identity, CC(CAcct, AcctVN), Times-tamp]G, AcctVN)

Page 17: Atomicity in Electronic Commerce

completed by a given customer (such as a child) withoutapproval from an access control server. This allowsdifferent organizations to provide access controlservices. For example, both the PTA and a church groupcould offer competing access control services.

To obtain an access control authorization, acustomer C must present details of a specific transactionto the access control server A, who grants a single-useproxy authorizing the given transaction. The protocol isas follows:

The item returned in step 2 is the Authorizationitem used in step 5 of the transaction protocol (seeSection 8.2.4).

8.5. Complaints and Failure Analysis

The NetBill protocols are robust against failures, andretain essential information to protect customers andmerchants against fraud. Our system can respond tocomplaints made by either the customer or themerchant. In this section, we examine those complaintsand discuss how they are handled. First, we look atpotential customer complaints, and then at potentialmerchant complaints.

8.5.1. Customer Complaints

8.5.1.1. Incorrect or Damaged Goods

• “This isn’t the product I specified.”

• “The goods arrived broken or incomplete.”

• “The decryption key I was given was wrong.”

In the event that the decrypted goods do not matchthe product description as given by the merchant, thedispute must be brought to the attention of a humanarbitrator, who will determine the validity of thecustomer’s complaint and, if appropriate, direct themerchant to provide a refund.

The arbitrator uses the registered copies at NetBillof the customer’s signed EPO containing acryptographic checksum of the encrypted goods, and themerchant’s signed endorsement indicating hisagreement with that cryptographic checksum and

1. C ⇒ A TCA(Identity), ECA(M, ProductID, Price, CC(EK(Goods)), EPOID, CAcct)

2. A ⇒ C ECA(EA-PRI(CC(Identity, M, Pro-ductID, Price, CC(EK(Goods), EPOID, CAcct)))

attesting to the decryption key. The arbitrator comparesthese registered values against the copy of the encryptedgoods and decryption key provided by the customer inher complaint. The arbitrator can easily determinewhether the purported problem with the goods is thefault of the merchant or an error by the customer.

• “The goods are not as advertised.”

The protocol can be used to demonstrate whetherthe goods delivered are the goods ordered, as shownabove. However, if the customer was induced to buy thegoods by false advertising claims, this protocol providesno help. The customer must lodge a complaint with theFederal Trade Commission or other appropriate agency.It is important for billing servers to monitor thesecharges and assist with their resolution.

• “I bought this but never got the decryption key.”

This complaint may be answered by directing thecustomer to perform a status query (see Section 8.2.5) toretrieve the key. In the event that the decryption keydoes not yield a satisfactory decryption, the dispute willchange to one of the other complaints listed.

8.5.1.2. Transaction Disputes

• “I agreed to pay $X, but was charged $Y instead.”

• “I’ve only bought $X worth of goods, but my bal-ance has gone down by $Y.”

Because the NetBill server has a signed EPO fromthe customer, it can prove that the customer approvedthe purchase(s) for $Y. In the event that the NetBillserver cannot provide the signed EPO(s), the customer’smoney is refunded. This protects customers againstfraud by the operators of the NetBill server.

• “I never bought this, but it appears on my state-ment.”

• “I told the merchant no, but he put it through any-way.”

Because the NetBill server has signed EPOs fromthe customer, it can prove that the customer approvedthe purchases. In the event that the NetBill server cannotprovide the signed EPOs, the customer’s money isrefunded.

• “You told me this transaction didn’t go through, butI got charged anyway.”

Because the NetBill server provides signed receiptseven for failed transactions, the customer can presentthese receipts to prove that the transactions weredeclined. If the customer cannot produce these receiptsand the NetBill server claims to have approved the

Page 18: Atomicity in Electronic Commerce

transactions, it must provide the decryption keys for theinformation goods (via status query exchange).

8.5.2. Merchant Complaints

8.5.2.1. Insufficient Payment

• “I sold $X worth of goods but only received $Y.”

• “You told me this transaction went through, but Inever got paid for it.”

In all transactions, the NetBill server provides asigned receipt indicating the success or failure of atransaction. In the event that a merchant is not properlycredited, he can prove the error by presenting thesesigned receipts.

References[1] A. Bahreman and J. D. Tygar. “Certified

Electronic Mail.” In Proceedings of the InternetSociety Symposium on Network and DistributedSystem Security, pages 3–19, San Diego, CA,February 1994.

[2] M. Bellare, et al. “iKP Family of SecureElectronic Payment Protocols.” In Proceedings ofthe First USENIX Workshop on ElectronicCommerce, pages 89–106, July 1995.

[3] N. Borenstein. “Perils and Pitfalls of PracticalCyber Commerce: the Lessons of First Virtual’sFirst Year.” Presented at Frontiers in ElectronicCommerce, Austin, TX, October 1994.

[4] E. Brickell, P. Gemmell, and D. Kravitz.“Trustee-based Tracing Extensions toAnonymous Cash and the Making of AnonymousChange.” In Proceedings of the Sixth ACM-SIAMSymposium on Discrete Algorithms, pages 457–466, 1995.

[5] L. Camp, M. Sirbu, and J. D. Tygar. “Token andNotational Money in Electronic Commerce.” InProceedings of the First USENIX Workshop onElectronic Commerce, pages 1–12, July 1995.

[6] B. Cox. Maintaining Privacy in ElectronicTransactions. Information Networking InstituteTechnical Report TR 1994–8, Fall 1994.

[7] B. Cox, J. D. Tygar, and M. Sirbu. “NetBillSecurity and Transaction Protocol.” InProceedings of the First USENIX Workshop onElectronic Commerce, pages 77–88, July 1995.

[8] H. Gobioff, S. Smith, and J. D. Tygar. SmartCards in Hostile Environment. CMU-CSTechnical Report CMU-CS-95-188, September1995.

[9] J. Gray and A. Reuter. Transactions Processing:Techniques and Concepts. Morgan Kaufmann,San Mateo, CA, 1994.

[10] N. Heintze, J. D. Tygar, and B. Yee.“Cryptographic Postage Indicia.” To appear.

[11] S. Itkin and J. Martell. A PDF417 Primer: AGuide to Understanding Second Generation BarCodes and Portable Data Files. Technical ReportMonograph 8, Symbol Technologies. April 1988

[12] S. Kent. RFC 1422: Privacy Enhancement forElectronic Mail: Part II: Certificate-Based KeyManagement. Internet Activities Board RequestFor Comments 1422, February 1993.

[13] N. Lynch, M. Merritt, W. Weihl, A. Fekete.Atomic Transactions. Morgan Kaufmann, SanMateo, CA, 1994.

[14] M. Manasse. “The Millicent Protocols forElectronic Commerce.” In Proceedings of theFirst USENIX Workshop on ElectronicCommerce, pages 117–123, July 1995.

[15] R. Mori and M. Kawahara. “Superdistribution:the Concept and the Architecture.” InTransactions of the Institute of Electronics,Information, and Communication Engineers(Japan), E73(7) pages 1133–1146.

[16] National Institute of Standards and Technology.FIPS 140-1: Security Requirements forCryptographic Modules. January 1994

[17] National Institute of Standards and Technology.FIPS 180: Federal Information ProcessingStandard: Secure Hash Standard (SHS). April1993.

[18] National Institute of Standards and Technology.FIPS 186: Federal Information ProcessingStandard: Digital Signature Standard (DSS).May 1994.

[19] B. Neuman. “Proxy-Based Authorization andAccounting for Distributed Systems.” InProceedings of the 13th International Conferenceon Distributed Computing Systems, pages 283–291, May 1993.

Page 19: Atomicity in Electronic Commerce

[20] T. Rabin and M. Ben-Or. “Verifiable SecretSharing and Multiparty Protocols with HonestMajority.” In Proceedings of the 21st ACMSymposium on Theory of Computing, pages 73–85, May 1989.

[21] R. Rivest, A. Shamir, L. Adleman. “A Method forObtaining Digital Signatures and Public-KeyCryptosystems.” In Communications of the ACM,21(2), February 1978.

[22] B. Schneier. Applied Cryptography: Protocols,Algorithms, and Source Code in C. New York:John Wiley & Sons, 1994.

[23] M. Sirbu and J. D. Tygar. “NetBill: An InternetCommerce System Optimized for NetworkDelivered Services.” In IEEE PersonalCommunications, 2(4) pages 34–39, August1995.

[24] A. Somogyi, T. Wagner, et al. NetBill.Information Networking Institute TechnicalReport TR 1994–11, Fall 1994.

[25] S. Smith. Secure Distributed Time for SecureDistributed Protocols. Ph.D. Thesis, CMU-CSTechnical Report CMU-CS-94-177, September1994.

[26] S. Smith, D. Johnson, and J. D. Tygar.“Completely Asynchronous Optimistic Recoverywith Minimal Rollbacks.” In Proceedings of the25th International IEEE Symposium on Fault-Tolerant Computing, pages 362–372, June 1995.

[27] S. Smith and J. D. Tygar. “Security and Privacyfor Partial Order Time.” In Proceedings of theISCA International Conference on Parallel andDistributed Computing Systems, pages 70–79,October 1994.

[28] J. Steiner, B. Neuman and J. Schiller. “Kerberos:An Authentication Service for Open NetworkSystems.” In USENIX Winter Conference, pages191–202, February 1988.

[29] US Postal Service. Information Based IndiciaProgram (IBIP) New Direction MeteringTechnology. May 1995.

[30] USENIX Association. Proceedings of the FirstUSENIX Workshop on Electronic Commerce,July 1995.

[31] Visa USA and Anderson Consulting. 1992 CreditCard Functional Cost Study. September 1992.

[32] B. Yee. Using Secure Coprocessors. Ph.D.Thesis, CMU-CS Technical Report CMU-CS-94-149, May 1994.

[33] B. Yee and J. D. Tygar. “Secure Coprocessors inElectronic Commerce Applications.” InProceedings of the First USENIX Workshop onElectronic Commerce, pages 155–170, July 1995.