• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

libbitcoin / libbitcoin-server / 44845974736

21 Nov 2026 12:45AM UTC coverage: 95.044% (-0.1%) from 95.15%
44845974736

push

github

web-flow
Merge pull request #1200 from evoskuil/master

btcd cleanup, return bad target on versioned native/admin fail to parse.

49 of 66 new or added lines in 8 files covered. (74.24%)

14 existing lines in 4 files now uncovered.

12829 of 13498 relevant lines covered (95.04%)

451.12 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

96.44
/src/protocols/native/protocol_native_block.cpp
1
/**
2
 * Copyright (c) 2011-2026 libbitcoin developers
3
 *
4
 * This file is part of libbitcoin.
5
 *
6
 * This program is free software: you can redistribute it and/or modify
7
 * it under the terms of the GNU Affero General Public License as published by
8
 * the Free Software Foundation, either version 3 of the License, or
9
 * (at your option) any later version.
10
 *
11
 * This program is distributed in the hope that it will be useful,
12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
 * GNU Affero General Public License for more details.
15
 *
16
 * You should have received a copy of the GNU Affero General Public License
17
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
18
 */
19
#include <bitcoin/server/protocols/protocol_native.hpp>
20

21
#include <atomic>
22
#include <optional>
23
#include <ranges>
24
#include <bitcoin/server/define.hpp>
25

