Skip to content

Vap #1734

Merged
merged 6 commits into from
Feb 28, 2020
Merged

Vap #1734

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions ccid.be0
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
#!/usr/bin/env beesh

# BEE_VERSION ccid-1.4.31-0

# more info: https://ccid.apdu.fr/

SRCURL[0]="https://ccid.apdu.fr/files/ccid-${PKGVERSION}.tar.bz2"

# PATCHURL+=()

# build_in_sourcedir

# sourcesubdir_append src

#mee_extract() {
# bee_extract "${@}"
#}

#mee_patch() {
# bee_patch "${@}"
#}

#mee_configure() {
# bee_configure
#}

#mee_build() {
# bee_build
#}

#mee_install() {
# bee_install
#}

#mee_install_post() {
# exit
#}
210 changes: 210 additions & 0 deletions citrix-workspace-app.be0
Original file line number Diff line number Diff line change
@@ -0,0 +1,210 @@
#!/usr/bin/env beesh

# BEE_VERSION citrix-workspace-app-19.10.0.15-0

# more info: https://www.citrix.com/downloads/workspace-app/linux/workspace-app-for-linux-latest.html
#
# never execute the provided installer. Its total junk.
#
# To use the package, this has to be done for each new user:
#
# mkdir -p $HOME/.ICAClient/cache
# cp /opt/Citrix/ICAClient/config/{All_Regions,Trusted_Region,Unknown_Region,canonicalization,regions}.ini $HOME/.ICAClient/
#
# maybe we do this from a wrapper in a future build

SRCURL[0]="/src/mariux/download/citrix_workspace_app-${PKGVERSION}.tgz"

# PATCHURL+=()

# build_in_sourcedir

# sourcesubdir_append src

#mee_extract() {
# bee_extract "${@}"
#}

#mee_patch() {
# bee_patch "${@}"
#}

#mee_configure() {
# bee_configure
#}

#mee_build() {
# bee_build
#}

