Rewards for files
If the Drive account has SM on the balance and the Drive has Pending or Finished state, replicators can send the transaction to get the reward for files transferring during the billing period. The consensus of replicators decides who will be the initiator. The initiator collects receipts (Fair Streaming protocol) from replicators and the owner and after creates the get rewards transaction and announces it to Blockchain. Other replicators validate it (the owner doesn't validate it), and cosign it in case everything is correct.
If the transaction contains information about replicators, which didn't put the deposit for active files or uploaded size equals zero, Blockchain will reject it.
Replicators should send information about all files uploaded during a billing period. But before sending this information, replicators should validate receipts of each other, so everyone makes sure that they are related to the same billing period accordingly. Uploaded information can be collected via Fair Streaming. After confirmation of the transaction, all SM that stored on the balance of the drive's account will be spread proportionally uploaded data. Only then replicators can delete receipts.
In case the Drive has the Finished state, but the Drive account contains SM on its balance, replicators still can send the get reward's transaction. After the confirmation, Blockchain prunes info about the Drive from cache after 360 blocks, the multisig account will be removed.
Rewards for drive
At the end of each billing, period replicators get their reward for participation in the drive. The billingPrice of the Drive is distributed between all replicators that passed verification. Every replicator gets the reward appropriate to its time in the contract (formula below). If it was the last billing period, then the deposit would be returned to honest replicators.