26
namespace libbitcoin {
27
namespace server {
28

29
using namespace system;
30
using namespace network::messages::peer;
31

32
BC_PUSH_WARNING(NO_INCOMPLETE_SWITCH)
33
BC_PUSH_WARNING(NO_THROW_IN_NOEXCEPT)
34

35
bool protocol_native::handle_get_top(const code& ec, interface::top,
313 ✔
36
    uint8_t, uint8_t media) NOEXCEPT
37
{
38
    if (stopped(ec))
313 ✔
39
        return false;
40

41
    switch (media)
31 ✔
42
    {
43
        case data:
7 ✔
44
            send_chunk(to_tops());
7 ✔
45
            return true;
7 ✔
46
        case text:
5 ✔
47
            send_text(encode_base16(to_tops()));
5 ✔
48
            return true;
5 ✔
49
        case json:
19 ✔
50
            send_json(to_tops_json());
19 ✔
51
            return true;
19 ✔
52
    }
53

54
    send_not_found();
×
55
    return true;
×
56
}
57

58
bool protocol_native::handle_get_top_subscribe(const code& ec,
293 ✔
59
    interface::top_subscribe, uint8_t version, uint8_t media,
60
    bool stop) NOEXCEPT
61
{
62
    if (stopped(ec))
293 ✔
63
        return false;
64

65
    const auto value = stop ? media_type::unknown : (media_type)media;
11 ✔
66
    top_subscribe_.store(value, std::memory_order_relaxed);
11 ✔
67
    if (stop)
11 ✔
68
    {
69
        send_empty();
1 ✔
70
        return true;
1 ✔
71
    }
72

73
    return handle_get_top(ec, {}, version, media);
10 ✔
74
}
75

76
bool protocol_native::handle_get_top_chain(const code& ec,
287 ✔
77
    interface::top_chain, uint8_t, uint8_t media, bool candidate) NOEXCEPT
78
{
79
    if (stopped(ec))
287 ✔
80
        return false;
81

82
    switch (media)
5 ✔
83
    {
84
        case data:
1 ✔
85
            send_chunk(to_top(candidate));
1 ✔
86
            return true;
1 ✔
87
        case text:
1 ✔
88
            send_text(encode_base16(to_top(candidate)));
1 ✔
89
            return true;
1 ✔
90
        case json:
3 ✔
91
            send_json(to_top_json(candidate));
3 ✔
92
            return true;
3 ✔
93
    }
94

95
    send_not_found();
×
96
    return true;
×
97
}
98

99
bool protocol_native::handle_get_top_height(const code& ec,
287 ✔
100
    interface::top_height, uint8_t, uint8_t media, bool candidate) NOEXCEPT
101
{
102
    if (stopped(ec))
287 ✔
103
        return false;
104

105
    const auto& query = archive();
5 ✔
106
    const auto height = possible_narrow_cast<uint32_t>(candidate ?
5 ✔
107
        query.get_top_candidate() : query.get_top_confirmed());
5 ✔
108

109
    switch (media)
5 ✔
110
    {
111
        case data:
1 ✔
112
            send_chunk(to_chunk(to_little_endian(height)));
1 ✔
113
            return true;
1 ✔
114
        case text:
1 ✔
115
            send_text(encode_base16(to_little_endian(height)));
1 ✔
116
            return true;
1 ✔
117
        case json:
3 ✔
118
            send_json(height);
3 ✔
119
            return true;
3 ✔
120
    }
121

122
    send_not_found();
×
123
    return true;
×
124
}
125

126
// notify
127
void protocol_native::do_top(media_type media) NOEXCEPT
6 ✔
128
{
129
    BC_ASSERT(stranded());
6 ✔
130

131
    switch (to_value(media))
6 ✔
132
    {
133
        case data:
4 ✔
134
            notify_chunk(to_tops());
4 ✔
135
            return;
4 ✔
136
        case text:
1 ✔
137
            notify_text(encode_base16(to_tops()));
1 ✔
138
            return;
1 ✔
139
        case json:
1 ✔
140
            notify_json(to_tops_json());
1 ✔
141
            return;
1 ✔
142
    }
143
}
144

145
bool protocol_native::handle_get_block(const code& ec, interface::block,
297 ✔
146
    uint8_t, uint8_t media, std::optional<hash_cptr> hash,
147
    std::optional<uint32_t> height, bool witness, bool candidate) NOEXCEPT
148
{
149
    if (stopped(ec))
297 ✔
150
        return false;
151

152
    const auto& query = archive();
15 ✔
153
    const auto link = to_header(height, hash, candidate);
15 ✔
154
    if (link.is_terminal())
15 ✔
155
    {
156
        send_not_found();
5 ✔
157
        return true;
158
    }
159

160
    size_t size{};
10 ✔
161
    if (!query.get_block_size(size, link, witness))
10 ✔
162
    {
163
        send_internal_server_error(database::error::integrity);
1 ✔
164
        return true;
1 ✔
165
    }
166

167
    switch (media)
9 ✔
168
    {
169
        case data:
5 ✔
170
        {
171
            send_stream(size, [&query, link, witness, turbo = turbo_](
5 ✔
172
                const data_slab& out) NOEXCEPT
173
            {
174
                return query.get_wire_block(out, link, witness, turbo);
5 ✔
175
            }, media_type::application_octet_stream);
176
            return true;
5 ✔
177
        }
178
        case text:
1 ✔
179
        {
180
            send_stream(two * size, [&query, link, witness, turbo = turbo_](
1 ✔
181
                const data_slab& out) NOEXCEPT
182
            {
183
                return query.get_wire_block<write::base16::fast>(out, link,
1 ✔
184
                    witness, turbo);
1 ✔
185
            }, media_type::text_plain);
186
            return true;
1 ✔
187
        }
188
        case json:
3 ✔
189
        {
190
            const auto block = query.get_block(link, witness);
3 ✔
191
            if (!block)
3 ✔
192
            {
193
                send_internal_server_error(database::error::integrity);
×
194
                return true;
×
195
            }
196

197
            auto model = value_from(block);
3 ✔
198
            inject(model.at("header"), height, link);
3 ✔
199
            send_json(std::move(model));
3 ✔
200
            return true;
201
        }
3 ✔
202
    }
203

204
    send_not_found();
×
205
    return true;
206
}
15 ✔
207

208
bool protocol_native::handle_get_block_header(const code& ec,
290 ✔
209
    interface::block_header, uint8_t, uint8_t media,
210
    std::optional<hash_cptr> hash, std::optional<uint32_t> height,
211
    bool candidate) NOEXCEPT
212
{
213
    if (stopped(ec))
290 ✔
214
        return false;
215

216
    const auto link = to_header(height, hash, candidate);
8 ✔
217
    if (const auto header = archive().get_header(link))
8 ✔
218
    {
219
        constexpr auto size = chain::header::serialized_size();
220
        switch (media)
5 ✔
221
        {
222
            case data:
1 ✔
223
                send_chunk(to_bin(*header, size));
1 ✔
224
                return true;
1 ✔
225
            case text:
1 ✔
226
                send_text(to_hex(*header, size));
1 ✔
227
                return true;
1 ✔
228
            case json:
3 ✔
229
                auto model = value_from(header);
3 ✔
230
                inject(model, height, link);
3 ✔
231
                send_json(std::move(model));
3 ✔
232
                return true;
233
        }
3 ✔
234
    }
8 ✔
235

236
    send_not_found();
3 ✔
237
    return true;
238
}
8 ✔
239

240
bool protocol_native::handle_get_block_header_context(const code& ec,
287 ✔
241
    interface::block_header_context, uint8_t, uint8_t media,
242
    std::optional<hash_cptr> hash, std::optional<uint32_t> height,
243
    bool candidate) NOEXCEPT
244
{
245
    if (stopped(ec))
287 ✔
246
        return false;
247

248
    if (media != json)
5 ✔
249
    {
250
        send_not_acceptable();
1 ✔
251
        return true;
1 ✔
252
    }
253

254
    database::context context{};
4 ✔
255
    const auto& query = archive();
4 ✔
256
    const auto link = to_header(height, hash, candidate);
4 ✔
257
    if (!query.get_context(context, link))
4 ✔
258
    {
259
        send_not_found();
2 ✔
260
        return true;
261
    }
262

263
    system::json::object object
264
    {
265
        { "hash", encode_hash(query.get_header_key(link)) },
4 ✔
266
        { "height", context.height },
267
        { "mtp", context.mtp },
268
    };
2 ✔
269

270
    // The "state" element implies transactions are associated.
271
    if (query.is_associated(link))
2 ✔
272
    {
273
        size_t nominal{}, maximal{};
2 ✔
274
        if (!query.get_block_sizes(nominal, maximal, link))
2 ✔
275
        {
276
            send_internal_server_error(database::error::integrity);
×
277
            return true;
×
278
        }
279

280
        const auto bypass = query.is_bypass(link);
2 ✔
281

282
        object["state"] = system::json::object
6 ✔
283
        {
284
            { "size", nominal },
285
            { "weight", chain::weighted_size(nominal, maximal) },
2 ✔
286
            { "count", query.get_tx_count(link) },
2 ✔
287
            { "validated", bypass || query.is_validated(link) },
2 ✔
288
            { "confirmed", query.is_confirmed_block(link) },
2 ✔
289
            { "confirmable", bypass || query.is_confirmable(link) },
2 ✔
290
            { "unconfirmable", !bypass && query.is_unconfirmable(link) }
4 ✔
291
        };
2 ✔
292
    }
293

294
    // TODO: move to system serializer.
295
    // All modern configurable forks.
296
    object["forks"] = system::json::object
4 ✔
297
    {
298
        { "bip16",  context.is_enabled(chain::flags::bip16_rule) },
2 ✔
299
        { "bip30",  context.is_enabled(chain::flags::bip30_rule) },
2 ✔
300
        { "bip34",  context.is_enabled(chain::flags::bip34_rule) },
2 ✔
301
        { "bip66",  context.is_enabled(chain::flags::bip66_rule) },
2 ✔
302
        { "bip65",  context.is_enabled(chain::flags::bip65_rule) },
2 ✔
303
        { "bip68",  context.is_enabled(chain::flags::bip68_rule) },
2 ✔
304
        { "bip112", context.is_enabled(chain::flags::bip112_rule) },
2 ✔
305
        { "bip113", context.is_enabled(chain::flags::bip113_rule) },
2 ✔
306
        { "bip141", context.is_enabled(chain::flags::bip141_rule) },
2 ✔
307
        { "bip143", context.is_enabled(chain::flags::bip143_rule) },
2 ✔
308
        { "bip147", context.is_enabled(chain::flags::bip147_rule) },
2 ✔
309
        { "bip42",  context.is_enabled(chain::flags::bip42_rule) },
2 ✔
310
        { "bip341", context.is_enabled(chain::flags::bip341_rule) },
2 ✔
311
        { "bip342", context.is_enabled(chain::flags::bip342_rule) },
2 ✔
312
        { "bip54_timewarp", context.is_enabled(chain::flags::bip54_timewarp_rule) },
2 ✔
313
        { "bip54_timespan", context.is_enabled(chain::flags::bip54_timespan_rule) },
2 ✔
314
        { "bip54_sigops", context.is_enabled(chain::flags::bip54_sigops_rule) },
2 ✔
315
        { "bip54_txsize", context.is_enabled(chain::flags::bip54_txsize_rule) },
2 ✔
316
        { "bip54_coinbase", context.is_enabled(chain::flags::bip54_coinbase_rule) }
2 ✔
317
    };
2 ✔
318

319
    send_json(std::move(object));
2 ✔
320
    return true;
2 ✔
321
}
4 ✔
322

323
bool protocol_native::handle_get_block_details(const code& ec,
289 ✔
324
    interface::block_details, uint8_t, uint8_t media,
325
    std::optional<hash_cptr> hash, std::optional<uint32_t> height,
326
    bool candidate) NOEXCEPT
327
{
328
    if (stopped(ec))
289 ✔
329
        return false;
330

331
    if (media != json)
7 ✔
332
    {
333
        send_not_acceptable();
1 ✔
334
        return true;
1 ✔
335
    }
336

337
    const auto& query = archive();
6 ✔
338
    const auto link = to_header(height, hash, candidate);
6 ✔
339

340
    // Missing block.
341
    if (!query.is_associated(link))
6 ✔
342
    {
343
        send_not_found();
2 ✔
344
        return true;
345
    }
346

347
    const auto count = query.get_tx_count(link);
4 ✔
348
    const auto key = hash.has_value() ? *hash.value() :
4 ✔
349
        query.get_header_key(link);
4 ✔
350

351
    database::context context{};
4 ✔
352
    size_t nominal{}, maximal{};
4 ✔
353
    uint64_t value{}, spend{}, claim{};
4 ✔
354
    if (is_zero(count) || key == system::null_hash ||
8 ✔
355
        !query.get_tx_spend(claim, query.to_coinbase(link)) ||
12 ✔
356
        !query.get_block_sizes(nominal, maximal, link) ||
8 ✔
357
        !query.get_block_value(value, link) ||
7 ✔
358
        !query.get_block_spend(spend, link) ||
6 ✔
359
        !query.get_context(context, link) ||
7 ✔
360
        is_subtract_overflow(value, spend))
3 ✔
361
    {
362
        send_internal_server_error(database::error::integrity);
1 ✔
363
        return true;
1 ✔
364
    }
365

366
    const auto fees = floored_subtract(value, spend);
3 ✔
367
    const auto& settings = system_settings();
3 ✔
368
    const auto bip42 = context.is_enabled(chain::flags::bip42_rule);
3 ✔
369
    const auto subsidy = chain::block::subsidy(context.height,
6 ✔
370
        settings.subsidy_interval_blocks, settings.initial_subsidy(), bip42);
3 ✔
371

372
    // sigops is not cached, so removed for now.
373
    system::json::object object
374
    {
375
        { "hash", encode_hash(key) },
6 ✔
376
        { "height", context.height },
377
        { "count", count },
378
        { "segregated", maximal != nominal },
6 ✔
379
        { "nominal", nominal },
380
        { "maximal", maximal },
381
        { "weight", chain::weighted_size(nominal, maximal) },
6 ✔
382
        { "virtual", chain::virtual_size(nominal, maximal) },
6 ✔
383
        { "value", value },
384
        { "fees", fees },
385
        { "subsidy", subsidy },
386
        { "reward", ceilinged_add(fees, subsidy) },
3 ✔
387
        { "claim", claim }
388
    };
6 ✔
389

390
    send_json(std::move(object));
3 ✔
391
    return true;
392
}
6 ✔
393

394
bool protocol_native::handle_get_block_txs(const code& ec,
288 ✔
395
    interface::block_txs, uint8_t, uint8_t media,
396
    std::optional<hash_cptr> hash, std::optional<uint32_t> height,
397
    bool candidate) NOEXCEPT
398
{
399
    if (stopped(ec))
288 ✔
400
        return false;
401

402
    const auto& query = archive();
6 ✔
403
    if (const auto hashes = query.get_tx_keys(to_header(height, hash, candidate));
12 ✔
404
        !hashes.empty())
6 ✔
405
    {
406
        const auto size = hashes.size() * hash_size;
4 ✔
407
        switch (media)
4 ✔
408
        {
409
            case data:
2 ✔
410
            {
411
                const auto bytes = pointer_cast<const uint8_t>(hashes.data());
2 ✔
412
                send_chunk(to_chunk({ bytes, std::next(bytes, size) }));
2 ✔
413
                return true;
2 ✔
414
            }
415
            case text:
1 ✔
416
            {
417
                const auto bytes = pointer_cast<const uint8_t>(hashes.data());
1 ✔
418
                send_text(encode_base16({ bytes, std::next(bytes, size) }));
1 ✔
419
                return true;
1 ✔
420
            }
421
            case json:
1 ✔
422
            {
423
                system::json::array out(hashes.size());
1 ✔
424
                std::ranges::transform(hashes, out.begin(),
1 ✔
425
                    [](const auto& hash) { return encode_hash(hash); });
1 ✔
426
                send_json(out);
1 ✔
427
                return true;
428
            }
1 ✔
429
        }
430
    }
6 ✔
431

432
    send_not_found();
2 ✔
433
    return true;
2 ✔
434
}
435

436
bool protocol_native::handle_get_block_filter(const code& ec,
294 ✔
437
    interface::block_filter, uint8_t, uint8_t media, uint8_t type,
438
    std::optional<hash_cptr> hash, std::optional<uint32_t> height,
439
    bool candidate) NOEXCEPT
440
{
441
    if (stopped(ec))
294 ✔
442
        return false;
443

444
    const auto& query = archive();
12 ✔
445
    if (!query.filter_enabled() || type != client_filter::type_id::neutrino)
12 ✔
446
    {
447
        send_not_implemented();
1 ✔
448
        return true;
1 ✔
449
    }
450

451
    data_chunk filter{};
11 ✔
452
    if (query.get_filter_body(filter, to_header(height, hash, candidate)))
11 ✔
453
    {
454
        switch (media)
9 ✔
455
        {
456
            case data:
7 ✔
457
                send_chunk(std::move(filter));
7 ✔
458
                return true;
459
            case text:
1 ✔
460
                send_text(encode_base16(filter));
1 ✔
461
                return true;
1 ✔
462
            case json:
1 ✔
463
                send_json(value_from(encode_base16(filter)));
1 ✔
464
                return true;
1 ✔
465
        }
466
    }
467

468
    send_not_found();
2 ✔
469
    return true;
470
}
11 ✔
471

472
bool protocol_native::handle_get_block_filter_hash(const code& ec,
289 ✔
473
    interface::block_filter_hash, uint8_t, uint8_t media, uint8_t type,
474
    std::optional<hash_cptr> hash, std::optional<uint32_t> height,
475
    bool candidate) NOEXCEPT
476
{
477
    if (stopped(ec))
289 ✔
478
        return false;
479

480
    const auto& query = archive();
7 ✔
481
    if (!query.filter_enabled() || type != client_filter::type_id::neutrino)
7 ✔
482
    {
483
        send_not_implemented();
1 ✔
484
        return true;
1 ✔
485
    }
486

487
    hash_digest filter_hash{ hash_size };
6 ✔
488
    if (query.get_filter_hash(filter_hash, to_header(height, hash, candidate)))
6 ✔
489
    {
490
        switch (media)
4 ✔
491
        {
492
            case data:
2 ✔
493
                send_chunk(to_chunk(filter_hash));
2 ✔
494
                return true;
2 ✔
495
            case text:
1 ✔
496
                send_text(encode_base16(filter_hash));
1 ✔
497
                return true;
1 ✔
498
            case json:
1 ✔
499
                send_json(value_from(encode_hash(filter_hash)));
1 ✔
500
                return true;
1 ✔
501
        }
502
    }
503

504
    send_not_found();
2 ✔
505
    return true;
506
}
507

508
bool protocol_native::handle_get_block_filter_header(const code& ec,
288 ✔
509
    interface::block_filter_header, uint8_t, uint8_t media, uint8_t type,
510
    std::optional<hash_cptr> hash, std::optional<uint32_t> height,
511
    bool candidate) NOEXCEPT
512
{
513
    if (stopped(ec))
288 ✔
514
        return false;
515

516
    const auto& query = archive();
6 ✔
517
    if (!query.filter_enabled() || type != client_filter::type_id::neutrino)
6 ✔
518
    {
519
        send_not_implemented();
1 ✔
520
        return true;
1 ✔
521
    }
522

523
    hash_digest filter_head{ hash_size };
5 ✔
524
    if (query.get_filter_head(filter_head, to_header(height, hash, candidate)))
5 ✔
525
    {
526
        switch (media)
3 ✔
527
        {
528
            case data:
1 ✔
529
                send_chunk(to_chunk(filter_head));
1 ✔
530
                return true;
1 ✔
531
            case text:
1 ✔
532
                send_text(encode_base16(filter_head));
1 ✔
533
                return true;
1 ✔
534
            case json:
1 ✔
535
                send_json(value_from(encode_hash(filter_head)));
1 ✔
536
                return true;
1 ✔
537
        }
538
    }
539

540
    send_not_found();
2 ✔
541
    return true;
542
}
543

544
bool protocol_native::handle_get_block_tx(const code& ec, interface::block_tx,
288 ✔
545
    uint8_t, uint8_t media, uint32_t position, std::optional<hash_cptr> hash,
546
    std::optional<uint32_t> height, bool witness, bool candidate) NOEXCEPT
547
{
548
    if (stopped(ec))
288 ✔
549
        return false;
550

551
    const auto& query = archive();
6 ✔
552
    if (const auto tx = query.get_transaction(query.to_transaction(
12 ✔
553
        to_header(height, hash, candidate), position), witness))
18 ✔
554
    {
555
        const auto size = tx->serialized_size(witness);
4 ✔
556
        switch (media)
4 ✔
557
        {
558
            case data:
2 ✔
559
                send_chunk(to_bin(*tx, size, witness));
2 ✔
560
                return true;
2 ✔
561
            case text:
1 ✔
562
                send_text(to_hex(*tx, size, witness));
1 ✔
563
                return true;
1 ✔
564
            case json:
1 ✔
565
                send_json(value_from(tx));
1 ✔
566
                return true;
1 ✔
567
        }
568
    }
6 ✔
569

570
    send_not_found();
2 ✔
571
    return true;
2 ✔
572
}
573

574
bool protocol_native::handle_get_block_subscribe(const code& ec,
289 ✔
575
    interface::block_subscribe, uint8_t, uint8_t media, bool stop) NOEXCEPT
576
{
577
    if (stopped(ec))
289 ✔
578
        return false;
579

580
    const auto value = stop ? media_type::unknown : (media_type)media;
7 ✔
581
    block_subscribe_.store(value, std::memory_order_relaxed);
7 ✔
582
    if (stop)
7 ✔
583
    {
584
        send_empty();
1 ✔
585
        return true;
1 ✔
586
    }
587

588
    // Return top block hash upon block subscription.
589
    const auto& query = archive();
6 ✔
590
    const auto link = query.to_top_confirmed();
6 ✔
591
    if (const auto hash = query.get_header_key(link); hash != null_hash)
6 ✔
592
    {
593
        switch (media)
6 ✔
594
        {
595
            case data:
2 ✔
596
                send_chunk(to_chunk(hash));
2 ✔
597
                return true;
6 ✔
598
            case text:
2 ✔
599
                send_text(encode_base16(hash));
2 ✔
600
                return true;
2 ✔
601
            case json:
2 ✔
602
                send_json(value_from(encode_hash(hash)));
2 ✔
603
                return true;
2 ✔
604
        }
605
    }
606

UNCOV
607
    send_not_found();
×
608
    return true;
609
}
6 ✔
610

611
// notify
612
void protocol_native::do_block(node::header_t link, media_type media) NOEXCEPT
3 ✔
613
{
614
    BC_ASSERT(stranded());
3 ✔
615

616
    const auto hash = archive().get_header_key(link);
3 ✔
617
    switch (to_value(media))
3 ✔
618
    {
619
        case data:
1 ✔
620
            notify_chunk(to_chunk(hash));
1 ✔
621
            return;
3 ✔
622
        case text:
1 ✔
623
            notify_text(encode_base16(hash));
1 ✔
624
            return;
1 ✔
625
        case json:
1 ✔
626
            notify_json(value_from(encode_hash(hash)));
1 ✔
627
            return;
1 ✔
628
    }
629
}
630

631
BC_POP_WARNING()
632
BC_POP_WARNING()
633

634
} // namespace server
635
} // namespace libbitcoin
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc