How XmlSecure Works



XMLSecure is a multi user XML Data Base Management System. The components of XmlSecure are:

  1. XmlSecured - The DBMS Daemon
  2. xmlSecure    - The Client

XmlSecured:

            The Daemon runs on a predefined (23456) port. It handles all the Query requests. This has all the Databases and tables under it.


xmlSecure:

            This is the client. This connects to the daemon and gives the queries and gets back the result. This acts as an interface between the user and the DBMS.


The File Organization:

            The internal file structure of xmlsecure dbms is as follows,

            Xml Secure Home
                |
                |------ bin
                |
                |------ conf
                |
                |------ databases
                            |
                            |------ shop
                            |
                            |------ sample
                            |
                            |------ ... (Each user created databases has a directory by its name)
                                            |
                                            |------(Each Table in this database has a directory by its name)
                                                         |
                                                         |------ config      (Has the classes and data structures needed by this table)
                                                         |
                                                         |------ data          (Stores data of the table)
                                                                    |
                                                                    |------ data.xml        (This xml file contains the entire data of the table)




The following are the commands in xmlsecure:



Command
Explanation
showdb
Shows all present dbs
usedb  <dbname>
Choose a db to use
showtables
Show all tables present in present db
usetable  <tablename>
Use this table
select
Select data from the present table
   (Only records with security level equal to or less than the present user level will be listed)
createdb  <dbname>
Create a db with the specified name
createtable  <tablename>
Create a table with the specified name (tablename should be a dtd filename)
insert  <xmlfile>
Insert the xml file into the present table
createuser  <username>  <password>  <user level>
Create a user with specified username, password and user level
user  <username>  pass  <password>
Switch to another user, without changing the present working environment
bye
Terminates the session