Questions tagged [security-context]

104 questions
4
votes
1 answer

spring security jmx authneticator

I have a JMX server configured without Spring and am trying to implement Spring Security for the Authorization part. (See here, https://blogs.oracle.com/lmalventosa/entry/jmx_authentication_authorization Use Case 4, without the Authorization part) I…
3
votes
1 answer

Minimun privileges for CSI sidecar

I'm building my own CSI driver with CSI standards and I'm wondering about the Security Context to be set for the CSI sidecar containers. I'm going to use: Node Driver Registrar CSI provisioner CSI attacher CSI liveness probe. Some of them need to…
3
votes
1 answer

kubernetes: using value of runAsUser in an environment variable using valueFrom?

I have a kubernetes deployment that starts a pod that includes a runAsUser key in its securityContext. I was hoping I could stick this value in the environment of an initContainer using valueFrom, like this: apiVersion: apps/v1 kind:…
larsks
  • 277,717
  • 41
  • 399
  • 399
3
votes
1 answer

securityContext.privileged: Forbidden: disallowed by cluster policy

I can't start pod which requires privileged security context. PodSecurityPolicy: apiVersion: policy/v1beta1 kind: PodSecurityPolicy metadata: name: pod-security-policy spec: privileged: true allowPrivilegeEscalation: true …
Kok How Teh
  • 3,298
  • 6
  • 47
  • 85
3
votes
0 answers

Send additional info in security context

I am using oauth2, and I have an authorization server and a (separate) resource server. A client gets a token from the authorization server and then uses the token to make requests to the resource server. When the resource server fetches the…
3
votes
2 answers

SQL Server: The server principal is not able to access the database under the current security context / windows authentication for the login

I saw a couple of other questions like this one but no one could solve my issue. I have a SQL 2016 Express and a database mydatabase. I created a login using Windows Authentication and I used my AD user domain\myuser. In mydatabase -> security ->…
3
votes
2 answers

Selinux - File Contexts Look Good, But Selinux Won't Allow Write

I am trying to learn Selinux. With a sandbox and using VSFTPD to experiment with, I have a vsfptd server running in Centos. I have annonmous users to place files in /var/ftp/incoming. On a remote machine I can have the user successfully log in but…
dman
  • 10,406
  • 18
  • 102
  • 201
3
votes
1 answer

Consuming web service with SSL (https) in C#

I want to consume an ssl secured web service in C#. The request looks like this:
user1379434
  • 31
  • 1
  • 1
  • 3
2
votes
2 answers

Why cant I configure POD-level securityContext settings to be applied to all underlying Containers?

In my POD, I wanted to restrict ALL my containers to read-only file systems with securityContext: readOnlyRootFilesystem: true example (note: yaml reduced for brevity) apiVersion: v1 kind: Pod metadata: labels: run: server123 name:…
siwasaki
  • 263
  • 2
  • 9
2
votes
1 answer

How to include security context for running a spark-submit job on kubernetes

I'm using Spark 2.4.5 to run a spark application on kubernetes through the spark-submit command. The application fails while trying to write outputs as detailed here, probably due to an issue with an incorrect security context. So I tried setting up…
Maaverik
  • 161
  • 3
2
votes
1 answer

How does Kubernetes implement Linux capabilities?

Linux capabilities is applied to an executable. If I add capabilities to a container, what does it mean? This is my container securityContext: securityContext: runAsUser: 1008 capabilities: add: - NET_ADMIN - NET_RAW But my task…
Mr Pang
  • 1,083
  • 1
  • 8
  • 20
2
votes
3 answers

Unable to run nginx container as non-root

I am trying to run nginx container as a non-root user I am trying to configure my nginx.conf file, which I am then putting into a k8s configmap, but when the container starts, it keeps throwing errors such as "pid" directive is not allowed here…
Sam-Tahir
  • 191
  • 3
  • 15
2
votes
0 answers

Keycloak java servlet adapter get roles and scopes

I'm currently implementing a webb app with JEE7 on a glassfish 4. With that I'm using Keycloak as a security provider which lead me to use the KeycloakOIDCFilter java servlet filter to get the combo working. For now the login and logout is no…
Felix
  • 43
  • 1
  • 1
  • 7
2
votes
2 answers

In Symfony2 how can I get a users full list of roles

I would like to pass the authenticated users list of roles to my front end apps, so I can use the same access control structure in the front and back end. I was looking in the security / authentication classes as that is where the isGranted function…
mike
  • 1,583
  • 1
  • 19
  • 35
2
votes
1 answer

Spring Security: SecurityContextHolder.getContext().getAuthentication() returns null after user registering user and redirecting to after login page

After user is registered successfully, i am trying to redirect user to after login page and trying to get the Active user from SecurityContextHolder.getContext().getAuthentication(); which is returning null. Here is how i am setting context when…
Giridhar
  • 512
  • 5
  • 20