安装特定版本的mPDF

I am trying to install mPDF on my Centos server with PHP 7.0.33 and it continues to default to mPDF version 6.1. I need version 7 or 8. I tried manually uploading mPDF 8 from github but it creates a cryptographic fingerprint issue with composer.

Is there a way to force install version 8 or 7?

Here's what I ultimately had to do. Since 'composer require' runs at the command line it detects the CLI version of PHP, which is different from what apache might be using. I updated my CLI PHP to 7.0 with the following script:

https://github.com/dfuentes87/change_phpcli.sh/blob/master/change_phpcli.sh

cd ~/

touch change_phpcli.sh

vim change_phpcli.sh

(I just pasted the code in since it is a small file) save file then

chmod +x change_phpcli.sh

run the script ./change_phpcli.sh

and answer the question, I entered 7.0 for my version

Then run composer require mpdf/mpdf:^8.0

I also had to force my code to use a specific tmp folder for mPDF for some reason using:

require_once APPPATH . '../vendor/autoload.php';

$mpdf = new \Mpdf\Mpdf(['tempDir' => APPPATH . '../vendor/mpdf/mpdf/tmp/']);

and chown it to the user/group that run my web scripts:

chown myuser:psacln vendor/mpdf/mpdf/tmp/

Hope this helps, thanks for the pointers @Finwe