Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin McCorkell <rmccorkell@owncloud.com>2015-08-24 18:13:16 +0300
committerRobin Appelman <icewind@owncloud.com>2016-01-18 13:10:41 +0300
commitda4127d23b168dbb34c066d9590b3fe1b965af46 (patch)
tree22d3ac5060211b44a305c989c88ee9896a9870ad /db_structure.xml
parent88cd61521459a18599407f83347f1d6a0e7700cc (diff)
Introduce CredentialsManager for storage of credentials in DB
CredentialsManager performs a simple role, of storing and retrieving encrypted credentials from the database. Credentials are stored by user ID (which may be null) and credentials identifier. Credentials themselves may be of any type that can be JSON encoded. The rationale behind this is to avoid further (mis)use of oc_preferences, which was being used for all manner of data not related to user preferences.
Diffstat (limited to 'db_structure.xml')
-rw-r--r--db_structure.xml55
1 files changed, 55 insertions, 0 deletions
diff --git a/db_structure.xml b/db_structure.xml
index e4bd8d998ee..cfda315e3c2 100644
--- a/db_structure.xml
+++ b/db_structure.xml
@@ -1493,5 +1493,60 @@
</table>
+ <table>
+ <!--
+ Encrypted credentials storage
+ -->
+ <name>*dbprefix*credentials</name>
+
+ <declaration>
+
+ <field>
+ <name>user</name>
+ <type>text</type>
+ <default></default>
+ <notnull>false</notnull>
+ <length>64</length>
+ </field>
+
+ <field>
+ <name>identifier</name>
+ <type>text</type>
+ <notnull>true</notnull>
+ <length>64</length>
+ </field>
+
+ <field>
+ <name>credentials</name>
+ <type>clob</type>
+ <notnull>false</notnull>
+ </field>
+
+ <index>
+ <name>credentials_user_id</name>
+ <primary>true</primary>
+ <unique>true</unique>
+ <field>
+ <name>user</name>
+ <sorting>ascending</sorting>
+ </field>
+ <field>
+ <name>identifier</name>
+ <sorting>ascending</sorting>
+ </field>
+ </index>
+
+ <index>
+ <name>credentials_user</name>
+ <unique>false</unique>
+ <field>
+ <name>user</name>
+ <sorting>ascending</sorting>
+ </field>
+ </index>
+
+ </declaration>
+
+ </table>
</database>