OpenCoverage

ec_oct.c

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/libressl/src/crypto/ec/ec_oct.c
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6int-
7EC_POINT_set_compressed_coordinates_GFp(const EC_GROUP * group, EC_POINT * point,-
8 const BIGNUM * x, int y_bit, BN_CTX * ctx)-
9{-
10 if (group->meth->point_set_compressed_coordinates == 0
group->meth->p...ordinates == 0Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • ectest
FALSEnever evaluated
0-7
11 && !(group->meth->flags & 0x1)
!(group->meth->flags & 0x1)Description
TRUEnever evaluated
FALSEevaluated 7 times by 1 test
Evaluated by:
  • ectest
) {
0-7
12 ERR_put_error(16,(0xfff),((2|64)),__FILE__,79);-
13 return
never executed: return 0;
0;
never executed: return 0;
0
14 }-
15 if (group->meth != point->meth
group->meth != point->methDescription
TRUEnever evaluated
FALSEevaluated 7 times by 1 test
Evaluated by:
  • ectest
) {
0-7
16 ERR_put_error(16,(0xfff),(101),__FILE__,83);-
17 return
never executed: return 0;
0;
never executed: return 0;
0
18 }-
19 if (group->meth->flags & 0x1
group->meth->flags & 0x1Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • ectest
FALSEnever evaluated
) {
0-7
20 if (group->meth->field_type == 406
group->meth->field_type == 406Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • ectest
FALSEnever evaluated
)
0-7
21 return
executed 7 times by 1 test: return ec_GFp_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
Executed by:
  • ectest
ec_GFp_simple_set_compressed_coordinates(
executed 7 times by 1 test: return ec_GFp_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
Executed by:
  • ectest
7
22 group, point, x, y_bit, ctx);
executed 7 times by 1 test: return ec_GFp_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
Executed by:
  • ectest
7
23 else-
24-
25-
26-
27-
28-
29-
30 return
never executed: return ec_GF2m_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
ec_GF2m_simple_set_compressed_coordinates(
never executed: return ec_GF2m_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
0
31 group, point, x, y_bit, ctx);
never executed: return ec_GF2m_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
0
32-
33 }-
34 return
never executed: return group->meth->point_set_compressed_coordinates(group, point, x, y_bit, ctx);
group->meth->point_set_compressed_coordinates(group, point, x, y_bit, ctx);
never executed: return group->meth->point_set_compressed_coordinates(group, point, x, y_bit, ctx);
0
35}-
36-
37-
38int-
39EC_POINT_set_compressed_coordinates_GF2m(const EC_GROUP * group, EC_POINT * point,-
40 const BIGNUM * x, int y_bit, BN_CTX * ctx)-
41{-
42 if (group->meth->point_set_compressed_coordinates == 0
group->meth->p...ordinates == 0Description
TRUEnever evaluated
FALSEnever evaluated
0
43 && !(group->meth->flags & 0x1)
!(group->meth->flags & 0x1)Description
TRUEnever evaluated
FALSEnever evaluated
) {
0
44 ERR_put_error(16,(0xfff),((2|64)),__FILE__,111);-
45 return
never executed: return 0;
0;
never executed: return 0;
0
46 }-
47 if (group->meth != point->meth
group->meth != point->methDescription
TRUEnever evaluated
FALSEnever evaluated
) {
0
48 ERR_put_error(16,(0xfff),(101),__FILE__,115);-
49 return
never executed: return 0;
0;
never executed: return 0;
0
50 }-
51 if (group->meth->flags & 0x1
group->meth->flags & 0x1Description
TRUEnever evaluated
FALSEnever evaluated
) {
0
52 if (group->meth->field_type == 406
group->meth->field_type == 406Description
TRUEnever evaluated
FALSEnever evaluated
)
0
53 return
never executed: return ec_GFp_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
ec_GFp_simple_set_compressed_coordinates(
never executed: return ec_GFp_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
0
54 group, point, x, y_bit, ctx);
never executed: return ec_GFp_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
0
55 else-
56 return
never executed: return ec_GF2m_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
ec_GF2m_simple_set_compressed_coordinates(
never executed: return ec_GF2m_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
0
57 group, point, x, y_bit, ctx);
never executed: return ec_GF2m_simple_set_compressed_coordinates( group, point, x, y_bit, ctx);
0
58 }-
59 return
never executed: return group->meth->point_set_compressed_coordinates(group, point, x, y_bit, ctx);
group->meth->point_set_compressed_coordinates(group, point, x, y_bit, ctx);
never executed: return group->meth->point_set_compressed_coordinates(group, point, x, y_bit, ctx);
0
60}-
61-
62-
63size_t-
64EC_POINT_point2oct(const EC_GROUP *group, const EC_POINT *point,-
65 point_conversion_form_t form,-
66 unsigned char *buf, size_t len, BN_CTX *ctx)-
67{-
68 if (group->meth->point2oct == 0
group->meth->point2oct == 0Description
TRUEevaluated 96 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
FALSEnever evaluated
0-96
69 && !(group->meth->flags & 0x1)
!(group->meth->flags & 0x1)Description
TRUEnever evaluated
FALSEevaluated 96 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
) {
0-96
70 ERR_put_error(16,(0xfff),((2|64)),__FILE__,137);-
71 return
never executed: return 0;
0;
never executed: return 0;
0
72 }-
73 if (group->meth != point->meth
group->meth != point->methDescription
TRUEnever evaluated
FALSEevaluated 96 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
) {
0-96
74 ERR_put_error(16,(0xfff),(101),__FILE__,141);-
75 return
never executed: return 0;
0;
never executed: return 0;
0
76 }-
77 if (group->meth->flags & 0x1
group->meth->flags & 0x1Description
TRUEevaluated 96 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
FALSEnever evaluated
) {
0-96
78 if (group->meth->field_type == 406
group->meth->field_type == 406Description
TRUEevaluated 95 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
FALSEevaluated 1 time by 1 test
Evaluated by:
  • ectest
)
1-95
79 return
executed 95 times by 2 tests: return ec_GFp_simple_point2oct(group, point, form, buf, len, ctx);
Executed by:
  • ectest
  • ssltest
ec_GFp_simple_point2oct(group, point,
executed 95 times by 2 tests: return ec_GFp_simple_point2oct(group, point, form, buf, len, ctx);
Executed by:
  • ectest
  • ssltest
95
80 form, buf, len, ctx);
executed 95 times by 2 tests: return ec_GFp_simple_point2oct(group, point, form, buf, len, ctx);
Executed by:
  • ectest
  • ssltest
95
81 else-
82-
83-
84-
85-
86-
87-
88 return
executed 1 time by 1 test: return ec_GF2m_simple_point2oct(group, point, form, buf, len, ctx);
Executed by:
  • ectest
ec_GF2m_simple_point2oct(group, point,
executed 1 time by 1 test: return ec_GF2m_simple_point2oct(group, point, form, buf, len, ctx);
Executed by:
  • ectest
1
89 form, buf, len, ctx);
executed 1 time by 1 test: return ec_GF2m_simple_point2oct(group, point, form, buf, len, ctx);
Executed by:
  • ectest
1
90-
91 }-
92 return
never executed: return group->meth->point2oct(group, point, form, buf, len, ctx);
group->meth->point2oct(group, point, form, buf, len, ctx);
never executed: return group->meth->point2oct(group, point, form, buf, len, ctx);
0
93}-
94-
95-
96int-
97EC_POINT_oct2point(const EC_GROUP *group, EC_POINT *point,-
98 const unsigned char *buf, size_t len, BN_CTX *ctx)-
99{-
100 if (group->meth->oct2point == 0
group->meth->oct2point == 0Description
TRUEevaluated 52 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
FALSEnever evaluated
&&
0-52
101 !(group->meth->flags & 0x1)
!(group->meth->flags & 0x1)Description
TRUEnever evaluated
FALSEevaluated 52 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
) {
0-52
102 ERR_put_error(16,(0xfff),((2|64)),__FILE__,169);-
103 return
never executed: return 0;
0;
never executed: return 0;
0
104 }-
105 if (group->meth != point->meth
group->meth != point->methDescription
TRUEnever evaluated
FALSEevaluated 52 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
) {
0-52
106 ERR_put_error(16,(0xfff),(101),__FILE__,173);-
107 return
never executed: return 0;
0;
never executed: return 0;
0
108 }-
109 if (group->meth->flags & 0x1
group->meth->flags & 0x1Description
TRUEevaluated 52 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
FALSEnever evaluated
) {
0-52
110 if (group->meth->field_type == 406
group->meth->field_type == 406Description
TRUEevaluated 50 times by 2 tests
Evaluated by:
  • ectest
  • ssltest
FALSEevaluated 2 times by 1 test
Evaluated by:
  • ectest
)
2-50
111 return
executed 50 times by 2 tests: return ec_GFp_simple_oct2point(group, point, buf, len, ctx);
Executed by:
  • ectest
  • ssltest
ec_GFp_simple_oct2point(group, point,
executed 50 times by 2 tests: return ec_GFp_simple_oct2point(group, point, buf, len, ctx);
Executed by:
  • ectest
  • ssltest
50
112 buf, len, ctx);
executed 50 times by 2 tests: return ec_GFp_simple_oct2point(group, point, buf, len, ctx);
Executed by:
  • ectest
  • ssltest
50
113 else-
114-
115-
116-
117-
118-
119-
120 return
executed 2 times by 1 test: return ec_GF2m_simple_oct2point(group, point, buf, len, ctx);
Executed by:
  • ectest
ec_GF2m_simple_oct2point(group, point,
executed 2 times by 1 test: return ec_GF2m_simple_oct2point(group, point, buf, len, ctx);
Executed by:
  • ectest
2
121 buf, len, ctx);
executed 2 times by 1 test: return ec_GF2m_simple_oct2point(group, point, buf, len, ctx);
Executed by:
  • ectest
2
122-
123 }-
124 return
never executed: return group->meth->oct2point(group, point, buf, len, ctx);
group->meth->oct2point(group, point, buf, len, ctx);
never executed: return group->meth->oct2point(group, point, buf, len, ctx);
0
125}-
Switch to Source codePreprocessed file

Generated by Squish Coco 4.2.2