Thursday, January 26, 2012

Securing your Facebook account.

                            Facebook been a lifestyle for majority of people. Almost all of us own a facebook account. Also we hear news about hackers being active in hacking your Facebook account. In this article I am presenting you a way by which you can be notified if your Facebook account is accessed by any other person or unauthorized person.
                               If anyone accesses your Facebook account then you can get an alert message informing you about it in your mobile phone or in your e-mail account. For this you need to provide your e-mail (that is your login e-mail) and add your mobile phone number in your Facebook profile. Then follow following steps.

1. First login into your Facebook account
2. At the top right corner click on down arrow and click on 'Account Settings'.

3. If you haven't added your mobile phone number in your Facebook account then you will need to add it else you can directly jump into step 8 below. To add mobile phone you need to follow following two steps mentioned in picture. You can get this webpage directly after clicking 'Account Settings' and clicking on 'Mobile' in left hand side of your screen. Follow Step:1 and Step:2 mentioned in following picture.

4. After clicking '+ Add a Phone' you will get a dialog box as below. You will need to choose your country and then click 'Add your phone number here'.



5. Then after that another dialog box will appear like below where you have to choose your country from the drop down list and enter your mobile number and don't forget to mark 'Send me a text' option.




6.  After that Facebook will send you a text in your mobile phone (in the mobile number you entered in above step ) containing a code which you will need to enter in a text box contained in a dialog box like below (this dialog box will appear as soon as you submit your mobile number).



7. If you didn't get the code then click on ' I didn't get my code' below the text box. Then you will need to repeat step 5 again. Else after sometime when you get the confirmation code you can enter the confirmation code by going back into your profile then 'Account Settings'--->'Mobile' and entering your confirmation code in a text box in the right hand side of your screen.



8. After adding your mobile phone in your Facebook account go back to 'Account Settings' then click on 'Security' on left hand side of your screen.


9. Then you can see 'Login Notifications' in the right hand side. You will need to enable it if it is disabled. You will need to click on 'Edit' sign on the right side of 'Login Notifications' as shown below.


10. Then check mark 'Email' to get your login notifications in your e-mail id or 'Text Message/Push notification' to get login notification in your mobile phone and click 'Save Changes'.

11. Then save these change. The next time when you or anyone else login into your account after sign in you will be provided this page where you need to enter the 'Device Name'. Device name is like a password (don't enter your Facebook password) which will be known to you only. You can use 100 different 'Device Names'. But use only one device name. For e.g. below I have entered Device name as 'hero123' and click on 'Save Device'.

12. Then after that I will get an e-mail or text message in my mobile phone as shown below.

        So by this process you will be notified whether your Facebook account is accessed by other users or not. Only you will know the correct Device Name and others will not know it. If they enter any Device Name other than you use then you can get notified of it. Else if the 'Device Name' is left empty and Clicked on 'Don't Save' option, then you get message as "An unknown device logged into your Facebook account..". Hence this method might not permanently protect your Facebook account but at least it will inform you if any other people tries to access it.



Friday, January 20, 2012

CPM VS. PERT



CPM stands for Critical Path Method and PERT stands for Program Evaluation and Review Technique. These are network techniques used to aid in the planning, scheduling, monitoring, and control of activities which are related to each other. CPM is frequently used in the construction industry to help organize and schedule those activities which together constitute a given construction project. PERT was first used to help coordinate the activities in the development of the Polaris missile system.CPM and PERT are two powerful tools for faster and more efficient completion of complex projects. Both methods show precedence relationships explicitly. Although the two methods were developed independently during the fifties, they are surprisingly similar. Both methods, PERT and CPM, use a graphic representation of a project that it is called "Project Network" or "CPM diagram", and it is used to portray graphically the interrelationships of the elements of a project and to show the order in which the activities must be performed.

PERT
There is high degree of uncertainty pertaining to completion time of certain activities. Particularly in research and development projects, it is difficult to gauge the time the project will take to complete. In such cases we can take probabilistic approach for each activity and define optimistic time estimate, most likely time estimate and pessimistic time estimate. With expected time for each activity, it is possible to determine the critical path. Thus PERT is a probabilistic tool that makes use of 3 estimates for completion of activities and is a tool for planning and control of time for completion of a project.
  Another derivative of the GANTT chart
  Multiple time estimates were used for each activity that allowed for variation in activity times
  Activity times are assumed to be random, with assumed probability distribution ("probabilistic")
  Activities are represented by arrowed lines between the nodes or circles
CPM
CPM on the other hand is a deterministic tool taking only a single estimate of time for completion of any activity in a project. It also allows for estimate of costs, thereby being a tool that can control both time as well as costs.
  • Tool to analyze project and determine duration, based on    identification of "critical path" through an activity network.
  • Knowledge of the critical path can permit management of the project to change duration.
  • A single estimate for activity time was used that did not allow for variation in activity times
  • Activity times are assumed to be known or predictable ("deterministic")
  • Activities are represented as nodes or circles
PERT(Program Evaluation and Review Technique)
CPM (Critical Path Method)
1) PERT is a probabilistic tool used with three estimating the duration for completion of estimate of duration.

