Alex Ho <firstname.lastname@example.org>
Gary Ng <email@example.com>
National University of Singapore
Chang Huong Tan <firstname.lastname@example.org>
National Computer Board
Lawrence Loh <email@example.com>
Tin Wee Tan <firstname.lastname@example.org>
National University of Singapore
As Singapore begins to establish itself as a hub for electronic commerce, developing an Internet-based platform for real-time stock transactions will be a real possibility. Such an application will, in fact, open up a whole new dimension of financial market investments for individuals all across the world.
Currently, a project named StockNet is being jointly spearheaded by the National University of Singapore (Internet Research & Development Unit and Faculty of Business Administration) and the National Computer Board, Singapore. Anchored on the World Wide Web (WWW), StockNet will allow market participation through cyberspace. The application has been successfully tested using a delayed feed from a secondary source of stock prices for an Internet-based stock trading game. It is currently being tested with a live feed from the SES through an Internet-based stock trading game for evaluation of security, financial, and operational issues before it is considered for actual implementation by the authorities.
A real-time WWW application like StockNet faces many design issues in terms of access speed, authentication, security, handling of live data, and user-friendly interface. As an integrated system, StockNet consists of various components. A stock information feed server processes the raw live stock data into a stock information database. A Web server component will control user requests and generate information for users viewing and submitting transactions through the WWW. The whole application is housed in a secure environment which provides not only access to authorized and authenticated users, but also encryption of data and information for users' privacy.
All information, whether the up-to-date price information of stocks or the historical price series of a stock, is stored in the database server. Data structures are carefully designed to ensure the most efficient way for storing such information without duplication so that the database server will be able to search and organize data efficiently.
A range of security services are being built into StockNet. They include authentication, authorization, data confidentiality, data integrity, and nonrepudiation. User authentication is based on a hierarchical login and password challenge sequence for accessing different levels in the program. Identification of the StockNet server will be based on certificates issued from the Singapore Certification Authority. Data confidentiality is achieved through a secure channel (Secure Sockets Layer [SSL] protocol) to encrypt data for transmission. Data integrity is protected over a secure channel with public-key mechanisms for signing the contents. Nonrepudiation is being done through the logging of user access and activity, user-server dual-notification, and other mechanisms.
Keywords: stock transactions, electronic commerce, stock trading, online trading.
For the past year, Singapore has been building a platform to enable itself to become an electronic commerce hub. Aiming to be an intelligent island by the year 2000, it had embarked on numerous efforts to make electronic commerce a reality. By means of a joint research effort to explore a possible electronic commerce applications, the National Computer Board (NCB), the Internet Research & Development Unit (IRDU), and the Faculty of Business Administration (FBA) from the National University of Singapore (NUS) came out with a full-scale prototype for online stock trading on the Internet, via the WWW. A stock trading game was conducted for students from NUS and has proven to be successful. Further progress will be made at the end of the year when NCB tests this application on the Singapore ONE network, a test bed for Singapore to become an information hub, which involves more than 5000 users.
Online stock trading is not a new technology altogether and has been implemented in the United States as a commercial application on the Internet. This paper deals with one implementation of such an application and discusses the policy and legal issues in the context of Singapore.
The stock data is derived through a live data feed connected to the Stock Exchange of Singapore (SES). The connection is a modem connected to an NT stock feed processing server workstation for preprocessing of stock information before the information is broadcast over the network.
The modem accepts the stock data in raw format is specified by SES, at a baud rate of 9600 bits per second (bps). The stock feed processing server formats the stock information and propagates the information in the form of UDP packets onto the network.
Upon receiving the UDP packets containing the updated information, the database server will collect the information, reprocess the information, and stored it in the database. The database stores not only the stock information but also the players' profiles.
The Web server that houses the StockNet program accepts real-time stock data that is updated on the database. The program queries the database for relevant information, which is then formatted and presented to the users of StockNet. The database is a hub for live stock information, an online user information system, and a user portfolio storage system.
Authentication for using StockNet is based on both the client and the server. Server authentication enables the user to authenticate to the real StockNet server to prevent any fraud; at the same time it offers encryption of private data through channel encryption. The server will be able to authenticate the identity of the user on the basis of the user's certificate.
Server authentication is based on the server certificate of the StockNet server. One example below shows the type of certificate that the StockNet server is based on when the user tries to authenticate the StockNet server for the first time.
The certificate is an SSL certificate signed by the NCB. SSL will provide an encrypted channel for transportation of data to and from the server. The certificate is SSL version 2.0 and is based on an exportable RC-4 with 40 bit secret key encryption for usage in Singapore. However, it does not restrict StockNet from having a higher grade of encryption, with encryption techniques being developed outside of the United States. Thus it will provide higher security strength encryption key lengths. (An example is Apache SSL 128-bit, developed in the United Kingdom).
In the coming months, when Infrastructure for Electronic Identification (IEI) is completely set up, NCB will be the official certifying authority for Singapore. The official certificate will be signed by NCB and issued to StockNet for authenticity for the StockNet server.
The user authentication is based on a login password challenge sequence. The password authentication is done in the secure channel environment. The password will be compared to the password that has been encrypted and stored in the database.
Upon verifying the password from the user, the StockNet server will issue a cookie string to be accepted by the user. This cookie string will look like the following:
This cookie string will be stored in a database as the cookie that will subsequently authorize the user to navigate in StockNet. The cookie will be set in the user's environment variable once the user has a successful login. At the same time, the cookie will be stored in the user database with a time stamp on it. Whenever the user accesses Web pages in StockNet, the program will compare the user's environment cookie string with the one that the server has on the database to see it matches. The program will then check the local time for the user and the time stamp on the stored cookie. There is a time duration in which the cookie is valid. If the time duration is exceeded, the user will have to be prompted to login to StockNet again.
A user can open multiple copies of the WWW browser to access StockNet. In this case, there will be a number of cookies strings set in the user's environment. When the user accesses StockNet, the user's environment cookie string will be compared against all the valid cookie strings stored in the database of StockNet.
The setting up of IEI also includes issuing digital certificates for all users of StockNet. User requests such as buying or selling of stocks can be digitally signed by users using their private keys and authenticated by the StockNet server, which will contain all public keys of the users of StockNet.
Stock information can be retrieved by querying the stock database in which the database server has collected the information through the network that is broadcast by the NT server. Users can view up-to-date market summaries such as top five gainers, top five losers, and top five volume, as well as market indexes. They can also retrieve the latest stock information through the WWW. Users can view information on all stocks, arranged alphabetically by counter name, or input only the counter name in which they are interested.
The stock database is updated continuously for accurate monitoring via the modem connection from SES over which the information is being sent. The NT server will then pass the information to the database server. If the information is new, the database server will change the record of the current stock information.
The user can analyze the market using the system's stock charting and forecasting utilities. Three methods of analysis are presented here.
Moving average (MA) is an average of a prior number of daily prices plotted to smooth the jitters and fluctuations out of market data in order to demonstrate how a stock is trending. The number of prior days' prices used in calculating the MA determines whether the trend line depicts a short- or long-term trend. A short-term trend line typically uses the prior 14 to 21 days' closing prices, while a long-tern trend line might use the prices of up to 200 days. StockNet uses the prior 20 days' closing prices.
Relative strength index (RSI) is a momentum indicator that measures an equity's price relative to itself and its past performance. Therefore, it gives a better velocity reading than other indicators. RSI is less affected by sharp rises or drops in an equity's price performance. Thus, it filters out some of the "noise" in a security's trading activity.
RSI is based on the observation that a stock that is advancing will tend to close nearer to the high of the day than the low. The reverse is true for declining stocks. RSI is basically a formula which attempts to indicate where investors are in the declining or advancing stage.
Moving average convergence divergence (MACD), which represents the spread between a short-term and a longer-term moving average, is an oscillator, derived by dividing one moving average by another. It is computed using exponential moving averages (EMAs), not the simple moving average. The name of the indicator is derived from the fact that the shorter EMA is continually converging toward and diverging away from the longer EMA. MACD can be used for an infinite number of time periods, although the choice depends on the volatility of the market--the more volatile a market, the shorter the period of the EMAs. However, the original MACD uses a 12-day EMA and 25-day EMA.
In addition to these three analytical methods, users can download raw stock information in the form of ASCII text files. These files can be used in other charting software that users have, allowing the users to do extensive analysis. Users can also download such information to their computer to analyze stock trends off line in their own leisure time.
Users can set up and manage their own portfolio. Stocks kept in the portfolio are stored in tables that allow users to keep track of their stocks once they login. In addition, when the user buys certain stocks from the simulated stock transactional services, that counter will automatically be added in the user portfolio. Additional features such as features for calculating profit from stocks will allow users to keep track of stock value and enable them to transact the stocks they have when the stock market is good.
Users can trade as they do in the real stock market environment. When a user sends in a request for trading, the request will be queued. After a number of minutes, the request will be processed according to current stock prices. Brokerage fees, contract stamp, clearing fees, and goods and services tax (GST) are taken into account. The bill to the user will include all details on the administrative fees.
Singapore is a multiracial society which consists of Chinese, Malays, Indians, Eurasians, and other minority races. Although English is the main language used in Singapore, some users may not be proficient in English. Moreover, stock information in Singapore can be obtained in other languages in newspapers.
StockNet would eventually incorporate a multilingual capability feature to enable users to read different languages of stock names in addition to English without the use of additional programs. Users can view stock information in the language they prefer. Below is a screen showing Chinese characters of the Indices in Singapore being placed next to the English Indices name.
The StockNet application is currently an experimental pilot project housed in a IBM platform. If it is eventually implemented, it may deliver potential benefits as follows:
The project is an avenue to broaden the base of Internet users and to promote their familiarity with the network. StockNet has high potential because it is accessible worldwide to all Internet users. With Singapore's ongoing regionalization, Singaporeans overseas will be able to access information on the local stock market as well as carry out transactions.
Development of StockNet nurtures our national competence pertaining to the technical and business issues in Internet-based commerce (e.g., transaction handling, database structures, privacy, and security issues). Ultimately, electronic stock trading through the Internet is a step towards the realization of a national electronic commerce infrastructure in Singapore.
The project is an excellent computer-based vehicle to familiarize students with stock ownership and trading mechanics in an innovative and interactive manner. This complements the formal curriculum in the tertiary institutions. The project provides a life-long educational foundation for students to approach stock investments with an informed long-term perspective.
Given the widely accessible nature of the application, StockNet allows a larger participation level of the population in stock investment. This is consistent with our national intent to broaden the pool of individual share-owning citizens. In fact, the system is especially catered to the small investor with a relatively minor budget for investments, who may thus not secure the attention of brokers.