If you are looking for Sony Xpeira Z5 stock firmware, we have got you covered. We have got hold of EU and DE stock firmwares. This would not wipe the DRM keys. You will need latest version of flashtool for Xperia Z5.
1. Open the Xperia Z5 flashtool and choose the firmware you downloaded earlier. Download links are present at bottom of this article. If you do not wish to delete any data on your Sony Xperia Z5, uncheck userdata.sin file. This way all data will remain intact on your phone.
2. Turn off the Xperia Z5 phone and when the Flashtool pops up, connect the Z5 to the PC and hold down volume down button. Start the flashing process now.
It might stall for about 5 minutes on “system.sin” but it will finish the flashing process eventually.
About unlocking bootloader. Be aware that unlocking your bootloader will cause permanent loss of DRM keys, and hence camera functionality, etc. Until we have a root exploit (if we ever do) for locked bootloaders, we can’t backup the TA partition and preserve our DRM keys.
PS: If your phone is not recognized when connect it to the PC, try installing official Sony drivers from here.