Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 14 for checkPermissions (0.2 sec)

  1. cmd/kubelet/app/server_others.go

    See the License for the specific language governing permissions and
    limitations under the License.
    */
    
    package app
    
    import (
    	"fmt"
    	"os"
    )
    
    func checkPermissions() error {
    	if uid := os.Getuid(); uid != 0 {
    		return fmt.Errorf("kubelet needs to run as uid `0`. It is being run as %d", uid)
    	}
    	// TODO: Check if kubelet is running in the `initial` user namespace.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Aug 24 19:47:49 UTC 2021
    - 951 bytes
    - Viewed (0)
  2. cmd/kubelet/app/server_windows.go

    limitations under the License.
    */
    
    package app
    
    import (
    	"errors"
    	"os/user"
    
    	"golang.org/x/sys/windows"
    	"k8s.io/klog/v2"
    )
    
    func checkPermissions() error {
    
    	u, err := user.Current()
    	if err != nil {
    		klog.ErrorS(err, "Unable to get current user")
    		return err
    	}
    
    	// For Windows user.UserName contains the login name and user.Name contains
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 24 21:57:08 UTC 2022
    - 1.2K bytes
    - Viewed (0)
  3. cluster/images/etcd/migrate/integration_test.go

    				if !v.Equals(end) {
    					t.Errorf("Expected version.txt to contain %s but got %s", end, v)
    				}
    				// Integration tests are run in a docker container with umask of 0022.
    				checkPermissions(t, server.cfg.dataDirectory, 0755|os.ModeDir)
    				checkPermissions(t, dataDir.versionFile.path, 0644)
    			})
    		})
    	}
    }
    
    func parallel(servers []*EtcdMigrateServer, fn func(server *EtcdMigrateServer)) {
    	var wg sync.WaitGroup
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Mar 28 07:33:23 UTC 2022
    - 11.4K bytes
    - Viewed (0)
  4. cmd/update.go

    	}
    	defer updateInProgress.Store(0)
    
    	transport := getUpdateTransport(30 * time.Second)
    	opts := selfupdate.Options{
    		Hash:     crypto.SHA256,
    		Checksum: sha256Sum,
    	}
    
    	if err := opts.CheckPermissions(); err != nil {
    		return AdminError{
    			Code:       AdminUpdateApplyFailure,
    			Message:    fmt.Sprintf("server update failed with: %s, do not restart the servers yet", err),
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 18.7K bytes
    - Viewed (0)
  5. cmd/kubelet/app/server.go

    			kubeletDeps, err := UnsecuredDependencies(kubeletServer, utilfeature.DefaultFeatureGate)
    			if err != nil {
    				return fmt.Errorf("failed to construct kubelet dependencies: %w", err)
    			}
    
    			if err := checkPermissions(); err != nil {
    				klog.ErrorS(err, "kubelet running with insufficient permissions")
    			}
    
    			// make the kubelet's config safe for logging
    			config := kubeletServer.KubeletConfiguration.DeepCopy()
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 07 00:05:34 UTC 2024
    - 53.9K bytes
    - Viewed (0)
  6. platforms/core-execution/workers/src/test/groovy/org/gradle/process/internal/worker/child/BootstrapSecurityManagerTest.groovy

            when:
            securityManager.checkPermission(new AllPermission())
    
            then:
            1 * cl.addURL(entry1.toURI().toURL())
            1 * cl.addURL(entry2.toURI().toURL())
            0 * cl._
            System.getProperty("java.class.path") == [entry1.absolutePath, entry2.absolutePath].join(File.pathSeparator)
    
            when:
            securityManager.checkPermission(new AllPermission())
    
            then:
            0 * cl._
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Sep 22 09:36:27 UTC 2023
    - 4.1K bytes
    - Viewed (0)
  7. platforms/core-execution/worker-main/src/main/java/org/gradle/process/internal/worker/child/BootstrapSecurityManager.java

        public BootstrapSecurityManager() {
            this(null);
        }
    
        BootstrapSecurityManager(URLClassLoader target) {
            this.target = target;
        }
    
        @Override
        public void checkPermission(Permission permission) {
            synchronized (this) {
                if (initialised) {
                    return;
                }
                if (System.in == null) {
                    // Still starting up
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu May 23 05:58:56 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/util/concurrent/AbstractFutureInnocuousThreadTest.java

            new PropertyPermission("guava.concurrent.generate_cancellation_cause", "read");
        SecurityManager disallowPropertySecurityManager =
            new SecurityManager() {
              @Override
              public void checkPermission(Permission p) {
                if (readSystemProperty.equals(p)) {
                  throw new SecurityException("Disallowed: " + p);
                }
              }
            };
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Dec 16 19:54:45 UTC 2020
    - 5.1K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/util/concurrent/CallablesTest.java

            new SecurityManager() {
              @Override
              public void checkAccess(Thread t) {
                throw new SecurityException();
              }
    
              @Override
              public void checkPermission(Permission perm) {
                // Do nothing so we can clear the security manager at the end
              }
            });
        try {
          final String oldName = Thread.currentThread().getName();
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Feb 13 14:28:25 UTC 2024
    - 5.4K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/util/concurrent/CallablesTest.java

            new SecurityManager() {
              @Override
              public void checkAccess(Thread t) {
                throw new SecurityException();
              }
    
              @Override
              public void checkPermission(Permission perm) {
                // Do nothing so we can clear the security manager at the end
              }
            });
        try {
          final String oldName = Thread.currentThread().getName();
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Feb 13 14:28:25 UTC 2024
    - 5.4K bytes
    - Viewed (0)
Back to top