Commit graph

7 commits

Author SHA1 Message Date
Tom Gundersen
bca53a596c crypt: add automatic darwin support
Currently one would have to pass a `macos` flag explicitly to build on
OSX, but if we replace `macos` with `darwin` this happens automatically.

Signed-off-by: Tom Gundersen <teg@jklm.no>
2020-07-17 07:48:22 +02:00
Martin Sehnoutka
e769377f0e crypt_test: don't run on macOS
The new crypt tests cannot be run on macOS. Making them conditional for
non-macOS platforms fixes running unit tests in the internal directory
on macOS.
2020-04-09 13:21:30 +02:00
Jakub Rusz
8861c6dbb9 tests: increase coverage of internal/crypt
fixes #444
2020-04-02 20:12:06 +02:00
Martin Sehnoutka
aab8a4d305 crypt: make it possible to compile and test on macOS
Our current crypt implmentation requires glibc to be available on the
developer's system. But it is not strictly necessary, because I'd like
to run at least unit tests on mac. This PR makes it possible to compile
and run unit-tests on mac, but it will panic if someone tries to run
osbuild-composer on mac.
2020-01-30 14:42:25 +01:00
Ondřej Budai
705338c5b3 blueprint: add support for unencrypted passwords in user customization 2019-10-31 21:46:39 +01:00
Ondřej Budai
189b2b4547 crypt: fix gcc warning
Newer gcc doesn't really like strncpy producing following warnings:
warning: ‘strncpy’ specified bound depends on the length of the source argument

I switched the function to the plain old strcpy as strncpy is not necessary anyway
because we allocate the destination buffer using size returned from strlen.
2019-10-31 21:46:39 +01:00
Ondřej Budai
5b0c2cac9f Import crypt library
Copied from b3e2912865/crypt_r.go

Original sources are under MIT license
2019-10-31 21:46:39 +01:00