Technical Specification Corporate Data
Technical Specification Corporate Data
Version: 2.4
Date: 19 December 2024
Non-Confidential
Corporate Data Multicast Specification
COPYRIGHT NOTICE
2
Corporate Data Multicast Specification
Revision History
3
Corporate Data Multicast Specification
Table of Contents
1. Introduction .......................................................................................................... 6
4
Corporate Data Multicast Specification
8 Annexure-1 ........................................................................................................... 50
10 Notes ................................................................................................................. 61
5
Corporate Data Multicast Specification
1. Introduction
NSE Data & Analytics Ltd. disseminates NSEIL’s real time broadcast data to
various information agencies. It provides 7 different types of data products viz.
The realtime data and corporate data is a packet broadcast available for
dissemination through feed, whereas the snapshot data, end of day data and
historical data is available in the form of files. All these data products come
under Infofeed application.
INFOFEED
(Level 3)
(CM) 15 Minute
Delayed
Index Feed Snapshot
(CM/FO/NSE IX)
MTBT Feed
(CM/CD/NSE IX) One-day
Delayed
Feed
Analytical Feed (CM/FO/CD)
(CM/FO)
6
Corporate Data Multicast Specification
This document explains about the NSE – Market Feed (FO Level 1 & Level 2)
products. Through this product on real time basis all the NSE’s market update
information is disseminated.
The information agencies connect to the Market Feed Server through Leased Lines.
These leased lines are terminated on Infofeed Router and their data specific
pneumonic calls are forwarded to Infofeed server.
The feed consists of series of sequenced and unsequenced variable length
compressed messages. The compression algorithm used over here is LZO –
Compression.
7
Corporate Data Multicast Specification
2. Connection Details
Compressed/Uncompressed:
This field tells whether packet is compressed or not compressed.
Number of Records:
This field tells the number of records present in the compressed packets.
Packet length:
This field specifies the total packet length.
Structure COM_HEADER
{
char cCompOrNot;
short iPackLen;
short iNoOfPack;
};
8
Corporate Data Multicast Specification
9
Corporate Data Multicast Specification
10
Corporate Data Multicast Specification
3. Data Details
The real time data is disseminated in the form of multicast packets and each
single packet is generated by the application with a definite structure i.e.
Header, Data body and Trailer.
The Header
The header in turn consists of 3 fields – Code, Length and Sequence number.
The details of these fields are explained as below.
• Code – It is a short data type field that provides the information about
the type of data that each packet contains.
• Length – It is a 2-byte short data type field that provides the length
of record within each packet of NSEIL real time data. This includes the
length of Header, Data and Trailer.
• Sequence Number – It is a 4-byte ASCII field that provides the
sequence number of each packet that is disseminated in NSEIL real
time data. Corporate Announcement, Company Result and Distribution
Schedule packets maintain its own sequence number. All the three
sequence numbers will start from 1 every day. When there is no data
to disseminate, application will send the heartbeat signal. Heartbeat
sequence number is also maintained separately.
The Trailer
• Trailer contains a 2-byte checksum and an end of trailer character.
• Checksum is calculated using the algorithm given in section Checksum
Calculation
• End of trailer character is ‘\r’.
11
Corporate Data Multicast Specification
Corporate Announcement & Quick Result packet will be sent by the application as
and when any announcement or quick result is published by the Exchange.
Announcement date
CA Date CHAR [13] Character
(DDMMYYYYHHmm)
CA Attachment File
CHAR [200] Character Attachment filename
Name
INFO TRAILER
Refer section Checksum
Checksum SHORT Numeric
Calculation
Corresponding Attachment file shall be available over SFTP. Please refer section
About SFTP for information on SFTP Protocol.
12
Corporate Data Multicast Specification
COMP HEADER
‘0’ = Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
Number of Packets *Size of (Info
Packet Length SHORT Numeric
Header+ Data+ Info Trailer)
Number of Packets SHORT Numeric Number of records
INFO HEADER
DATA
‘B’ – Banking,
Category CHAR [1] Character ‘N’ - Nonbanking,
‘A’ - Alternative
Result Period To
To Date CHAR [11] Character
[YYYY-MM-DD]
13
Corporate Data Multicast Specification
Audited (A),
Unaudited(U),
Result Type CHAR [3] Character
Project Status
Report
“Q1” = Quarter 1,
“Q2” =Quarter 2,
“Q3” =Quarter 3,
Period Type CHAR [3] Character “Q4” =Quarter 4,
“H1” =Half Yearly,
“AN” =Annual,
“OT” =Others
14
Corporate Data Multicast Specification
Non-promoter
FLOAT Numeric Non-promoter shareholding (%)
shareholding (%)
Interest/discount on Interest/discount on
DOUBLE Numeric
advances/bills advances/bills
Income on Income on
DOUBLE Numeric
Investments Investments
15
Corporate Data Multicast Specification
Provisions (Other
Provisions (Other than Tax) &
than Tax) & DOUBLE Numeric
Contingencies
Contingencies
Operating Profit
0 If Result Is Banking or Non-
before interest and DOUBLE Numeric
Banking
depreciation
General
0 If Result Is Banking or Non-
Administrative DOUBLE Numeric
Banking
Expenses
‘V’ = Revision,
‘F’ = Refilling,
FRF Flag CHAR [1] Character
‘G’ = Regrouping,
‘N’ = None (No Change)
16
Corporate Data Multicast Specification
For Revision/Refilling/Re
Result Create Date CHAR [21] Character grouping "On Date" Format (DD-
MON- YYYY HH24:MI:SS)
Consolidated Net
Consolidated Net Profit (+)/Loss
Profit (+)/Loss (-) for DOUBLE Numeric
(-) for the Period
the Period
Operating Profit
DOUBLE Numeric Operating Profit before Interest
before Interest
17
Corporate Data Multicast Specification
Profits from
operations before Profits from operations before
Other Income, DOUBLE Numeric Other Income,
Interest & Interest & Exceptional Items
Exceptional Items
18
Corporate Data Multicast Specification
19
Corporate Data Multicast Specification
COMP HEADER
‘0’ = Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
Number of Packets *Size of
Packet Length SHORT Numeric (Info Header+ Data+ Info
Trailer)
INFO HEADER
DATA
Secondary Segment
CHAR [51] Character Secondary Segment Name
Name
Segment Value DOUBLE Numeric Segment Value
Field to be added or ‘A’ = Added,
CHAR [1] Character
subtracted ‘S’ = Subtracted
INFO TRAILER
Refer section 6. Checksum
Checksum SHORT Numeric
Calculation
20
Corporate Data Multicast Specification
COMP HEADER
‘0’ = Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
Number of Packets
Packet Length SHORT Numeric *Size of (Info Header+
Data+ Info Trailer)
INFO HEADER
DATA
Shareholder category
Particulars CHAR [101] Character
description
21
Corporate Data Multicast Specification
Promotor &
CHAR [11] Character Shareholder category type
Promotor Group
Non-Promotor Non-
CHAR [4] Character Shareholder category type
Public
INFO TRAILER
22
Corporate Data Multicast Specification
‘0’ = Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
Number of Packets
Packet Length SHORT Numeric *Size of (Info Header+
Data+ Info Trailer)
INFO HEADER
DATA
23
Corporate Data Multicast Specification
Depository Receipts
Total number of
LONG LONG Numeric Total number of shares held
shares held
Shareholding as a %
of total number of
shares (calculated as DOUBLE Numeric Total Share held percentage
per SCRR, 1957)
As a % of (A+B+C2)
Number of Voting
Number of Voting Rights held
Rights held in each
LONG LONG Numeric in each class of securities
class of securities
Class eg: X
Class eg: X
Number of Voting
Number of Voting Rights held
Rights held in each
LONG LONG Numeric in each class of securities
class of securities
Class eg: Y
Class eg: Y
Number of Voting
Number of Voting Rights held
Rights held in each
LONG LONG Numeric in each class of securities:
class of securities:
total
total
Number of Voting
Rights held in each Number of Voting Rights held
class of securities: DOUBLE Numeric in each class of securities:
Total as a % of Total as a % of (A+B+C)
(A+B+C)
Number of Shares
Number of Shares
Underlying
Underlying Outstanding
Outstanding LONG LONG Numeric
convertible securities
convertible securities
(including Warrants)
(including warrants)
Shareholding, as a
% assuming full
conversion of Shareholding, as a %
convertible assuming full conversion of
securities (as a DOUBLE Numeric convertible securities (as a
percentage of percentage of diluted share
diluted share capital) As a % of (A+B+C2)
capital) As a % of
(A+B+C2)
Number of Locked in
LONG LONG Numeric Number of Locked in shares
shares
Number of Locked in
Number of Locked in shares as
shares as a % of DOUBLE Numeric
a % of total Shares held
total Shares held
24
Corporate Data Multicast Specification
Number of Shares
Number of Shares pledged or
pledged or otherwise LONG LONG Numeric
otherwise encumbered
encumbered
Number of Shares
Number of Shares pledged or
pledged or otherwise
DOUBLE Numeric otherwise encumbered as a %
encumbered as a %
of total Shares held
of total Shares held
Number of equity
Number of equity shares held
shares held in LONG LONG Numeric
in dematerialized form
dematerialized form
INFO TRAILER
25
Corporate Data Multicast Specification
‘0’= Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
Number of Packets
Packet Length SHORT Numeric *Size of (Info Header+
Data+ Info Trailer)
Number of Packets SHORT Numeric Number of records
INFO HEADER
DATA
Number of
LONG LONG Numeric Number of shareholders
shareholders
26
Corporate Data Multicast Specification
Number of Partly
Number of Partly paid- up
paid-up equity shares LONG LONG Numeric
equity shares held
held
Number of shares
Number of shares underlying
underlying LONG LONG Numeric
Depository Receipts
Depository Receipts
Total number of
LONG LONG Numeric Total number of shares held
shares held
Shareholding as a %
of total number of
shares (calculated as DOUBLE Numeric Total Share held percentage
per SCRR, 1957) As a
% of (A+B+C2)
Number of Voting
Number of Voting Rights held in
Rights held in each
LONG LONG Numeric each class of securities
class of securities
Class eg: X
Class eg: X
Number of Voting
Number of Voting Rights held in
Rights held in each
LONG LONG Numeric each class of securities
class of securities
Class eg: Y
Class eg: Y
Number of Voting
Number of Voting Rights held in
Rights held in each
LONG LONG Numeric each class of securities:
class of securities:
total
total
Number of Voting
Number of Voting Rights held
Rights held in each
in each class of securities:
class of securities: DOUBLE Numeric
Total as a % of
Total as a % of
(A+B+C)
(A+B+C)
Number of Shares
Underlying Number of Shares
Outstanding Underlying Outstanding
LONG LONG Numeric
convertible securities convertible securities (including
(including Warrants)
Warrants)
Shareholding, as a %
assuming full Shareholding, as a % assuming
conversion of full conversion of convertible
convertible securities DOUBLE Numeric securities (as a percentage of
(as a percentage of diluted share capital) As a %
diluted share capital) of (A+B+C2)
As a % of (A+B+C2)
27
Corporate Data Multicast Specification
Number of Locked in
LONG LONG Numeric Number of Locked in shares
shares
Number of Locked in
Number of Locked in shares as
shares as a % of total DOUBLE Numeric
a % of total Shares held
Shares held
Number of Shares
Number of Shares pledged or
pledged or otherwise LONG LONG Numeric
otherwise encumbered
encumbered
Number of Shares
Number of Shares pledged or
pledged or otherwise
DOUBLE Numeric otherwise encumbered as a %
encumbered as a %
of total Shares held
of total Shares held
Number of equity
Number of equity shares held in
shares held in LONG LONG Numeric
dematerialized form
dematerialized form
Unique parent ID which is used
Parent ID LONG LONG Numeric
for mapping and aggregation.
INFO TRAILER
Refer section 6. Checksum
Checksum SHORT Numeric
Calculation
End Of Trailer CHAR [1] Character ‘\r’
Under Any Other Category in Category field, if subsequent packet has NULL field populated
under Category code, in this case a new Category of shareholder will be defined.
Subsequent packets will contain a unique Parent ID for mapping and aggregation of
shareholding details.
28
Corporate Data Multicast Specification
29
Corporate Data Multicast Specification
COMP HEADER
‘0’ = Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
Number of Packets
Packet Length SHORT Numeric *Size of (Info Header+ Data+
Info Trailer)
INFO HEADER
DATA
Number of
LONG LONG Numeric Number of shareholders
shareholders
30
Corporate Data Multicast Specification
Number of Partly
Number of Partly paid- up
paid-up equity LONG LONG Numeric
equity shares held
shares held
Number of shares
Number of shares underlying
underlying LONG LONG Numeric
Depository Receipts
Depository Receipts
Total number of
LONG LONG Numeric Total number of shares held
shares held
Shareholding as a %
of total number of
shares (Calculated as DOUBLE Numeric Total Share held percentage
per SCRR, 1957)
As a % of (A+B+C2)
Number of Voting
Number of Voting Rights held
Rights held in each
LONG LONG Numeric in each class of securities
class of securities
Class eg: X
Class eg: X
Number of Voting
Number of Voting Rights held
Rights held in each
LONG LONG Numeric in each class of securities
class of securities
Class eg: Y
Class eg: Y
Number of Voting
Number of Voting Rights held
Rights held in each
LONG LONG Numeric in each class of securities:
class of securities:
total
total
Number of Voting
Number of Voting Rights held
Rights held in each
in each class of securities:
class of securities: DOUBLE Numeric
Total as a % of
Total as a % of
(A+B+C)
(A+B+C)
Number of Shares
Number of Shares
Underlying
Underlying Outstanding
Outstanding
LONG LONG Numeric convertible securities
convertible securities
(including
(including
Warrants)
Warrants)
Shareholding, as a % Shareholding, as a %
assuming full assuming full conversion of
conversion of DOUBLE Numeric convertible securities (as a
convertible securities percentage of diluted share
(as a percentage of capital) As a % of
31
Corporate Data Multicast Specification
Number of Locked in
LONG LONG Numeric Number of Locked in shares
shares
Number of Locked in
Number of Locked in shares as
shares as a % of DOUBLE Numeric
a % of total Shares held
total Shares held
Number of Shares
Number of Shares pledged or
pledged or otherwise LONG LONG Numeric
otherwise encumbered
encumbered
Number of Shares
Number of Shares pledged or
pledged or otherwise
LONG LONG Numeric otherwise encumbered as a %
encumbered as a %
of total Shares held
of total Shares held
Number of equity
Number of equity shares held
shares held in LONG LONG Numeric
in dematerialized form
dematerialized form
INFO TRAILER
Under Any Other Category in Category field, if subsequent packet has NULL field populated
under Category code, in this case a new Category of shareholder will be defined.
Subsequent packets will contain a unique Parent ID for mapping and aggregation of
shareholding details.
32
Corporate Data Multicast Specification
COMP HEADER
‘0‘= Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
Number of Packets
Packet Length SHORT Numeric *Size of (Info Header+
Data+ Info Trailer)
INFO HEADER
DATA
33
Corporate Data Multicast Specification
Number of Partly
Number of Partly paid- up
paid-up equity LONG LONG Numeric
equity shares held
shares held
Number of shares
Number of shares underlying
underlying LONG LONG Numeric
Depository Receipts
Depository Receipts
Total number of
LONG LONG Numeric Total number of shares held
shares held
Shareholding as a %
of total number of
shares (Calculated as DOUBLE Numeric Total Share held percentage
per SCRR, 1957)
As a % of (A+B+C2)
Number of Voting
Number of Voting Rights held
Rights held in each
LONG LONG Numeric in each class of securities
class of securities
Class eg: X
Class eg: X
Number of Voting
Number of Voting Rights held
Rights held in each
LONG LONG Numeric in each class of securities
class of securities
Class eg: Y
Class eg: Y
Number of Voting
Number of Voting Rights held
Rights held in each
LONG LONG Numeric in each class of securities:
class of securities:
total
total
Number of Voting
Number of Voting Rights held
Rights held in each DOUBLE Numeric
in each class of securities:
class of securities:
Total as a % of Total as a % of
Numeric
(A+B+C) (A+B+C)
34
Corporate Data Multicast Specification
Number of Shares
Underlying Number of Shares
Outstanding Underlying Outstanding
LONG LONG Numeric
convertible securities convertible securities
(including (including Warrants)
Warrants)
Shareholding, as a
% assuming full
Shareholding, as a %
conversion of
assuming full conversion of
convertible
convertible securities (as a
securities (as a DOUBLE Numeric
percentage of diluted share
percentage of
capital) As a % of
diluted share
(A+B+C2)
capital) As a % of
(A+B+C2)
Number of Locked in
LONG LONG Numeric Number of Locked in shares
shares
Number of Locked in
Number of Locked in shares as
shares as a % of DOUBLE Numeric
a % of total Shares held
total Shares held
Number of Shares
Number of Shares pledged or
pledged or otherwise LONG LONG Numeric
otherwise encumbered
encumbered
Number of Shares
Number of Shares pledged or
pledged or otherwise
DOUBLE Numeric otherwise encumbered as a %
encumbered as a %
of total Shares held
of total Shares held
Number of equity
Number of equity shares held
shares held in LONG LONG Numeric
in dematerialized form
dematerialized form
Unique parent ID which is
Parent ID LONG LONG Numeric used for mapping and
aggregation.
INFO TRAILER
Refer section 6. Checksum
Checksum SHORT Numeric
Calculation
End Of Trailer CHAR [1] Character ‘\r’
Under Any Other Category in Category field, if subsequent packet has NULL field
populated under Category code, in this case a new Category of shareholder will be
defined. Subsequent packets will contain a unique Parent ID for mapping and
aggregation of shareholding details.
35
Corporate Data Multicast Specification
36
Corporate Data Multicast Specification
COMP HEADER
‘0’= Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
Number of Packets
Packet Length SHORT Numeric *Size of (Info Header+
Data+ Info Trailer)
INFO HEADER
DATA
Distribution Schedule
provided is recorded on this
As On Date CHAR [12] Character
date.Date in DD-MMM- YYYY
format
Number of
LONG LONG Numeric Number of shareholders
shareholders
Number of Shares
LONG LONG Numeric Number of shares held
held
37
Corporate Data Multicast Specification
INFO TRAILER
38
Corporate Data Multicast Specification
COMP HEADER
Number of Packets
Packet Length SHORT Numeric *Size of (Info Header+
Data+ Info Trailer)
INFO HEADER
DATA
Character
Symbol CHAR [11] Security symbol
Character
Security Name CHAR [151] Security Name
Character
Company Name CHAR [151] Company Name
Distribution Schedule
Character provided is recorded on this
As On Date CHAR [12]
date. Date in DD-MMM-
YYYY format
Character
Name of shareholder CHAR [301] Name of shareholder
Character
Name of PAC CHAR [301] Name of PAC
39
Corporate Data Multicast Specification
Number of
LONG LONG Numeric Number of shareholders
shareholders
Holding % DOUBLE Numeric Holding %
INFO TRAILER
40
Corporate Data Multicast Specification
COMP HEADER
‘0’= Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
Number of Packets
Packet Length SHORT Numeric *Size of (Info Header+
Data+ Info Trailer))
Number of Packets SHORT Numeric Number of records
INFO HEADER
DATA
41
Corporate Data Multicast Specification
Distribution Schedule
provided is recorded on
As On Date CHAR [12] Character
this date. Date in DD-
MMM-YYYY format
Number of
LONG LONG Numeric Number of shareholders
shareholders
Number of Shares
LONG LONG Numeric Number of Shares held
held
INFO TRAILER
42
Corporate Data Multicast Specification
This packet will indicate that the online feed dissemination is complete and
offline data dissemination will start.
COM HEADER
‘0’ = Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
INFO HEADER
DATA
Not associated with any data.
INFO TRAILER
43
Corporate Data Multicast Specification
44
Corporate Data Multicast Specification
The Heartbeat packets are sent throughout the day from 02:00 to 22:30 (IST)
This packet indicates to the Info-Vendors that data packets are received from the
application. A separate sequence number will be maintained for Heartbeat signal.
COM HEADER
‘0’ = Compressed,
Compressed or not CHAR [1] Character
‘1’ = Uncompressed
INFO HEADER
Heartbeat packet
Sequence Number LONG Numeric
sequence number
DATA
Not associated with any ASCII data.
INFO TRAILER
45
Corporate Data Multicast Specification
The LZO stands for Lempel Ziv Oberhaumer. It is a data compression library which
is suitable for data Decompression in real-time. This means it favors speed over
compression ratio.
LZO is written in ANSI C. Both the source code and the compressed data format
are designed to be portable across platforms. This algorithm is freely available on
the internet (URL: https://www.oberhumer.com/opensource/lzo/). It is made
available by free software foundation. The algorithm is tested on various operating
systems like UNIX and Red Hat Linux.
Decompression steps:
46
Corporate Data Multicast Specification
IpLength: The length of the packet which application has received using
Receive ().
COutputBuf: The uncompressed output data which is result of
decompression.
OpLength: Length of uncompressed data
7. After decompression data will be available in Output Buffer.
8. Map the outputbuf to existing Header structure according to iCode field
available in header structure.
9. Look for Record size in the length field and Code.
10.Steps to recover data from OutputBuf is as follows.
Algorithm:
Length_of_Record = Header->length;
Sequence_no = Header->Sequence_num;
For I = 0 to Number of records (obtained in step 4)
Begin
Bytes_to_seek = Length_of_Record * I
Seek to number of Bytes_to_seek
Map (Length_of_Record) of Bytes to proper structure according to iCode
as found in Header part.
Do the required processing….
….
End
End for Loop.
47
Corporate Data Multicast Specification
6 Checksum Calculation
uData = *(cData+i);
uData <<= 8;
for(j=8;j>0;j--){
if((uData^uAccum)&0x8000)
uAccum=(uAccum<<1)^POLY;
/* SHIFT AND SUBTRACT POLY */
else
uAccum<<=1;
uData<<=1;
}
}
ucChk[0] = uAccum>>8;
if (ucChk[0] == DC1 || ucChk[0] == DC3 || ucChk[0] == CR || ucChk[0] ==
LF )
ucChk[0] -= 1;
ucChk[1] = uAccum&0xFF;
if (ucChk[1] == DC1 || ucChk[1] == DC3 || ucChk[1] == CR || ucChk[1]
== LF )
ucChk[1] -= 1;
uAccum = ucChk[1];
uAccum = (uAccum<<8) + ucChk[0];
return(uAccum);
}
48
Corporate Data Multicast Specification
lzo_decomp (char cInputBuf [], unsigned int ipLength, char cOutputBuf [],
unsigned *opLength, unsigned short * lzo_errorcode)
{
int r;
char mess [50];
r = lzo1z_decompress ((unsigned char *) cInputBuf, ipLength,
(unsigned char *) cOutputBuf, opLength, NULL);
if ( r == LZO_E_OK)
{
print (mess,” Decompressed %lu Bytes back into %lu Bytes\n",
(long) ipLength, (long) *opLength); return true;
}
else
49
Corporate Data Multicast Specification
8 Annexure-1
50
Corporate Data Multicast Specification
51
Corporate Data Multicast Specification
52
Corporate Data Multicast Specification
38 a) Public Non-institutions
shareholding
53
Corporate Data Multicast Specification
regulations,201
4)
54
Corporate Data Multicast Specification
The file transfer takes place over SFTP (Secure FTP) protocol over the Internet.
The Info Vendor requires to provide the Exchange with the SSH RSA Public Key
of their machine for receiving login details form the Exchange.
The following details will be provided once the request is processed by the
Exchange:
• Server IP
• SSH Service Port
• User ID
• File Path
General information on SFTP has been provided in the following sections for
popular OS platforms.
The OpenSSH suite, which comes pre-installed in most Linux distributions, can
be used for transferring files securely using SFTP.
The SSH key-pair is generally generated in the “.ssh” directory in the user’s
home directory.
55
Corporate Data Multicast Specification
• If a file already exists with the same name, then you will receive
the following prompt:
/host/users/user/.ssh/id_rsa already exists.
Overwrite (y/n)?
Type “y” and press Enter to overwrite.
After generating public key, user needs to share the Public Key file
with exchange for requesting the credentials.
NOTE: In above steps the words “host” and “user” are used to represent the
hostname and username of the machine. This is used for demo
purpose only. The same will differ as per your server and usernames.
Login to the Exchange Server over SFTP using the following command:
sftp -o PORT=6010 remote_user@remote_host
You should get the SFTP prompt as below, upon successful login:
56
Corporate Data Multicast Specification
The SFTP “get” command may be used at the SFTP prompt for fetching the
files while logged into the host over SFTP.
The SFTP “bye” command may be used for terminating the session.
Help may be obtained with SFTP commands by typing the “help” command
at the SFTP prompt.
This guide explains how to generate the SSH RSA key-pair using the PuttyGen
application.
57
Corporate Data Multicast Specification
• After generating the key, you will be shown the screen below.
Keep the “Key passphrase” and “Confirm passphrase” as blank.
58
Corporate Data Multicast Specification
• Share this Public Key File (id_rsa.pub) with the Exchange when
requesting for SFTP credentials.
There are multiple SFTP Client Programs (paid for and free) available
for transferring files over SFTP.
One such software is WinSCP, available for free from the WinSCP
website. This program is intuitive, user friendly and can be used in
interactive mode (GUI) as well as from the command line (for
automation/batch processing).
59
Corporate Data Multicast Specification
Apart from the above guide, many of the online resources can be referred
on the World Wide Web for more information on how to set up and use
SFTP at the Client’s site on various OS platforms.
Note:
This “About SFTP” section is intended as a guide used to understand and
become familiarized with this transfer protocol. It may be noted that the
Exchange does not provide SFTP software or support for configuring and
using SFTP at Client site.
60
Corporate Data Multicast Specification
10 Notes
• All the character (i.e. Byte) array fields are terminated with ‘\0’.
• All the structures fields are packed at a boundary of 1 byte. This can
be done as shown below.
#pragma pack(1)
typedef struct
{ short iCode
…
}ST_INFO_HEADER;
#pragma pack()
Sample code for reversing the byte order of any multi-byte data type
field.
void Twiddle(char *buffer, int buffer_size)
{
char *twiddle_buffer;
int i;
/*allocate the buffer for twiddling bytes */
twiddle_buffer = (char* ) malloc(buffer_size);
/* copy the buffer into a temporary buffer for
twiddling.*/ memcpy(twiddle_buffer, buffer,
buffer_size);
/* reverse the bytes */
for( i=0; i < buffer_size; i++)
{
buffer[i] = twiddle_buffer[buffer_size -i -
1];
}
/* free the buffer after twiddling */
free(twiddle_buffer);
}
e.g. The code field in Info header structure is 1000.
Then its byte can be reversed by calling the above function as shown
below
61
Corporate Data Multicast Specification
11 Support Information
62