Changeset 18 for trunk/standards

Show
Ignore:
Timestamp:
12/15/07 18:56:42 (4 years ago)
Author:
ocmathew
Message:

Add Prior and Follow to each message (information to be used to create simple state machine for messages)

Location:
trunk/standards/messages
Files:
4 modified

Legend:

Unmodified
Added
Removed
  • trunk/standards/messages/DSDB.to.wallet.txt

    r15 r18  
    1515                                                #key_identifier1 #encrypted_serial1 
    1616                                                #key_identifier2 #encrypted_serial2 
     17        Prior:  Hello 
     18        Follow: LOCK_COINS_ACCEPT 
     19                        LOCK_COINS_FAILURE 
    1720 
    1821DSDB: 
    1922  LOCK_COINS_ACCEPT             #hex_string(transaction_id) TIME(lock_expires) 
     23        Prior:  LOCK_COINS_REQUEST 
     24        Follow: Goodbye 
    2025 
    2126  LOCK_COINS_FAILURE    #hex_sting(transaction_id) #hex_string(number_of_failures) 
     
    2833                                                                Serial already redeemed                                         Permanant 
    2934                                                                Serial locked (not spent)                                       Temporary 
     35        Prior:  LOCK_COINS_REQUEST 
     36        Follow: Goodbye 
    3037 
    3138 
     
    3643Wallet: 
    3744  UNLOCK_COINS_REQUEST  #hex_string(transaction_id) 
     45        Prior:  Hello 
     46        Follow: UNLOCK_COINS_PASS 
     47                        UNLOCK_COINS_FAILURE 
    3848 
    3949DSDB: 
    4050  UNLOCK_COINS_PASS 
     51        Prior:  UNLOCK_COINS_REQUEST 
     52        Follow: Goodbye 
     53         
    4154  UNLOCK_COINS_FAILURE  #hex_string(transaction_id) "Reason" 
    4255                                                        Reasons: 
     
    4457                                                                Transaction already completed 
    4558                                                                Lock expired *Not really a failure...* 
     59        Prior:  UNLOCK_COINS_REQUEST 
     60        Follow: Goodbye 
  • trunk/standards/messages/IS.to.wallet.txt

    r16 r18  
    1616Wallet: 
    1717  MINTING_KEY_FETCH_DENOMINATION        #string(denomination) 
     18        Prior:  Hello 
     19        Follow: MINTING_KEY_PASS 
     20                        MINTING_KEY_FAILURE 
     21                         
    1822  MINTING_KEY_FETCH_KEYID       #hexstring(key_id)} 
     23        Prior:  Hello 
     24        Follow: MINTING_KEY_PASS 
     25                        MINTING_KEY_FAILURE 
    1926 
    2027IS: 
    2128  MINTING_KEY_PASS      keycertificate 
     29        Prior:  MINTING_KEY_FETCH_DENOMINATION 
     30                        MINTING_KEY_FETCH_KEYID 
     31        Follow: Goodbye 
     32                         
    2233  MINTING_KEY_FAILURE   "Reason" 
    2334                                                Reasons: 
    2435                                                        Unknown denomination 
    2536                                                        Unknown key_id 
     37        Prior:  MINTING_KEY_FETCH_DENOMINATION 
     38                        MINTING_KEY_FETCH_KEYID 
     39        Follow: Goodbye 
    2640   
    2741 
     
    3448                                #key_id(blind1) #base64(blind1) 
    3549                                #key_id(blind2) #base64(blind2) 
     50        Prior:  Hello 
     51        Follow: MINT_REJECT 
     52                        MINT_ACCEPT 
    3653 
    3754IS: 
     
    4360                                                Unable to blind 
    4461                                                        Question: if the IS doesn't have the minting key, use a similar key to test? 
     62        Prior:  MINT_REQUEST 
     63        Follow: Goodbye 
    4564 
    4665  MINT_ACCEPT   #base64(request_id) 
     66        Prior:  MINT_REQUEST 
     67        Follow: Goodbye 
    4768 
    4869 
     
    5374Wallet: 
    5475  FETCH_MINTED_REQUEST  #base64(request_id) 
     76        Prior:  Hello 
     77        Follow: FETCH_MINTED_FAILURE 
     78                        FETCH_MINTED_WAIT 
     79                        FETCH_MINTED_ACCEPT 
    5580 
    5681 
     
    6287                                                                Unknown request_id 
    6388                                                                Unable to blind (note: redundant? maybe not for all signatures) 
     89        Prior:  FETCH_MINTED_REQUEST 
     90        Follow: Goodbye 
    6491                                                                 
    6592  FETCH_MINTED_WAIT     #base64(request_id) "Reason" 
     
    6895                                                                Request not credited 
    6996                                                                        Note: this message may be a permanant failure (FETCH_MINTED_FAILURE) 
     97        Prior:  FETCH_MINTED_REQUEST 
     98        Follow: Goodbye 
    7099   
    71100  FETCH_MINTED_ACCEPT   #base64(request_id) #hex_string(number_of_blinds) 
    72101                                                #base64(signature_of_blind1) 
    73102                                                #base64(signature_of_blind2) 
     103        Prior:  FETCH_MINTED_REQUEST 
     104        Follow: Goodbye 
    74105 
    75106 
     
    80111Wallet: 
    81112  DSDB_KEY_REQUEST 
     113        Prior:  Hello 
     114        Follow: DSDB_KEY_PASS 
    82115 
    83116IS: 
    84117  DSDB_KEY_PASS keycertificate 
     118        Prior:  DSDB_KEY_REQUEST 
     119        Follow: Goodbye 
    85120 
    86121 
     
    98133                                                                The only required defined target is for another transaction to the mint. 
    99134                                                                        MINT_REQUEST=#string(request_id) 
     135        Prior:  Hello 
     136        Follow: REDEEM_COINS_REJECT 
     137                        REDEEM_COINS_ACCEPT 
    100138IS: 
    101139  REDEEM_COINS_REJECT   #hex_string(number_of_coins) 
     
    109147                                                                Unknown target 
    110148                                                                        Note: Can be used if Mint requires request_id to already be awaiting minting 
     149        Prior:  REDEEM_COINS_REQUEST 
     150        Follow: Goodbye 
    111151 
    112152  REDEEM_COINS_ACCEPT 
     153        Prior:  REDEEM_COINS_REQUEST 
     154        Follow: Goodbye 
  • trunk/standards/messages/all.txt

    r16 r18  
    1111                                                = REDEEM_COINS          = 
    1212                                                ===================== 
     13                                                 
     14        Prior: All messages between two entities that can occur directly before this one 
     15        Follow: All messages between two entities that can occur directly after this one 
     16         
     17        Hello is the initial handshake between two entities or the state after a Goodbye 
     18        Goodbye is the end of a transaction, although also a Hello for a new transaction 
    1319 
    1420============================================================================ 
     
    3137                                blank1 
    3238                                blank2 
     39                Prior:  Hello 
     40                Follow: BLANK_FAILURE 
     41                                BLANK_REJECT 
     42                                BLANK_ACCEPT 
    3343 
    3444B: 
     
    4050                                                Unknown issuer 
    4151                                                        Note: Also used for an untrusted issuer 
     52                Prior:  BLANK_PRESENT 
     53                Follow: Goodbye 
    4254                                                 
    4355  BLANK_FAILURE #hex_string(0) "reason" 
    4456                                        Reason: 
    4557                                                Cancelled 
     58                Prior:  BLANK_PRESENT 
     59                Follow: Goodbye 
    4660                                                 
    4761 
     
    5569                                                DSDB: Serial already redeemed                                   Permanant 
    5670                                                DSDB: Serial locked (not spent)                                 Temporary 
     71                Prior:  BLANK_PRESENT 
     72                Follow: Goodbye 
    5773 
    5874  BLANK_REJECT  #hex_string(0) "reason" 
    5975                                        Reasons: 
    6076                                                Cancelled 
     77                Prior:  BLANK_PRESENT 
     78                                BLANK_ACCEPT (Message from self) 
     79                Follow: Goodbye 
    6180 
    6281  BLANK_ACCEPT 
    63          Note: After ACCEPT, a REJECT #hex_string(0) can be given to abort the transaction 
     82                Note:   After ACCEPT, a REJECT #hex_string(0) can be given to abort the transaction 
     83                Prior:  BLANK_PRESENT 
     84                Follow: COINS_REDEEM 
     85                                BLANK_REJECT (Message from self) 
    6486 
    6587 
     
    7294                                #base64(coin1) 
    7395                                #base64(coin2) 
     96                Prior:  BLANK_ACCEPT 
     97                Follow: COINS_REJECT 
     98                                COINS_ACCEPT 
    7499 
    75100B: 
     
    81106                                                Unknown coin 
    82107                                                        Note: Used when the coin we are given is different than the blank 
     108                Prior:  COINS_REDEEM 
     109                Follow: COINS_REDEEM 
     110                                Goodbye 
    83111 
    84112  COINS_REJECT  #hex_string(0) "Reason" 
    85113                                        Reasons: 
    86114                                                *I can't think of anything valid* 
     115                Prior:  COINS_REDEEM 
     116                Follow: COINS_REDEEM 
     117                                Goodbye 
    87118 
    88119  COINS_ACCEPT 
     120                Prior:  COINS_REDEEM 
     121                Follow: Goodbye 
    89122 
    90123 
     
    109142Wallet: 
    110143  MINTING_KEY_FETCH_DENOMINATION        #string(denomination) 
     144        Prior:  Hello 
     145        Follow: MINTING_KEY_PASS 
     146                        MINTING_KEY_FAILURE 
     147                         
    111148  MINTING_KEY_FETCH_KEYID       #hexstring(key_id)} 
     149        Prior:  Hello 
     150        Follow: MINTING_KEY_PASS 
     151                        MINTING_KEY_FAILURE 
    112152 
    113153IS: 
    114154  MINTING_KEY_PASS      keycertificate 
     155        Prior:  MINTING_KEY_FETCH_DENOMINATION 
     156                        MINTING_KEY_FETCH_KEYID 
     157        Follow: Goodbye 
     158                         
    115159  MINTING_KEY_FAILURE   "Reason" 
    116160                                                Reasons: 
    117161                                                        Unknown denomination 
    118162                                                        Unknown key_id 
     163        Prior:  MINTING_KEY_FETCH_DENOMINATION 
     164                        MINTING_KEY_FETCH_KEYID 
     165        Follow: Goodbye 
    119166   
    120167 
     
    127174                                #key_id(blind1) #base64(blind1) 
    128175                                #key_id(blind2) #base64(blind2) 
     176        Prior:  Hello 
     177        Follow: MINT_REJECT 
     178                        MINT_ACCEPT 
    129179 
    130180IS: 
     
    136186                                                Unable to blind 
    137187                                                        Question: if the IS doesn't have the minting key, use a similar key to test? 
     188        Prior:  MINT_REQUEST 
     189        Follow: Goodbye 
    138190 
    139191  MINT_ACCEPT   #base64(request_id) 
     192        Prior:  MINT_REQUEST 
     193        Follow: Goodbye 
    140194 
    141195 
     
    146200Wallet: 
    147201  FETCH_MINTED_REQUEST  #base64(request_id) 
     202        Prior:  Hello 
     203        Follow: FETCH_MINTED_FAILURE 
     204                        FETCH_MINTED_WAIT 
     205                        FETCH_MINTED_ACCEPT 
    148206 
    149207 
     
    155213                                                                Unknown request_id 
    156214                                                                Unable to blind (note: redundant? maybe not for all signatures) 
     215        Prior:  FETCH_MINTED_REQUEST 
     216        Follow: Goodbye 
    157217                                                                 
    158218  FETCH_MINTED_WAIT     #base64(request_id) "Reason" 
     
    161221                                                                Request not credited 
    162222                                                                        Note: this message may be a permanant failure (FETCH_MINTED_FAILURE) 
     223        Prior:  FETCH_MINTED_REQUEST 
     224        Follow: Goodbye 
    163225   
    164226  FETCH_MINTED_ACCEPT   #base64(request_id) #hex_string(number_of_blinds) 
    165227                                                #base64(signature_of_blind1) 
    166228                                                #base64(signature_of_blind2) 
     229        Prior:  FETCH_MINTED_REQUEST 
     230        Follow: Goodbye 
    167231 
    168232 
     
    173237Wallet: 
    174238  DSDB_KEY_REQUEST 
     239        Prior:  Hello 
     240        Follow: DSDB_KEY_PASS 
    175241 
    176242IS: 
    177243  DSDB_KEY_PASS keycertificate 
     244        Prior:  DSDB_KEY_REQUEST 
     245        Follow: Goodbye 
    178246 
    179247 
     
    191259                                                                The only required defined target is for another transaction to the mint. 
    192260                                                                        MINT_REQUEST=#string(request_id) 
     261        Prior:  Hello 
     262        Follow: REDEEM_COINS_REJECT 
     263                        REDEEM_COINS_ACCEPT 
    193264IS: 
    194265  REDEEM_COINS_REJECT   #hex_string(number_of_coins) 
     
    202273                                                                Unknown target 
    203274                                                                        Note: Can be used if Mint requires request_id to already be awaiting minting 
     275        Prior:  REDEEM_COINS_REQUEST 
     276        Follow: Goodbye 
    204277 
    205278  REDEEM_COINS_ACCEPT 
     279        Prior:  REDEEM_COINS_REQUEST 
     280        Follow: Goodbye 
    206281 
    207282 
     
    225300                                                #key_identifier1 #encrypted_serial1 
    226301                                                #key_identifier2 #encrypted_serial2 
     302        Prior:  Hello 
     303        Follow: LOCK_COINS_ACCEPT 
     304                        LOCK_COINS_FAILURE 
    227305 
    228306DSDB: 
    229307  LOCK_COINS_ACCEPT             #hex_string(transaction_id) TIME(lock_expires) 
     308        Prior:  LOCK_COINS_REQUEST 
     309        Follow: Goodbye 
    230310 
    231311  LOCK_COINS_FAILURE    #hex_sting(transaction_id) #hex_string(number_of_failures) 
     
    238318                                                                Serial already redeemed                                         Permanant 
    239319                                                                Serial locked (not spent)                                       Temporary 
     320        Prior:  LOCK_COINS_REQUEST 
     321        Follow: Goodbye 
    240322 
    241323 
     
    246328Wallet: 
    247329  UNLOCK_COINS_REQUEST  #hex_string(transaction_id) 
     330        Prior:  Hello 
     331        Follow: UNLOCK_COINS_PASS 
     332                        UNLOCK_COINS_FAILURE 
    248333 
    249334DSDB: 
    250335  UNLOCK_COINS_PASS 
     336        Prior:  UNLOCK_COINS_REQUEST 
     337        Follow: Goodbye 
     338         
    251339  UNLOCK_COINS_FAILURE  #hex_string(transaction_id) "Reason" 
    252340                                                        Reasons: 
     
    254342                                                                Transaction already completed 
    255343                                                                Lock expired *Not really a failure...* 
    256  
    257  
    258  
     344        Prior:  UNLOCK_COINS_REQUEST 
     345        Follow: Goodbye 
     346 
     347 
     348 
     349 
  • trunk/standards/messages/wallet.to.wallet.txt

    r15 r18  
    1515                                blank1 
    1616                                blank2 
     17                Prior:  Hello 
     18                Follow: BLANK_FAILURE 
     19                                BLANK_REJECT 
     20                                BLANK_ACCEPT 
    1721 
    1822B: 
     
    2428                                                Unknown issuer 
    2529                                                        Note: Also used for an untrusted issuer 
     30                Prior:  BLANK_PRESENT 
     31                Follow: Goodbye 
    2632                                                 
    2733  BLANK_FAILURE #hex_string(0) "reason" 
    2834                                        Reason: 
    2935                                                Cancelled 
     36                Prior:  BLANK_PRESENT 
     37                Follow: Goodbye 
    3038                                                 
    3139 
     
    3947                                                DSDB: Serial already redeemed                                   Permanant 
    4048                                                DSDB: Serial locked (not spent)                                 Temporary 
     49                Prior:  BLANK_PRESENT 
     50                Follow: Goodbye 
    4151 
    4252  BLANK_REJECT  #hex_string(0) "reason" 
    4353                                        Reasons: 
    4454                                                Cancelled 
     55                Prior:  BLANK_PRESENT 
     56                                BLANK_ACCEPT (Message from self) 
     57                Follow: Goodbye 
    4558 
    4659  BLANK_ACCEPT 
    47          Note: After ACCEPT, a REJECT #hex_string(0) can be given to abort the transaction 
     60                Note:   After ACCEPT, a REJECT #hex_string(0) can be given to abort the transaction 
     61                Prior:  BLANK_PRESENT 
     62                Follow: COINS_REDEEM 
     63                                BLANK_REJECT (Message from self) 
    4864 
    4965 
     
    5672                                #base64(coin1) 
    5773                                #base64(coin2) 
     74                Prior:  BLANK_ACCEPT 
     75                Follow: COINS_REJECT 
     76                                COINS_ACCEPT 
    5877 
    5978B: 
     
    6584                                                Unknown coin 
    6685                                                        Note: Used when the coin we are given is different than the blank 
     86                Prior:  COINS_REDEEM 
     87                Follow: COINS_REDEEM 
     88                                Goodbye 
    6789 
    6890  COINS_REJECT  #hex_string(0) "Reason" 
    6991                                        Reasons: 
    7092                                                *I can't think of anything valid* 
     93                Prior:  COINS_REDEEM 
     94                Follow: COINS_REDEEM 
     95                                Goodbye 
    7196 
    7297  COINS_ACCEPT 
     98                Prior:  COINS_REDEEM 
     99                Follow: Goodbye