A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://cloud.google.com/appengine/docs/legacy/standard/python/access-control below:

Setting Up Access Control | App Engine standard environment for Python 2

Skip to main content Setting Up Access Control

Stay organized with collections Save and categorize content based on your preferences.

Access control determines who has permission to access services and resources in a Google Cloud project. In App Engine, there are a few separate use cases for setting up access control:

This page provides an overview of setting up access control in each use case.

For background information on how Google Cloud Platform handles access control, see the overview of Identity and Access Management (IAM).

Granting access to team members

To give a developer access to your Google Cloud project, create one or both of the following:

Creating a user account
  1. Open the IAM page in the Google Cloud console.

    Open the IAM page

  2. Click Select a project, choose a project, and click Open.

  3. Click Add.

  4. Enter an email address.

  5. Select roles that grant access to App Engine features.

    If the user also needs access to other Cloud services, select roles that grant access to other Cloud services.

  6. Click Save.

The user can now sign into Google Cloud console as well as authorize the gcloud CLI.

You can also create user accounts from gcloud, the REST API, or client libraries.

Creating a service account
  1. Open the Service Accounts page in the Google Cloud console.

    Open the Service Accounts page

  2. Select your project and click Open.

  3. Click Create Service Account.

  4. Enter a service account name. This should be a user-friendly name for display.

  5. Click Create.

  6. Select roles that grant access to App Engine features.

    If the service account also needs access to other Cloud services, select roles that grant access to other Cloud services.

  7. Click Continue.

  8. Optionally, specify user accounts who can manage the service account. You can also specify user accounts who can use the service account to indirectly access all the resources to which the service account has access.

  9. Click Save.

    A list of existing service accounts appears.

  10. Optionally, if you need to use your service account outside of Google Cloud, follow the instructions to create a service account key.

Next steps Granting your app access to Cloud services

Every call to a Cloud service needs to be authenticated and authorized, including calls from an App Engine app to other Cloud services such as Cloud Storage.

By default, calls from your App Engine app to services in the same project are authorized. Here's how the default flow works:

  1. To initiate calls to a Cloud service, your app creates a client object, which contains the credentials and other data your app needs to interact with the service. If you don't specify credentials in the client's constructor, the client looks for credentials in the app's environment.

    Here's an example of creating a client for Cloud Storage:

    Go Java Node.js PHP Python Ruby
  2. By default, the app's environment contains credentials from the default App Engine service account.

    This service account is created by Google when you create an App Engine app and is given full permissions to manage and use all Cloud services in a Google Cloud project.

You can override this default flow by doing any of the following:

If you set the GOOGLE_APPLICATION_CREDENTIALS environment variable or pass credentials in your code, we recommend that you store your credentials in one of the following ways:

To learn about the advantages of each approach, see Choosing a secret management solution.

Granting users access to Cloud resources

If you want your app to read user data from another Google service, you'll need to set up OAuth 2.0 for Web Server Applications. For example, if you want to pull a user's data from Google Drive and bring it into your app, use OAuth 2.0 for Web Server Applications to share specific data while keeping other data, such as usernames and passwords, private.

If you have a Google Workspace (formerly G Suite) domain, an administrator of the domain can authorize an application to access user data on behalf of users in the Google Workspace domain. For example, an application that uses the Google Calendar API to add events to the calendars of all users in a Google Workspace domain would use a service account to access the Google Calendar API on behalf of users.

Authorizing a service account to access data on behalf of users in a domain is sometimes referred to as "delegating domain-wide authority" to a service account. This still uses OAuth 2.0, and requires a Google Workspace domain administrator to authorize domain-wide authority to the service account.

Specifying a service account

App Engine lets you use two types of service accounts:

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-08-07 UTC.

[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["Access control in Google Cloud, including App Engine, involves managing permissions for team members, the app itself, and end-users to access services and resources."],["Team members can gain access to a Google Cloud project through user accounts, intended for individuals, or service accounts, designed for applications or processes."],["App Engine apps require authentication and authorization to access other Google Cloud services, typically utilizing a default service account with project-wide permissions unless alternative credentials are provided."],["End-users can be granted access to specific Cloud resources via OAuth 2.0, allowing the app to access user data securely, or through domain-wide delegation for Google Workspace domains."],["App Engine apps use either the default service account, provided automatically, or a user-managed service account, created manually, for identity when interacting with other App Engine services and tasks."]]],[]]


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4