1) CPM is a deterministic tool, with only single activities.

2) This tool is basically a tool for planning and control of time.
2) CPM also allows and explicit estimate of
costs in addition to time, therefore CPM can
control both time and cost.

3) In routine projects where estimated time for each activity is known, CPM is a better tool to control both time and cost than PERT.
3) In routine projects where estimated time for each activity is known, CPM is a better tool to control both time and cost.



4) The probability factor i major in PERT so outcomes may not be exact.
4) The deterministic factor is more so values or outcomes are generally accurate and
realistic.



5) Where the estimation of time for each activity is difficult such as R&D, PERT is a more suitable method




5) Where the estimation of time for each activity is difficult such as R&D, CPM is a not suitable method


Implementation of HANGMAN using C


            Hangman is a paper and pencil guessing game for two or more players. One player thinks of a word and the other tries to guess it by suggesting letters.
The word to guess is represented by a row of dashes, giving the number of letters. If the guessing player suggests a letter which occurs in the word, the other player writes it in all its correct positions. If the suggested letter does not occur in the word, the other player draws one element of the hangman diagram as a tally mark.The game is over when:
  • The guessing player completes the word, or guesses the whole word correctly
  • The other player completes the diagram
                                                                                                                                                                   I have developed simple yet useful program called "HANGMAN" using Borland C. The main objective of developing this software is to utilize the knowledge of C in developing a simple and useful program, useful to someone.
This game is made on Graphical User Interface mode allowing a colorful and attractive user friendly interface. In this game user is displayed following options:
1.      PLAY: To play a new game.
2.      INSTRUCTIONS: To display rules of game.
3.      CATEGORY: To allow user choose his choice of category from which the word would be provided to guess.
4.      QUIT: To exit the game.



The output of the game is like below:
          
1. The welcome screen of the game.



2. The Menu

3. Category Selection Screen


4.The Instruction Screen



5. Game Playing Screen

6. Winning Applause Screen.





7. Failure Screen













8. Game Closing Screen

Thursday, January 19, 2012

Component Based Software Engineering


This approach is based on the existence of a significant number of reusable components. The system development process focuses on integrating these components into a system rather than developing them from scratch.
fig: Reuse oriented development
The Reuse-based development is based on the systematic reuse of systems where they are integrated from existing components or COTS (Commercial-off-the-shelf) systems.  Therefore the final product is assembled using existing components. It emerged from the failure of object-oriented development to support effective reuse. Single object classes are too detailed and specific. Components are more abstract than object classes and can be considered to be stand-alone service providers.
Advantages
1.      Minimization of cost and risk,
2.      Management of Complexity
3.      Reduce Development Time
4.      Increased Productivity
5.      Improved Quality

 Disadvantages
1.                  Development of Components
2.                  Lack of Components
3.                  Component Maintenance Costs
4.                  Reliability and Sensitivity to changes
5.            Unsatisfied Requirements- how do we trade-off analysis between the features of one   component and another?
6.                  Trust – how can a component with no available source code be trusted?

Generic Software Process Model:Evolutionary development


