Last week I spent most of my time studying the application and try to solve the application problem.

Let us first go into the problems that I have discover in the application first.

revoking the certificate twice

This event is highly unlikely to occur, but there is a thin chance of it happening. Previously I used the email address of the user to store their certificate in the approot. In the revoke directory of approot, I have also used the same naming convention just to reduce the complexity of my revoke code. When a certificate is revoked, the certificate in the active root will be removed and a copy of the certificate will be stored in the revoke directory. The code that I have currently applied works fine if the certificate is only revoked once. If the user use the same email address to create another certificate, which so happens to be revoked again, the system will crash due to the presence of previous certificate in the revoked directory of approot.

I have thought of two different ways to solve this problem which is the lazy way. First solution is to check if there is any folder with the same email address. If such folder is found, then the folder is deleted and replaced by the second revoked certificate. This method is unacceptable because we must have a copy of all the revoked certificate for future references. The second method that I have come up is to prevent the user from creating the certificate with the same email address again. But this will cause inconveniences to the user because he will never create a certificate again in this application.A better solution is provided by Dr Shawn is to add the date of revocation to the name of the file in the revoke directory. i will implement this to the application to prevent the system to crash again.

Decode signal not Exposed

Trying to solve this problem that I mentioned earlier in my previous blog post in this week. Until now I still cant figure out what is the signal that should have exposed in order to trigger the message box. I have searched the web and learned the fact that message box or dialog will stop any signal that is transmitted in the back of the message box. But in my application, that is not the case, I have tried to remove the message box and just add a simple set text to it and the signal is still not exposed. I believe that the problem is originated from the place I called the signal. I called the signal in the handle Http response void. I do not understand why but when I try to call signal or transfer any data from the void, I will face the same problem. To solve the problem, I simply used JQuery post request to replace the witty client post request as suggested by Islam.

Closing the Browser Window

Previously, I have tried to use the Wt::Application::Quit() function to quit the application but not closing the browser Window. so I went to the web to search for the solution to close the browser window. I have found a nice and sweet code”,’_self’).close();

but this code will only work in firefox browser and do not work on chrome browser. then me and Dr Shawn have decided to not close the browser window and just redirect the user to a thank you page.

File System Limitation

Getting back to last week file system research, I have found out that the limit of subdirectories of the ext3 file system is 32,000 from this website which is not a impressive number of certificate that can hold by the system that I have build. on the other hand, the ext4 file systems limit subdirectories is 2x of ext3 file system which is 64,000 according to this. I have also tried to search for the limit number of subdirectories in XFS file system. So far I have not found the hard limit of this file system but I believe that this file system will have a significantly higher limits compare to ext3 and ext4. To store the certificate efficiently in the file system. It will be wise to separate the large number of files into different subdirectories compare to throwing everything in one directory(which is what the application is doing for now). I will restructure the whole system to store this file efficiently to allow more certificate to e created.

It is almost the end of my internship program so this week I will be concentrating my attention to the file storage system of the application. I hope that I will be able to finish the basic structure of the application by the end of my Internship.



Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.