.. _registration server setup/databases: Databases ========= The Registration Server setup will install 2 databases: .. _registration server setup/databases/database "td2reg": Database "td2reg" ----------------- This is the main database with the following tables: .. _registration server setup/databases/database "td2reg"/td2addressrange table: TD2AddressRange table ~~~~~~~~~~~~~~~~~~~~~ Entries to identify users by the ip address (see :ref:`provider concept/user allocation/network allocation`) Columns: * ``ID``: Primary key column * ``OwnerID``: Reference to Owner=Table * ``AddressType``: 0 = API Access, 1 = Clients of the Provider * ``MinAddress``: IP address start * ``MaxAddress``: IP address end * ``RangeSize``: IP range .. _registration server setup/databases/database "td2reg"/td2autotask table: TD2Autotask table ~~~~~~~~~~~~~~~~~ Entries for period tasks (see :ref:`registration server setup/autotasks` for details) Columns: * ``ID``: Primary key column * ``Name``: Name of the task * ``Status``: En= or disabled * ``Description``: Task description * ``RunnerConnID``: ID of the PBAC which is processing the task currently to avoid duplicate execution at the same time by two different PBAC * ``RunnerLoginTime``: Start time * ``LastStartTime``: Start time * ``LastEndTime``: End time * ``LastResult``: Error description * ``ProcedureText``: Function call * ``Frequency``: Frequency in seconds, minutes or hours for tasks which should not run on every PBAC start .. _registration server setup/databases/database "td2reg"/td2blobdata table: TD2BlobData table ~~~~~~~~~~~~~~~~~ Stores blob data which is necessary for update notifications for the clients. Columns: * ``ID:`` Primary key column * ``OwnerID``: Reference to Owner=Table * ``CreationTime``: Creation timestamp * ``ModifyTime``: Modification timestamp * ``Type``: type of the blob. Could be "update", "banner", "email", "csv", "logs". Please notice, that not all types are in use at the moment. A few types are planned for future release. * ``IsActive``: Is entry activated or not * ``Language``: Language for the entry to support banner or update informations in different languages * ``Name``: An internal name for the entry * ``Extension``: Additional field to store non blob information for the entry * ``Data``: The file itself .. _registration server setup/databases/database "td2reg"/td2depots table: TD2Depots table ~~~~~~~~~~~~~~~ Will store the reference to the depots for a user (see Hosting Server Documentation for more info). Columns: * ``ID``: Primary key column * ``UserID``: Reference to User=Table * ``ReposDoc``: Repository document * ``HostUrl``: URL of the Host=Server * ``RepositoryID``: Repository ID * ``IsDefault``: Default repository or not .. _registration server setup/databases/database "td2reg"/td2device table: TD2Device table ~~~~~~~~~~~~~~~ Each client installation will be stored in this table Columns: * ``ID``: Primary key column * ``MD5Password``: Identical to user md5 password * ``Status``: Status of the device * ``User``: Reference to User=Table * ``Name``: Name of the device * ``Ticket``: Reference to ``Ticket=Table`` * ``TicketStatus``: Status of a ticket * ``ActivationCode``: Activation code for device activation * ``PublicKey``: Public key of the device * ``CreationTime``: Creation timestamp * ``ActiveTime``: Last active timestamp * ``IPAddress``: IP address of the device when it was created * ``ClientVersion``: Version of the client installation * ``Platform``: Windows, Mac, Linux, iOS, Android * ``ScreenResolution``: For later use * ``PublicKey2``: The new public key using a RSA 2048 Bit key length .. _registration server setup/databases/database "td2reg"/td2email table: TD2Email table ~~~~~~~~~~~~~~ All emails generated by the clients are stored in this table. One autotask process will send the emails from this table Columns: * ``ID``: Primary key column * ``OwnerID``: Reference to Owner=Table * ``Status``: Status of the mail * ``DestUserID``: Reference to User=Table * ``ErrorMessage``: Error message * ``Destination``: Reference to Device or User=Table (depends on the Template=column) * ``Email``: Destination Email * ``CreationTime``: Creation timestamp * ``SendTime``: Send timestamp * ``Template``: Template name * ``Content``: Mail body in case it's mixed with user data .. _registration server setup/databases/database "td2reg"/td2freeuserstorage table: TD2FreeUserStorage table ~~~~~~~~~~~~~~~~~~~~~~~~ If the referral functionality is enabled, information about additional storage space awarded will be stored here (see :ref:`provider / distributor settings/referral settings` for details). Columns: * ``UserID``: Reference to `User=Table`` * ``InviteFriend``: Additional free storage due to invited users * ``FreeOffset``: An additional free offset (used for old TeamDrive 2 clients) * ``Fixed``: A fixed value (no changes in ``FreeOffset``) .. _registration server setup/databases/database "td2reg"/td2licencetype table: TD2LicenceType table ~~~~~~~~~~~~~~~~~~~~ License types for monthly, yearly, permanent, or not=for=resale licenses Columns: * ``ID``: Primary key column * ``LicenceName``: License name: Permanent, Monthly Payment, Not for Resale, Yearly Payment .. _registration server setup/databases/database "td2reg"/td2message table: TD2Message table ~~~~~~~~~~~~~~~~ This table stores invitations and other messages exchanged between Clients until a Client polls for its messages (see :ref:`teamdrive client <--> server interaction/messages, invitations & invitation types`) Columns: * ``ID``: Primary key column * ``Destination``: Reference to Device table. The device which should receive the message * ``Origin``: Reference to Device table. The device which send the message * ``CreationTime``: Creation timestamp * ``Hash``: Hash to identify a message for the revoke function * ``Content``: Encrypted message body .. _registration server setup/databases/database "td2reg"/td2messagefd table: TD2MessageFD table ~~~~~~~~~~~~~~~~~~ This table stores invitations for devices of a user which will be installed in the future (see :ref:`teamdrive client <--> server interaction/messages, invitations & invitation types/invitation for future devices`) Columns: * ``ID``: Primary key column * ``User``: Reference to the User=Table * ``Origin``: Reference to the Device table * ``CreationTime``: Creation timestamp * ``Hash``: Hash to identify a message for the revoke function * ``Content``: Encrypted message body * ``ClientVersion``: Version of the client .. _registration server setup/databases/database "td2reg"/td2messagesf table: TD2MessageSF table ~~~~~~~~~~~~~~~~~~ This table contains store-forward invitations for new users which don't have an account yet, but have been invited by an existing user to join one of his Spaces (see :ref:`teamdrive client <--> server interaction/messages, invitations & invitation types/store forward invitation`) Columns: * ``ID``: Primary key column * ``Email``: Email of the invited user * ``Origin``: Reference to the Device table * ``CreationTime``: Creation timestamp * ``Hash``: Hash to identify a message for the revoke function * ``Content``: Encrypted message body * ``ClientVersion``: Version of the client .. _registration server setup/databases/database "td2reg"/td2owner table: TD2Owner table ~~~~~~~~~~~~~~ The table for the Provider entries (see :ref:`provider concept`) Columns: * ``ID``: Primary key column * ``LoginName``: Loginname * ``MD5Password``: MD5 Password * ``Language``: Language of the Provider * ``FirstName``: Firstname of the Provider * ``LastName``: Lastname of the Provider * ``Email``: Email of the Provider * ``WorkPhone``: Phone number of the Provider * ``CreationDate``: Creation timestamp * ``Gender``: Gender m(ale)/f(emale) * ``Address``: Address of the Provider * ``City``: City of the Provider * ``PostalCode``: PostalCode of the Provider * ``Country``: Country of the Provider * ``Company``: Company of the Provider * ``TicketPrefix``: 4 letter Provider Code * ``LicenseEmail``: CC=Email for license creation .. _registration server setup/databases/database "td2reg"/td2ownerlicencetype table: TD2OwnerLicenceType table ~~~~~~~~~~~~~~~~~~~~~~~~~ Which Provider can use which license types for host licences Columns: * ``IDOwner``: Reference to Owner table * ``IDLicenceType``: Reference to LicenseType table TD2OwnerMeta table ~~~~~~~~~~~~~~~~~~~ A key=value table to store different Provider settings as described in (see :ref:`provider / distributor settings`) Columns: * ``ID``: Primary key column * ``OwnerID``: Reference to Owner table * ``Name``: Name of the key * ``Value``: Value of the key TD2OwnerMetaSetting table ~~~~~~~~~~~~~~~~~~~~~~~~~~ A template table to store all available settings which could be chosen as a new parameter for an entry in ``TD2OwnerMeta``. Columns: * ``ID``: Primary key column * ``Grouping``: A group entry * ``Name``: Name of the key * ``DefaultValue``: A default value of the key. Will be used if a new entry will be created in ``TD2OwnerMeta`` or if the key in ``TD2OwnerMeta`` is missing. * ``Description``: A description for this value * ``ReadOnly``: Is the entry read only when editing a ``TD2OwnerMeta`` value * ``Visible``: Is the entry visible * ``IsUnique``: Is only one entry per provider in ``TD2OwnerMeta`` allowed * ``Deletable``: Is the entry in ``TD2OwnerMeta`` deletable * ``Type``: Data type * ``Format``: A regular expression to validate the user input * ``CreationTime``: Creation timestamp * ``ModifyTime``: Modification timestamp .. _registration server setup/databases/database "td2reg"/td2ownerproduct table: TD2OwnerProduct table ~~~~~~~~~~~~~~~~~~~~~ Which Provider can create which licenses for the client and/or TDPS Columns: * ``IDOwner``: Reference to Owner table * ``IDProduct``: Reference to Product table .. _registration server setup/databases/database "td2reg"/td2parcel table: TD2Parcel table ~~~~~~~~~~~~~~~ The key repository table to store space access data for the users on the server. Columns: * ``ID``: Primary key column * ``UserID``: Reference to the ``TD2User`` table * ``Type``: user=private=key, user=public=key or space=key * ``Status``: 1 = active, 2 = archived, 3 = backed up * ``CreationTime``: Creation timestamp * ``ModifyTime``: Modification timestamp * ``PublicKeyID``: Reference to the "user=public=key"=type for a user in this table * ``GlobalID``: An internal global ID * ``Content``: The key data .. _registration server setup/databases/database "td2reg"/td2product table: TD2Product table ~~~~~~~~~~~~~~~~ The list of products which are available to create licenses Columns: * ``ID``: Primary key column * ``ProductName``: Name of the product (TeamDrive Client, TeamDrive Personal Server) .. _registration server setup/databases/database "td2reg"/td2regserverlist table: TD2RegServerList table ~~~~~~~~~~~~~~~~~~~~~~ Table with available Registration Server within the TDNS. List will be updated by an autotask process from a server of TeamDrive Systems GmbH. Only active if TDNS usages is activated see :ref:`teamdrive name server (tdns)`) Columns: * ``ID``: Primary key column * ``RegServerName``: Name of the Registration Server * ``CreationTime``: Creation timestamp * ``ModifyTime``: Modification timestamp * ``Enabled``: White= or blacklisted * ``Data``: Data block * ``AuthSequence``: Authorization sequence .. _registration server setup/databases/database "td2reg"/td2setting table: TD2Setting table ~~~~~~~~~~~~~~~~ A key=value table to store different global settings for the server as described in :ref:`registration server settings`. Columns: * ``ID``: Primary key column * ``Grouping``: Field to group values in the GUI * ``Name``: Name of the key * ``Value``: Value of the key * ``Description``: Description of the field * ``ReadOnly``: Readonly attribute * ``Visible``: Visible attribute * ``Type``: Data type (boolean, varchar, integer) * ``Format``: A regular expression to validate the user input * ``CreationTime``: Creation timestamp * ``ModifyTime``: Modification timestamp .. _registration server setup/databases/database "td2reg"/td2ticket table: TD2Ticket table ~~~~~~~~~~~~~~~ The license keys for the clients Columns: * ``ID``: Primary key column * ``Number``: License number * ``MD5Password``: MD5Password to allow administration of the license by the user * ``Type``: Reference to LicenseType table * ``Status``: Status of the license * ``Owner``: Reference to Owner table * ``ContractNumber``: Free text field * ``HolderEmail``: License email * ``Language``: Language * ``TimeLimit``: Time limitation for the license * ``ValidUntil``: A fixed valid timestamp * ``LicenseLimit``: Single or Multi=User license value * ``LicenseUsed``: License in use * ``FeatureFlag``: Combination of Banner, WebDAV, Personal and/or Professional * ``CreationTime``: Creation timestamp * ``UserID``: Reference to User table if license is bound to a user * ``Product``: TeamDrive Client or TDPS * ``IsDefault``: Default license * ``ExtReference``: Free text field to store an external reference .. _registration server setup/databases/database "td2reg"/td2ticketchanges table: TD2TicketChanges table ~~~~~~~~~~~~~~~~~~~~~~ A history table with all changes made to license keys (amount of seats changed or changed features) Columns: * ``ID``: Primary key column * ``Ticket``: Reference to Ticket table * ``WhatChanged``: Information what changed * ``ChangeDate``: Change date * ``ChangeID``: Text field with change information * ``Status``: The original ``status`` * ``ContractNumber``: The original ``ContractNumber`` * ``HolderEmail``: The original ``HolderEmail`` * ``ValidUntil``: The original ``ValidUntil`` * ``LicenseLimit``: The original ``LicenseLimit`` * ``FeatureFlag``: The original ``FeatureFlag`` * ``LicenseKey``: The original ``LicenseKey`` .. _registration server setup/databases/database "td2reg"/td2user table: TD2User table ~~~~~~~~~~~~~ A table with all registered users Columns: * ``ID``: Primary key column * ``CreationTime``: Creation timestamp * ``UserName``: Username * ``TdnsUserName``: The hashed Username for TDNS * ``Email``: Email * ``ExtReference``: Free text field to store an external reference * ``Department``: Free text field * ``ExtAuthID``: External ID. Will be set when using external authentication (see :ref:`external authentication`) * ``AllowEmailSearch``: Not longer used * ``MD5Password``: Salted MD5Password of the user * ``Language``: Language of the user * ``EmailDay``: Date when the last mail was sent * ``EmailCount``: How many mails were send by this user a the ``EmailDay`` * ``TmpPwd``: Temporary password for lost password function * ``TmpEmail``: New Email until email is confirmed by the link * ``TmpSession``: Used during registration process * ``Status``: Status of the user * ``InvitedBy``: Reference to the user which invited this user * ``OwnerID``: Reference to Owner table * ``Capability``: User settings to enable or disable certain functionality .. _registration server setup/databases/database "td2reg"/td2userprivileges table: TD2UserPrivileges table ~~~~~~~~~~~~~~~~~~~~~~~ Assigned privileges for users for the access to the Admin Console Columns: * ``userId`` * ``flagList`` .. _registration server setup/databases/database "td2reg"/td2userprivilegessetting table: TD2UserPrivilegesSetting table ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Available privileges for users for the access to the Admin Console Columns: * ``ID`` * ``Grouping`` * ``Name`` * ``Description`` * ``CreationTime`` * ``ModifyTime`` .. _registration server setup/databases/database "td2reg"/keys table: Keys table ~~~~~~~~~~ This table stores the all keys for the Registration Server. The private and public key of this Registration Server and all public keys of the clients will be stored in this database. Prior to version 3.0.017, this table was stored in a separate database named "pbpg". Columns: * ``Code``: Primary key column * ``UniqueDevice``: Unique devicename within the TDNS network * ``Version``: Public key version * ``CreationTime``: Creation timestamp * ``Data``: Public key of the device .. _registration server setup/databases/database "td2apilog": Database "td2apilog" -------------------- A database with one "``TD2APIRequests``"=table. API calls can be logged in this table to identify problems when using the Registration Server API interface (look in :ref:`registration server settings` for the part about request logging). Columns: * ``ID``: Primary key column * ``Created``: Creation timestamp * ``IPAddress``: IP of the request * ``Command``: API function call name * ``User``: Username * ``Request``: XML from the request * ``Answer``: XML which was send back