mee_install() {

# stolen from
# https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=icaclient

srcdir="$S"
pkgdir=$D
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add of curiosity, why the new variables?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because the following code is copy-and-pasted from the source referenced above. By adding these names we don't need to modify each and every line below.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, that makes sense. “stolen from” was not clear enough for me.


ICAROOT=/opt/Citrix/ICAClient
ICADIR="$srcdir/linuxx64/linuxx64.cor"
mkdir -p "${pkgdir}$ICAROOT"

cd "$ICADIR"
install -m755 wfica *.so *.DLL AuthManagerDaemon PrimaryAuthManager ServiceRecord selfservice "${pkgdir}$ICAROOT"

# copy directories
cp -r ./config/ "${pkgdir}$ICAROOT"
cp -r ./gtk/ "${pkgdir}$ICAROOT"
cp -r ./help/ "${pkgdir}$ICAROOT"
cp -r ./keyboard/ "${pkgdir}$ICAROOT"
cp -r ./keystore/ "${pkgdir}$ICAROOT"
cp -r ./lib/ "${pkgdir}$ICAROOT"
cp -r ./icons/ "${pkgdir}$ICAROOT"
cp -r ./nls/ "${pkgdir}$ICAROOT"
cp -r ./site/ "${pkgdir}$ICAROOT"
cp -r ./usb/ "${pkgdir}$ICAROOT"
cp -r ./util/ "${pkgdir}$ICAROOT"

# Install License
install -m644 -D nls/en.UTF-8/eula.txt \
"${pkgdir}$ICAROOT/eula.txt"

# create /config/.server to enable user customization using ~/.ICACLient/ overrides. Thanks Tomek
touch "${pkgdir}$ICAROOT/config/.server"

# # Extract system ca-certificates and install in the Citrix cacerts directory
# cp /etc/ca-certificates/extracted/tls-ca-bundle.pem "${pkgdir}$ICAROOT/keystore/cacerts/"
# cd "${pkgdir}$ICAROOT/keystore/cacerts/"
# awk 'BEGIN {c=0;} /BEGIN CERT/{c++} { print > "cert." c ".pem"}' < tls-ca-bundle.pem
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why can’t the system CA certificates not be used or symlinked?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using the above code, the certificates would be copied from the build system, which is not what we want. Again this part is copy-and-pasted from the "stolen from" source. I want to make as few modifications to it as possible, so this is easier to maintain. Commenting out unwanted lines is a small modification and easy to understand. Changing the code to create symlinks would be a bigger modification. And it is not needed at all. Why add complexity without reason? Plus, I want the Citrix junk to be as self-contained as possible.


# The following 32-bit library causes false namcap errors
# rm util/libgstflatstm.32.so

# # Install wrapper script
# install -m755 "${srcdir}/wfica.sh" "${pkgdir}$ICAROOT/wfica.sh"

# Dirty Hack
# wfica expects {module,wfclient,apssrv}.ini in $ICAROOT/config
# sadly these configs differ slightly by locale
lang=${LANG%%_*}
if [[ ! -d "${pkgdir}/$ICAROOT/nls/$lang" ]]; then
lang='en'
fi
cp "${pkgdir}$ICAROOT/nls/$lang/module.ini" "${pkgdir}/$ICAROOT/config/"
cp "${pkgdir}$ICAROOT/nls/$lang/appsrv.template" "${pkgdir}/$ICAROOT/config/appsrv.ini"
cp "${pkgdir}$ICAROOT/nls/$lang/wfclient.template" "${pkgdir}/$ICAROOT/config/wfclient.ini"

# Copy Firefox plugin into plugin directory
mkdir -p "${pkgdir}/usr/lib/mozilla/plugins"
ln -s "$ICAROOT/npica.so" "${pkgdir}"/usr/lib/mozilla/plugins/npica.so
cd "${srcdir}"
# install freedesktop.org files
# install -Dm644 wfica.desktop "${pkgdir}/usr/share/applications/wfica.desktop"
# install -Dm644 conncenter.desktop "${pkgdir}/usr/share/applications/conncentre.desktop"
# install -Dm644 configmgr.desktop "${pkgdir}/usr/share/applications/configmgr.desktop"
# install -Dm644 selfservice.desktop "${pkgdir}/usr/share/applications/wfcmgr.desktop"
mkdir -p "${pkgdir}/usr/share/applications/"
cat <<'EOF' >"${pkgdir}/usr/share/applications/wfica.desktop"
[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Name=Citrix Receiver Engine
StartupWMClass=Wfica
NoDisplay=true
Categories=Application;Network;X-Red-Hat-Base;X-SuSE-Core-Internet;
MimeType=application/x-ica;
Icon=/opt/Citrix/ICAClient/icons/manager.png
TryExec=/opt/Citrix/ICAClient/wfica.sh
Exec=/opt/Citrix/ICAClient/wfica.sh
EOF
cat <<'EOF' >"${pkgdir}/usr/share/applications/conncentre.desktop"
[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Name=Citrix Connection Centre
NoDisplay=false
Categories=Application;Network;X-Red-Hat-Base;X-SuSE-Core-Internet;
Icon=/opt/Citrix/ICAClient/icons/manager.png
TryExec=/opt/Citrix/ICAClient/util/conncenter
Exec=/opt/Citrix/ICAClient/util/conncenter --icaroot /opt/Citrix/ICAClient
EOF
cat <<'EOF' >"${pkgdir}/usr/share/applications/configmgr.desktop"
[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Name=Citrix Receiver Preferences
NoDisplay=false
Categories=Application;Network;X-Red-Hat-Base;X-SuSE-Core-Internet;
Icon=/opt/Citrix/ICAClient/icons/manager.png
TryExec=/opt/Citrix/ICAClient/util/configmgr
Exec=/opt/Citrix/ICAClient/util/configmgr --icaroot /opt/Citrix/ICAClient
EOF
cat <<'EOF' > "${pkgdir}/usr/share/applications/wfcmgr.desktop"
[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Name=Citrix Receiver Self Service
Categories=Application;Network;X-Red-Hat-Base;X-SuSE-Core-Internet;
Icon=/opt/Citrix/ICAClient/icons/manager.png
TryExec=/opt/Citrix/ICAClient/selfservice
Exec=/opt/Citrix/ICAClient/selfservice --icaroot /opt/Citrix/ICAClient
EOF

# install scripts
# install -Dm755 wfica.sh "${pkgdir}$ICAROOT"
# install -Dm755 wfica_assoc.sh "${pkgdir}$ICAROOT"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a comment why the scripts above are not used?

Copy link
Collaborator Author

@donald donald Feb 27, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The script is created from a here document in the bee script. I already forgot, why this needed to be changed.

cat <<'EOF' >"${pkgdir}$ICAROOT/wfica.sh"
#!/bin/sh
export ICAROOT=/opt/Citrix/ICAClient
${ICAROOT}/wfica -file "$1"
EOF
chmod 755 "${pkgdir}$ICAROOT/wfica.sh"
cat <<'EOF' >"${pkgdir}$ICAROOT/wfica_assoc.sh"
#!/bin/sh
export ICAROOT=/opt/Citrix/ICAClient
${ICAROOT}/wfica -associate -fileparam "$1"
EOF
chmod 755 "${pkgdir}$ICAROOT/wfica_assoc.sh"

# # make certificates available
# rm -r "${pkgdir}/opt/Citrix/ICAClient/keystore/cacerts"
# ln -s /etc/ssl/certs "${pkgdir}/opt/Citrix/ICAClient/keystore/cacerts"
# #ln -s /usr/share/ca-certificates/trust-source/* "${pkgdir}/opt/Citrix/ICAClient/keystore/cacerts/"
# #c_rehash "${pkgdir}/opt/Citrix/ICAClient/keystore/cacerts/"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this be removed?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment? No. Again: This is all verbatim copy-and-pasted.


cat<<'EOF' >"${pkgdir}/opt/Citrix/ICAClient/keystore/cacerts/T-TeleSec_GlobalRoot_Class_2.pem"
subject=/CN=T-TeleSec GlobalRoot Class 2/OU=T-Systems Trust Center/O=T-Systems Enterprise Services GmbH/C=DE
-----BEGIN CERTIFICATE-----
MIIDwzCCAqugAwIBAgIBATANBgkqhkiG9w0BAQsFADCBgjELMAkGA1UEBhMCREUx
KzApBgNVBAoMIlQtU3lzdGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAd
BgNVBAsMFlQtU3lzdGVtcyBUcnVzdCBDZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNl
YyBHbG9iYWxSb290IENsYXNzIDIwHhcNMDgxMDAxMTA0MDE0WhcNMzMxMDAxMjM1
OTU5WjCBgjELMAkGA1UEBhMCREUxKzApBgNVBAoMIlQtU3lzdGVtcyBFbnRlcnBy
aXNlIFNlcnZpY2VzIEdtYkgxHzAdBgNVBAsMFlQtU3lzdGVtcyBUcnVzdCBDZW50
ZXIxJTAjBgNVBAMMHFQtVGVsZVNlYyBHbG9iYWxSb290IENsYXNzIDIwggEiMA0G
CSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCqX9obX+hzkeXaXPSi5kfl82hVYAUd
AqSzm1nzHoqvNK38DcLZSBnuaY/JIPwhqgcZ7bBcrGXHX+0CfHt8LRvWurmAwhiC
FoT6ZrAIxlQjgeTNuUk/9k9uN0goOA/FvudocP05l03Sx5iRUKrERLMjfTlH6VJi
1hKTXrcxlkIF+3anHqP1wvzpesVsqXFP6st4vGCvx9702cu+fjOlbpSD8DT6Iavq
jnKgP6TeMFvvhk1qlVtDRKgQFRzlAVfFmPHmBiiRqiDFt1MmUUOyCxGVWOHAD3bZ
wI18gfNycJ5v/hqO2V81xrJvNHy+SE/iWjnX2J14np+GPgNeGYtEotXHAgMBAAGj
QjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBS/
WSA2AHmgoCJrjNXyYdK4LMuCSjANBgkqhkiG9w0BAQsFAAOCAQEAMQOiYQsfdOhy
NsZt+U2e+iKo4YFWz827n+qrkRk4r6p8FU3ztqONpfSO9kSpp+ghla0+AGIWiPAC
uvxhI+YzmzB6azZie60EI4RYZeLbK4rnJVM3YlNfvNoBYimipidx5joifsFvHZVw
IEoHNN/q/xWA5brXethbdXwFeilHfkCoMRN3zUA7tFFHei4R40cR3p1m0IvVVGb6
g1XqfMIpiRvpb7PO4gWEyS8+eIVibslfwXhjdFjASBgMmTnrpMwatXlajRWc2BQN
9noHV8cigwUtPJslJj0Ys6lDfMjIq2SPDqO/nBudMNva0Bkuqjzx+zOAduTNrRlP
BSeOE6Fuwg==
-----END CERTIFICATE-----
EOF

}

#mee_install_post() {
# exit
#}
37 changes: 37 additions & 0 deletions pcsc-lite.be0
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
#!/usr/bin/env beesh

# BEE_VERSION pcsc-lite-1.8.25-0

# more info: https://pcsclite.apdu.fr/

SRCURL[0]="https://pcsclite.apdu.fr/files/pcsc-lite-${PKGVERSION}.tar.bz2"

# PATCHURL+=()

# build_in_sourcedir

# sourcesubdir_append src

#mee_extract() {
# bee_extract "${@}"
#}

#mee_patch() {
# bee_patch "${@}"
#}

#mee_configure() {
# bee_configure
#}

#mee_build() {
# bee_build
#}

#mee_install() {
# bee_install
#}

#mee_install_post() {
# exit
#}
46 changes: 46 additions & 0 deletions safenetauthenticationclient.be0
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
#!/usr/bin/env beesh

# BEE_VERSION safenetauthenticationclient-10.7.77-0

# more info on Token: https://safenet.gemalto.com/multi-factor-authentication/authenticators/pki-usb-authentication/etoken-5300-usb-token/
#
# Download Driver from
# https://extranet.mpg.de/IKT/Projekte/15022/Datenraum%20Rollouts/Forms/AllItems.aspx
# - 001_Citrix_Client-Komponenten - 003_Linux - CryptoToken Treiber - safenetauthenticationclient_10.7.77_amd64

SRCURL[0]="/src/mariux/beeroot/downloads/safenetauthenticationclient_${PKGVERSION}_amd64.deb"

# PATCHURL+=()

# build_in_sourcedir

# sourcesubdir_append src

mee_extract() {
cd $S
start_cmd ar xv "${@}"
mkdir control
start_cmd tar xvf control.tar.gz -C control
start_cmd tar xvf data.tar.xz
echo \$S=$S
}

#mee_patch() {
# bee_patch "${@}"
#}

#mee_configure() {
# bee_configure
#}

#mee_build() {
# bee_build
#}

mee_install() {
start_cmd cp -r $S/etc $S/usr $D/
}

#mee_install_post() {
# exit
#}