-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathclassification-banner.spec
65 lines (52 loc) · 1.98 KB
/
classification-banner.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
Name: classification-banner
Version: 1.7.2
Release: 1%{?dist}
Summary: Displays Classification Banner for a Graphical Session
License: GPLv2+
URL: https://github.com/SecurityCentral/classification-banner
Source0: %{URL}/archive/%{version}/%{name}-%{version}.tar.gz
BuildArch: noarch
BuildRequires: python3-setuptools
BuildRequires: python3-devel
BuildRequires: python3-gobject
BuildRequires: desktop-file-utils
BuildRequires: gtk3
Requires: xrandr
Requires: python3-gobject
Requires: gtk3
%description
Classification Banner is a python script that will display the
classification level banner of a session with a variety of
configuration options on the primary screen. This script can
help government and possibly private customers display a
notification that sensitive material is being displayed - for
example PII or SECRET Material being processed in a graphical
session. The script has been tested on a variety of graphical
environments such as GNOME2, GNOME3, KDE, twm, icewm, and Cinnamon.
%prep
%autosetup -n %{name}-%{version}
%build
%py3_build
%install
%py3_install
install -d -m755 %{buildroot}%{_datadir}/%{name}
install -d -m755 %{buildroot}%{_sysconfdir}/%{name}
install -d -m755 %{buildroot}%{_sysconfdir}/xdg/autostart/
install -pm644 contrib/banner.conf %{buildroot}%{_sysconfdir}/%{name}/banner.conf
install -pm644 share/%{name}-screenshot.png %{buildroot}%{_datadir}/%{name}/%{name}-screenshot.png
desktop-file-install \
--dir=%{buildroot}%{_sysconfdir}/xdg/autostart \
contrib/%{name}.desktop
%check
export DISPLAY=":0.0"
%{__python3} setup.py test
%files
%license LICENSE
%doc README.md AUTHOR Contributors.md
%{python3_sitelib}/classification_banner
%{python3_sitelib}/classification_banner-*.egg-info/
%config(noreplace) %{_sysconfdir}/%{name}/banner.conf
%config(noreplace) %{_sysconfdir}/xdg/autostart/classification-banner.desktop
%{_bindir}/%{name}
%{_datadir}/%{name}/%{name}-screenshot.png
%changelog