Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.bugs.dist > #1178902

Bug#1058770: globalplatform: establish_context failed with error 0x8010006A (Access denied.)

From Ludovic Rousseau <ludovic.rousseau@free.fr>
Newsgroups linux.debian.bugs.dist
Subject Bug#1058770: globalplatform: establish_context failed with error 0x8010006A (Access denied.)
Date 2023-12-16 12:20 +0100
Message-ID <HLAS5-dXE5-3@gated-at.bofh.it> (permalink)
References <HLoHf-dQ8N-5@gated-at.bofh.it> <HLoHf-dQ8N-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, 15 Dec 2023 22:29:46 +0100 Ludovic Rousseau <rousseau@debian.org> wrote:
> Is it possible to modify the tests in globalplatform so that the error
> 0x8010006A is NOT considered as a failure?

No need to disable your tests. I found the solution.

> I am trying to find a long term solution in pcsc-lite.

The idea is to start pcscd with polkit disabled.

In debian/tests/control you add (for both tests):
Restrictions: needs-sudo

In your test files cli and lib you add:
# setup pcscd with NO polkit control to avoid " Access denied." errors
echo "PCSCD_ARGS=--disable-polkit" | sudo tee /etc/default/pcscd
sudo systemctl restart pcscd.service



Proposed patch:
diff --git a/debian/tests/cli b/debian/tests/cli
index 298088b..1e19f2a 100755
--- a/debian/tests/cli
+++ b/debian/tests/cli
@@ -2,6 +2,10 @@
 
 set -e
 
+# setup pcscd with NO polkit control to avoid " Access denied." errors
+echo "PCSCD_ARGS=--disable-polkit" | sudo tee /etc/default/pcscd
+sudo systemctl restart pcscd.service
+
 cat<<EOF | gpshell
 enable_trace
 establish_context
diff --git a/debian/tests/control b/debian/tests/control
index 63b632f..250c457 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -3,6 +3,7 @@ Depends:
  gpshell,
  libgppcscconnectionplugin1,
  pcscd,
+Restrictions: needs-sudo
 
 Tests: lib
 Depends:
@@ -13,3 +14,4 @@ Depends:
  libssl-dev,
  pcscd,
  pkgconf,
+Restrictions: needs-sudo
diff --git a/debian/tests/lib b/debian/tests/lib
index 18aad32..7597c33 100755
--- a/debian/tests/lib
+++ b/debian/tests/lib
@@ -2,6 +2,10 @@
 
 set -e
 
+# setup pcscd with NO polkit control to avoid " Access denied." errors
+echo "PCSCD_ARGS=--disable-polkit" | sudo tee /etc/default/pcscd
+sudo systemctl restart pcscd.service
+
 dir=`dirname "$0"`
 
 # change directory to $AUTOPKGTEST_TMP if available



I can push this patch in salsa and close this bug if you want.
Just tell me.

Back to linux.debian.bugs.dist | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Bug#1058770: globalplatform: establish_context failed with error 0x8010006A (Access denied.) Ludovic Rousseau <rousseau@debian.org> - 2023-12-15 23:20 +0100
  Bug#1058770: globalplatform: establish_context failed with error 0x8010006A (Access denied.) Ludovic Rousseau <ludovic.rousseau@free.fr> - 2023-12-16 12:20 +0100
    Bug#1058770: globalplatform: establish_context failed with error 0x8010006A (Access denied.) Simon Josefsson <simon@josefsson.org> - 2023-12-16 19:50 +0100

csiph-web