I believe there’s no need for action here - that package has a dependency on ^2.4.11, not 2.4.11 - that means “anything in the range >=2.4.11 <3.0.0”.
Your package manager should be able to update to 2.4.12 just fine, and any future installation of @apollo/utils.createhash will end up using the latest, non-vulnerable version.
% npm i
added 32 packages, and audited 33 packages in 777ms
16 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities
% npm audit
found 0 vulnerabilities
% npm why sha.js
sha.js@2.4.12
node_modules/sha.js
sha.js@"^2.4.11" from @apollo/utils.createhash@3.0.1
node_modules/@apollo/utils.createhash
@apollo/utils.createhash@"^3.0.1" from the root project
% npm ls sha.js
test@ /tmp/test
└─┬ @apollo/utils.createhash@3.0.1
└── sha.js@2.4.12
Npm behaves as expected, does not install the vulnerable version, and npm audit seems to take that on correctly.
Did you run npm update or npm update sha.js on your end before running npm audit?