Subject | Re: [firebird-support] [FIREBIRD WIRE PROTOCOL] Documentation |
---|---|
Author | Mark Rotteveel |
Post date | 2015-02-25T17:19:02Z |
On 25-2-2015 17:45, sdnetwork@... [firebird-support] wrote:
firebird-support. The firebird-devel mailinglist is better suited for
these types of questions.
Firebird 2.5):
/* User identification data, if any, is of form:
<type> <length> <data>
where
type is a byte code
length is an unsigned byte containing length of data
data is 'type' specific
*/
const UCHAR CNCT_user = 1; // User name
const UCHAR CNCT_passwd = 2;
//const UCHAR CNCT_ppo = 3; // Apollo person, project, organization.
OBSOLETE.
const UCHAR CNCT_host = 4;
const UCHAR CNCT_group = 5; // Effective Unix group id
const UCHAR CNCT_user_verification = 6; // Attach/create using this
connection will use user verification
I am not sure why the .net provider doesn't have these constants.
guide, and the sources of Firebird itself, and sources of drivers like
Jaybird, the .net provider, etc.
Mark
--
Mark Rotteveel
> i try to implement a driver and i play with the wire protocol but i needQuestion about implementing the wirebird protocol are off-topic on
> help !
firebird-support. The firebird-devel mailinglist is better suited for
these types of questions.
> i have found this doc :Look at the protocol.h in the Firebird sources, it describes (in
> http://sourceforge.net/p/firebird/NETProvider/ci/3.1.1.0/tree/Documentation/FirebirdWireProtocol/
> => FirebirdWireProtocol.pdf
>
> For exemple the packet to send for a connect is :
>
> Int32 => Operation code (op_connect)
> Int32 => Operation code (op_attach)
> Int32 => Version (CONNECT_VERSION2)
> Int32 => Architecture type (Generic = 1)
> String => Database path
> Int32 => Protocol versions understood (1)
> Buffer => User identification
> Int32 => Protocol version (PROTOCOL_VERSION10)
> Int32 => Architecture type (Generic = 1)
> Int32 => Minimum type (2)
> Int32 => Maximum type (3)
> Int32 => Preference weight (2)
>
> the problem is that i don't find the doc that describe the buffer for
> user identification.
>
> i have take a look in the dotnet provider : and i found this :
>
> it is the code for the buffer
>
> user_id.WriteByte(1); => what is the 1 ?
> user_id.WriteByte((byte)user.Length);
> user_id.Write(user, 0, user.Length);
> // Host name
> user_id.WriteByte(4); => what is the 4 ?
> user_id.WriteByte((byte)host.Length);
> user_id.Write(host, 0, host.Length);
> // Attach/create using this connection will use user verification
> user_id.WriteByte(6); => what is the 6 ?
> user_id.WriteByte(0); => what is the 0 ?
Firebird 2.5):
/* User identification data, if any, is of form:
<type> <length> <data>
where
type is a byte code
length is an unsigned byte containing length of data
data is 'type' specific
*/
const UCHAR CNCT_user = 1; // User name
const UCHAR CNCT_passwd = 2;
//const UCHAR CNCT_ppo = 3; // Apollo person, project, organization.
OBSOLETE.
const UCHAR CNCT_host = 4;
const UCHAR CNCT_group = 5; // Effective Unix group id
const UCHAR CNCT_user_verification = 6; // Attach/create using this
connection will use user verification
I am not sure why the .net provider doesn't have these constants.
> more globally how i can found the description of this buffer ? and doAs documentation there is only that document, the Interbase 6.0 API
> you know a more detailed documentation about the wire protocol ?
guide, and the sources of Firebird itself, and sources of drivers like
Jaybird, the .net provider, etc.
Mark
--
Mark Rotteveel