File: test_botan_gost.cpp

package info (click to toggle)
softhsm2 2.6.1-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 7,496 kB
  • sloc: cpp: 65,881; sh: 4,363; ansic: 2,018; makefile: 655
file content (17 lines) | stat: -rw-r--r-- 468 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include <botan/gost_3410.h>
#include <botan/oids.h>
#include <botan/version.h>
int main()
{
        try {
                const std::string name("gost_256A");
                const Botan::OID oid(Botan::OIDS::lookup(name));
                const Botan::EC_Group ecg(oid);
                const std::vector<Botan::byte> der =
                    ecg.DER_encode(Botan::EC_DOMPAR_ENC_OID);
        } catch(...) {
                return 1;
        }

        return 0;
}