English

Error: 1021: Token has expired

Error Message

While implementing WS-Security as the authentication mechanism in accessing ArcWeb Services, the following error message may occur:

Error:   
1021: Token has expired

Cause

The clock on the client machine is not synchronized with the clock on the ArcWeb servers.

Solution or Workaround

Synchronize the clock on the client machine with standard time maintained by some Network Time Protocol (NTP) servers. The National Institute of Standards and Technology (NIST) maintains time servers.

Before Beginning...

  1. Check the time on your computer with the NIST WWV broadcast. Refer to the following technical article, How To: Verify the time on the computer with National Institute Standards and Technology for instructions.
  2. Review the information available at National Institute of Systems and Technology Internet Time Service.
  3. Select an NIST Internet Time Service (ITS) server that is closest to your location: Internet Time Service table.
  4. Continue the procedure by selecting the instructions below that pertain to your domain.

Computers with Windows 2000 or Windows XP in an enterprise network (domain)

  1. Contact your system administrator to verify if your machine is part of a domain; if so, no further action may be necessary because the computer clocks may automatically adjust for accurate time. Continue with the following steps if you maintain clocks for a network or if you are an individual within a network that needs very accurate time displayed on your computer.
  2. Open the command prompt by clicking Start > All Programs > Accessories > Command Prompt.
  3. Type the following command:
    net time /setsntp:{Server Address}
    'Server Address' is the selection you made in Step 3 above. For example: net time /setsntp:nist1-ny.glassey.com
  4. Restart the the Windows Time Service to affect change in the configuration.
    1. Open Start > All Programs > Control Panel > Administrative Tools > Services. Select 'Windows Time' service and open its properties dialog box by right-clicking on it.
    2. Click on Stop and then Start button to restart the service.
      Note:
      To return to the original configuration, use the following command: net time /setsntp
      
      To find out the external NTP server w32time service will use when it starts again, use the following command: net time /querysntp

Computers with Windows 2000 or Windows XP not in an enterprise network (domain)

  1. Open the Date & Time Control Panel by double-clicking on the time shown on the bottom right corner of your computer screen.
  2. Click the Internet Time tab.
  3. Check the box labeled: Automatically synchronize with an Internet time server.
  4. Type the server name you selected in Step 3 above into the box to the right of 'Server:'
  5. Click Update Now to ensure it is working properly.
  6. Click OK to confirm the configuration change.

Factors that affect the accuracy of NTP protocol

  • The distance between your computer and the NTP server
  • The load on your network
  • Firewalls or proxy servers settings

Try different ITS servers if any of these might be the problem.

Additionally, if the firewall or proxy server on the network might be the problem, check the UDP port 123. Windows Time Service uses UDP port 123 for incoming and outgoing traffic; it is possible that the traffic on port 123 is blocked. Contact a system administrator.

Related Information