1.      This approach interleaves the activities of specification, development and validation. An initial system is rapidly developed from abstract specifications. This is then refined with customer input to produce a system that satisfies the customer's needs.
fig: Evolutionary development
The waterfall model is viable for software products that do not change very much once they are specified. But for software products that have their feature sets redefined during development because of user feedback and other factors, the traditional waterfall model is no longer appropriate.
- The Evolutionary EVO development model divides the development cycle into smaller, incremental waterfall models in which users are able to get access to the
product at the end of each cycle.
- Feedback is provided by the users on the product for the planning stage of the next cycle and the development team responds, often by changing the product, plans, or process.
- These incremental cycles are typically two to four weeks in duration and continue until the product is shipped.
There are two fundamental types of evolutionary development:
2.1 Exploratory development where the objective of the process is to work with the customer to explore their requirements and deliver a final system. The development starts with the parts of the system that are understood. The system evolves by adding new features proposed by the customer.
2.2 Throwaway prototyping where the objective of the evolutionary development process is to understand the customer's requirements and hence develop a better requirements definition for the system. The prototype concentrates on the experiencing with the customer requirements that are poorly understood.
Advantages
- Benefit not only business results but marketing and internal operations as well.
- Use of EVO brings significant reduction in risk for software projects.
- EVO can reduce costs by providing a structured, disciplined avenue for experimentation.
- EVO allows the marketing department access to early deliveries, facilitating development of documentation and demonstrations.
- Short, frequent EVO cycles have some distinct advantages for internal processes and people considerations.
- The cooperation and flexibility required by EVO of each developer results in greater teamwork.
- Better fit the product to user needs and market requirements.
- Manage project risk with definition of early cycle content.
- Uncover key issues early and focus attention appropriately.
- Increase the opportunity to hit market windows.
- Accelerate sales cycles with early customer exposure.
- Increase management visibility of project progress.
- Increase product team productivity and motivation.
 Disadvantages
-                           The process is not visible. Mangers need to regular deliverables to measure progress. If systems are developed quickly, it is not cost-effective to produce documents that reflect every version of the system.
-                           Systems are often poorly structured: Continual change tends to corrupt the software structure. Incorporating software changes becomes increasingly difficult and costly.
Applicability
-                           For small or medium-size interactive systems.
-                           For parts of large systems (e.g. the user interface)
-                           For short lifetime systems.

Generic Software Process Model:The waterfall model


A software process is a set of activities that leads to the production of a software product. These activities may involve the development of software from scratch in a standard programming language like JAVA or C.  A software process model is an abstract representation of a software process. Each process model represents a process from a particular perspective, and thus provides only partial information about that process.
            The generic software process models are not definitive descriptions of software processes. Rather, they are abstractions of the process that can be used to explain different approaches to software development. We can think of them as process frameworks that may be extended and adapted to create more specific software engineering processes.
1.      The waterfall model
This takes the fundamental process activities of specification, development, validation and evolution and represents them as separate process phases such as requirements specification, software design, implementation, testing and so on.
Fig: Waterfall Model
The waterfall model derives its name due to the cascading effect from one phase to the. In this model each phase well defined starting and ending point, with identifiable deliveries to the next phase. This model is sometimes referred to as the linear sequential model or the software life cycle.
The model consists of six distinct stages, namely:
1.1     In the requirements definitions phase:
(a)    The problem is specified along with the desired service objectives (goals)
(b)   The constraints are identified
They are then defined in detail and serve as a system specification.

            1.2 System & Software design phase:
The system design process partitions the requirements to either hardware or software systems. It establishes overall system architecture. Software design involves identifying and describing the fundamental software system abstractions and their relationships.
            1.3 Implementation and unit testing phase:
In this stage, the software design is realized as a set of programs or program units. Unit testing involves verifying that each unit meets its specification.
            1.4 Integration and system testing phase:
The individual program units or programs are integrated and tested as a complete system to ensure that the software requirements have been met. After testing, the software system is delivered to the customer.
            1.5 Operation and maintenance phase:
This is the longest phase. The system is installed and put into practical use. Maintenance involves correcting errors which were not discovered in earlier stages of the life cycle, improving the implementation of system units and enhancing the system's services as new requirements are discovered.
The Waterfall method is expensive and is very time consuming because it was designed to minimize the use of very expensive computing resources. The Waterfall model describes a process of stepwise refinement.  It is widely used in military and aerospace industries.
            Advantages
