geliboot_internal.h (62bd02cee5752592d6f284a61759fb398a3ea8ff) geliboot_internal.h (c1418270b28edf9b99044181e9f48dfc0a7dc160)
1/*-
2 * Copyright (c) 2015 Allan Jude <allanjude@FreeBSD.org>
3 * Copyright (c) 2005-2011 Pawel Jakub Dawidek <pawel@dawidek.net>
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 41 unchanged lines hidden (view full) ---

50/* Pull in AES implementation */
51#include <crypto/rijndael/rijndael-api-fst.h>
52
53/* AES-XTS implementation */
54#define _STAND 1
55#define STAND_H /* We don't want stand.h in {gpt,zfs,gptzfs}boot */
56#include <opencrypto/xform_enc.h>
57
1/*-
2 * Copyright (c) 2015 Allan Jude <allanjude@FreeBSD.org>
3 * Copyright (c) 2005-2011 Pawel Jakub Dawidek <pawel@dawidek.net>
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 41 unchanged lines hidden (view full) ---

50/* Pull in AES implementation */
51#include <crypto/rijndael/rijndael-api-fst.h>
52
53/* AES-XTS implementation */
54#define _STAND 1
55#define STAND_H /* We don't want stand.h in {gpt,zfs,gptzfs}boot */
56#include <opencrypto/xform_enc.h>
57
58struct geli_entry {
59 struct dsk *dsk;
58#define GELIDEV_NAMELEN 32
59
60struct geli_dev {
60 off_t part_end;
61 struct g_eli_softc sc;
62 struct g_eli_metadata md;
63 int keybuf_slot;
61 off_t part_end;
62 struct g_eli_softc sc;
63 struct g_eli_metadata md;
64 int keybuf_slot;
64 SLIST_ENTRY(geli_entry) entries;
65} *geli_e, *geli_e_tmp;
65 char *name; /* for prompting; it ends in ':' */
66};
66
67
67static int geli_count;
68int geliboot_crypt(u_int algo, int enc, u_char *data, size_t datasize,
69 const u_char *key, size_t keysize, u_char *iv);
68
69#endif /* _GELIBOOT_INTERNAL_H_ */
70
71#endif /* _GELIBOOT_INTERNAL_H_ */