  Industrial Internet of Things (IIoT) opens up a challenging research area
towards improving secure data sharing which currently has several limitations.
Primarily, the lack of inbuilt guarantees of honest behavior of participating,
such as end-users or cloud behaving maliciously may result in disputes. Given
such challenges, we propose a fair, accountable, and secure data sharing
scheme, $\textit{FairShare}$ for IIoT. In this scheme, data collected from IoT
devices are processed and stored in cloud servers with intermediate fog nodes
facilitating computation. Authorized clients can access this data against some
fee to make strategic decisions for improving the operational services of the
IIoT system. By enabling blockchain, $\textit{FairShare}$ prevents fraudulent
activities and thereby achieves fairness such that each party gets their
rightful outcome in terms of data or penalty/rewards while simultaneously
ensuring accountability of the services provided by the parties. Additionally,
smart contracts are designed to act as a mediator during any dispute by
enforcing payment settlement. Further, security and privacy of data are ensured
by suitably applying cryptographic techniques like proxy re-encryption. We
prove $\textit{FairShare}$ to be secure as long as at least one of the parties
is honest. We validate $\textit{FairShare}$ with a theoretical overhead
analysis. We also build a prototype in Ethereum to estimate performance and
justify comparable results with a state-of-the-art scheme both via simulation
and a realistic testbed setup. We observe an additional communication overhead
of 256 bytes and a cost of deployment of 1.01 USD in Ethereum which are
constant irrespective of file size.
