summaryrefslogtreecommitdiff
path: root/p11p-daemon/src/p11p_rpc.hrl
blob: 8ccb0d12598688afdd39f4039aebfb18f001f00b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
%%% Copyright (c) 2019, Sunet.
%%% See LICENSE for licensing information.

-record(p11rpc_msg, {
	  call_code = -1 :: integer(),		% Length is 4
	  opt_len = -1 :: integer(),		% Length is 4
	  data_len = -1 :: integer(),		% Length is 4

	  options = <<>> :: binary(),	    % Length is header.opt_len
	  data = <<>> :: binary(),	    % Length is header.buf_len

	  buffer = <<>> :: binary(),
	  state = header :: header | opts | data | done
	 }).
-type p11rpc_msg() :: #p11rpc_msg{}.