Wireless sensor network is an emerging technology. WSN's are deployed in an open and unattended environment. Therefore they are prone to security threats. The traditional approach of cryptography alone was not sufficient for security. Cryptography was not able to prevent internal adversaries from inserting the forged data. As a result Trust factor scheme was introduced in wireless sensor networks to prevent internal security threats in a network. In a distributed deployment of wireless sensor network, nodes communicate with each other on the basis of their trustworthiness. But in a huge network it becomes challenge for sensor nodes to recognize all the sensor nodes present in a network and retain their trust values with it, as the changes are very frequent in wireless sensor networks. So nodes are more vulnerable to attacks. In a proposed work, the main base station keeps the trust value of all the sensor nodes. The trust values are defined by belief of an individual node in a network. Belief is the subjective trust which can be justified by the past judgments in a network. If the value of belief is more, the sensor node will be more trustworthy. Different algorithms have been applied to authenticate the new sensor node and to provide secured file sharing in a wireless sensor network.