File erlang-credentials-obfuscation.spec of Package erlang-credentials-obfuscation
#
# spec file for package erlang-credentials-obfuscation
#
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: erlang-credentials-obfuscation
Version: 3.4.0
Release: 0
%define mod_ver %(echo "%{version}" | cut -d "+" -f1)
Summary: Tiny library/OTP app for credential obfuscation
License: Apache-2.0 OR MPL-2.0
Group: Development/Libraries/Other
URL: https://github.com/rabbitmq/credentials-obfuscation
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Source0: credentials-obfuscation-%{version}.tar.xz
Requires: erlang >= 23.2
BuildRequires: erlang >= 23.2
BuildRequires: erlang-rebar
%description
This is a small library OTP application that acts as a helper. It encrypts and
decrypts sensitive data typically stored in processes state with a one-off key
(key material must be provided on node start). One example of such sensitive
data is credentials used to access remote services.
This is necessary to avoid the sensitive values logged when process state is
dumped by the Erlang runtime (error_logger).
%prep
%setup -q -n credentials-obfuscation-%{version}
%build
%__rebar compile
%install
for dir in ebin include ; do
install -d %{buildroot}%{erlang_libdir}/credentials-obfuscation-%{mod_ver}/${dir}
cp -r ${dir}/* %{buildroot}%{erlang_libdir}/credentials-obfuscation-%{mod_ver}/${dir}/
done
%check
%__rebar ct
%files
%defattr(-,root,root)
%doc README.md CHANGELOG.md HISTORY.md doc
%license LICENSE LICENSE-APACHE2 LICENSE-MPL-RabbitMQ
%dir %{erlang_libdir}/credentials-obfuscation-%{mod_ver}
%{erlang_libdir}/credentials-obfuscation-%{mod_ver}/ebin
%{erlang_libdir}/credentials-obfuscation-%{mod_ver}/include
%changelog