バージョンごとのドキュメント一覧

第22章 データベースロール

目次

22.1. データベースロール
22.2. ロールの属性
22.3. ロールのメンバ資格
22.4. ロールの削除
22.5. 定義済みロール
22.6. 関数のセキュリティ
<title>Database Roles</title>

<productname>PostgreSQL</productname> manages database access permissions using the concept of <firstterm>roles</firstterm>. A role can be thought of as either a database user, or a group of database users, depending on how the role is set up. Roles can own database objects (for example, tables and functions) and can assign privileges on those objects to other roles to control who has access to which objects. Furthermore, it is possible to grant <firstterm>membership</firstterm> in a role to another role, thus allowing the member role to use privileges assigned to another role. PostgreSQLは、ロールという概念を使用してデータベースへの接続承認を管理します。 ロールは、その設定方法に応じて、データベースユーザ、またはデータベースユーザのグループとみなすことができます。 ロールはデータベースオブジェクト(例えばテーブルや関数)を所有することができます。 またロールは、どのオブジェクトに誰がアクセスできるかを制御するために、それらのオブジェクトに対しての権限を他のロールに割り当てることができます。 更に、ロールのメンバ資格を他のロールに与えることもできます。 そのため、メンバとなったロールは別のロールに割り当てられた権限を使用することができます。

The concept of roles subsumes the concepts of <quote>users</quote> and <quote>groups</quote>. In <productname>PostgreSQL</productname> versions before 8.1, users and groups were distinct kinds of entities, but now there are only roles. Any role can act as a user, a group, or both. ロールの概念には、ユーザという概念とグループという概念が含まれます。 PostgreSQLバージョン8.1より前まででは、ユーザとグループは異なる種類の実体として扱われていました。 しかし、現在ではロールしか存在しません。 すべてのロールは、ユーザとして、グループとして、またはその両方として動作することができます。

This chapter describes how to create and manage roles. More information about the effects of role privileges on various database objects can be found in <xref linkend="ddl-priv"/>. 本章では、ロールの作成と管理の方法について説明します。 様々なデータベースオブジェクト上の権限の効果について、さらに詳細な情報は5.7に記載されています。