·        Testing is inherent to every phase of the waterfall model
·        It is an enforced disciplined approach
·        It is documentation driven, that is, documentation is produced at every stage
 
 Disadvantages
  The waterfall model is the oldest and the most widely used paradigm. However, many projects rarely follow its sequential flow. This is due to the inherent problems associated with its rigid format. Namely:
·        It only incorporates iteration indirectly, thus changes may cause considerable confusion as the project progresses. 
·        As The client usually only has a vague idea of exactly what is required from the software product, this WM has difficulty accommodating the natural uncertainty that exists at the beginning of the project.
·        The customer only sees a working version of the product after it has been coded. This may result in disaster any undetected problems are precipitated to this stage.
·        Inflexible partioning of the project into distinct stages makes it difficult to respond to changing customer requirements.
·    Only appropriate when the requirements are well-understood and changes will be fairly limited during the design process.
·        Mostly used for large systems engineering projects where a system is developed at several sites.

Layered model of legacy system.


An alternative way of looking at these components of a legacy system is as a series of layers as shown in figure below. Each layer depends on the layer immediately below it and interfaces with that layer. If interfaces are maintained, then we should be able to make changes within a layer without affecting either of the adjacent layers. In practice, however, this simple encapsulation is an over-simplification, and changes to one layer of the system may require consequent changes to layers that are both above and below the changed level. The reasons for this are:
·   Changing one layer in the system may introduce new facilities and higher layers in the system may then be changed to take advantage of these facilities. For example, a new database introduced at the support software layer may include facilities to access the data through a web browser and business processes may be modified to take advantage of this facility.
·   Changing the software may slow the system down so that new hardware is needed to improve the system performance. The increase in performance from the new hardware may then mean that further software changes which were previously impractical become possible.
It is often impossible to maintain hardware interfaces, especially if a radical change to a new type of hardware is proposed. Major changes to the application software may therefore be required.

Fig: Layered model of a legacy system
1. Business processes: These are processes that are used in the business to achieve some business objective. An example of a business process in an insurance company would be issuing an insurance policy; in a manufacturing company, a business process would be accepting an order for products and setting up the associated manufacturing process. Business processes may be designed around a legacy system and constrained by the functionality that it provides.
2. Application software: The application system that provides the business services is usually composed of a number of separate programs which have been developed at different times. Sometime the term legacy system means this application software system rather than the entire system.
3. Support software: The legacy system may rely on a range of support software from the operating system and utilities provided by the hardware manufacturer through to the compilers used for system development. Again, these may be obsolete and no longer supported by their original providers.
4. Hardware: Legacy systems may have been written for hardware that is no longer available, that is expensive to maintain and that may not be compatible with current organizational IT purchasing policies.

Legacy System


What do you mean by legacy system? Define about the layered model of legacy system.
            Because of the time and effort required to develop a complex system, large computer based systems usually have a long lifetime. It is sometimes too expensive and too risky to discard such business critical systems after a few years of use. Their development continues throughout their life with changes to accommodate new requirements, new operating platforms, and so forth. Such systems are called Legacy Systems. Legacy system is obsolete computer system that may still be in use because its data cannot be changed to newer or standard formats, or its application programs cannot be upgraded. s an old method, technology, computer system, or application program that continues to be used, typically because it still functions for the users' needs, even though newer technology or more efficient methods of performing a task are now available. A legacy system may include procedures or terminology which are no longer relevant in the current context, and may hinder or confuse understanding of the methods or technologies used. Legacy systems utilize outmoded programming languages, software and/or hardware that typically are no longer supported by the respective vendors.
            Legacy systems are socio-technical computer-based systems that have been developed in the past, often using older or obsolete technology. These systems include not only hardware and software but also legacy processes and procedures- old ways of doing things that are difficult to change because they rely on legacy software. Changes to one part of the system inevitably involve changes to other components.
            Legacy systems are often business-critical systems. They are maintained because it is too risky to replace them. For example, for most banks the customer accounting system was one of their earliest systems. Organisational policies and procedures may rely on this system. If the bank were to scrap and replace the customer accounting software then there would be a serious business risk if the replacement system didn't work properly. Furthermore, existing procedures would have to change, and this may upset the people in the organization and cause with the bank's auditors.