Closed Bug 1769627 Opened 2 years ago Closed 2 years ago

Use the NSS 3.79 SECMOD_LockedModuleHasRemovableSlots function where appropriate

Categories

(Core :: Security: PSM, defect, P1)

defect

Tracking

()

RESOLVED FIXED
102 Branch
Tracking Status
firefox102 --- fixed

People

(Reporter: jschanck, Assigned: jschanck)

References

Details

(Whiteboard: [psm-assigned])

Crash Data

Attachments

(1 file)

The SECMOD_LockedModuleHasRemovableSlots function was added to NSS 3.79 to provide a safe alternative to SECMOD_HasRemovableSlots when the calling thread has already acquired the module list lock. As mentioned in Bug 1753315, we can attribute some firefox shutdown hangs to the attempted re-acquisition of the module list lock here and here. We should update these call sites to use SECMOD_LockedModuleHasRemovableSlots.

Severity: S4 → S2
Priority: P5 → P1
Whiteboard: [psm-assigned]
Pushed by jschanck@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/93af3b1d56ef
switch to SECMOD_LockedModuleHasRemovableSlots. r=keeler

Backed out for causing build bustages on xul.dll.

Push with failures

Failure log

Backout link

[task 2022-05-23T18:01:46.695Z] 18:01:46     INFO -  gmake[4]: Entering directory '/builds/worker/workspace/obj-build/toolkit/library/gtest'
[task 2022-05-23T18:01:46.698Z] 18:01:46     INFO -  /builds/worker/fetches/sccache/sccache /builds/worker/fetches/clang/bin/clang++ --sysroot /builds/worker/fetches/MacOSX10.12.sdk -mmacosx-version-min=10.12 -stdlib=libc++ -std=gnu++17 --target=x86_64-apple-darwin -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fstack-protector-strong -ftrivial-auto-var-init=pattern -Qunused-arguments -Qunused-arguments -Wall -Wbitfield-enum-conversion -Wdeprecated-this-capture -Wempty-body -Wformat-type-confusion -Wignored-qualifiers -Wpointer-arith -Wshadow-field-in-constructor-modified -Wsign-compare -Wtype-limits -Wno-error=tautological-type-limit-compare -Wunreachable-code -Wunreachable-code-return -Wunused-but-set-parameter -Wno-invalid-offsetof -Wclass-varargs -Wempty-init-stmt -Wfloat-overflow-conversion -Wfloat-zero-conversion -Wloop-analysis -Wno-range-loop-analysis -Wc++2a-compat -Wcomma -Wenum-compare-conditional -Wimplicit-fallthrough -Wduplicate-method-arg -Wduplicate-method-match -Wmissing-method-return-type -Wobjc-signed-char-bool -Wsemicolon-before-method-body -Wsuper-class-method-mismatch -Werror=non-literal-null-conversion -Wstring-conversion -Wno-inline-new-delete -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=backend-plugin -Wno-error=free-nonheap-object -Wno-error=return-std-move -Wno-error=atomic-alignment -Wno-error=deprecated-copy -Wformat -Wformat-security -Wno-gnu-zero-variadic-macro-arguments -Wno-psabi -Wthread-safety -Wno-unknown-warning-option -fno-sized-deallocation -fno-aligned-new -fcrash-diagnostics-dir=/builds/worker/artifacts -fno-exceptions -fPIC -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -pthread -pipe -gdwarf-4 -Xclang -load -Xclang /builds/worker/workspace/obj-build/build/clang-plugin/libclang-plugin.so -Xclang -add-plugin -Xclang moz-check -O3 -fno-omit-frame-pointer -funwind-tables -Werror   -o XUL -Wl,-filelist,/builds/worker/workspace/obj-build/toolkit/library/gtest/XUL.list   -fstack-protector-strong '-Wl,-U,_OBJC_CLASS_$_NSTouchBar' '-Wl,-U,_OBJC_CLASS_$_NSSharingServicePickerTouchBarItem' '-Wl,-U,_OBJC_METACLASS_$_NSTouchBar' '-Wl,-U,_OBJC_CLASS_$_NSCustomTouchBarItem' '-Wl,-U,_OBJC_CLASS_$_NSPopoverTouchBarItem' -lresolv -Wl,-dead_strip  ../../../security/nss/lib/crmf/crmf_crmf/libcrmf.a ../../../js/src/build/libjs_static.a /builds/worker/workspace/obj-build/x86_64-apple-darwin/debug/libgkrust_gtest.a ../../../security/libnss3.dylib ../../../config/external/lgpllibs/liblgpllibs.dylib ../../../mozglue/build/libmozglue.dylib -dynamiclib -install_name @executable_path/XUL -compatibility_version 1 -current_version 1  -framework AudioUnit -framework CoreAudio -lbsm -framework IOSurface -framework IOKit -framework AudioToolbox -framework CoreMedia -framework VideoToolbox -Wl,-U,_VTRegisterSupplementalVideoDecoderIfAvailable -Wl,-U,_VTIsHardwareDecodeSupported -framework LocalAuthentication -framework Security -lm -framework Foundation -framework CoreFoundation -framework CoreLocation -framework QuartzCore -framework Carbon -framework CoreVideo -framework AddressBook -framework OpenGL -framework ServiceManagement -framework CoreServices -framework ApplicationServices -framework AppKit -framework CoreMIDI -framework SystemConfiguration -framework AVFoundation -F/builds/worker/fetches/MacOSX10.12.sdk/System/Library/PrivateFrameworks -framework CoreUI -framework CoreSymbolication -lcups -weak_framework Metal -weak_framework MediaPlayer
[task 2022-05-23T18:01:46.698Z] 18:01:46     INFO -  Undefined symbols for architecture x86_64:
[task 2022-05-23T18:01:46.698Z] 18:01:46     INFO -    "_SECMOD_LockedModuleHasRemovableSlots", referenced from:
[task 2022-05-23T18:01:46.698Z] 18:01:46     INFO -        __ZN14nsNSSComponent19HasActiveSmartCardsEPb in Unified_cpp_security_manager_ssl2.o
[task 2022-05-23T18:01:46.698Z] 18:01:46     INFO -        __ZN14nsNSSComponent24CheckForSmartCardChangesEv in Unified_cpp_security_manager_ssl2.o
[task 2022-05-23T18:01:46.698Z] 18:01:46     INFO -  ld: symbol(s) not found for architecture x86_64
[task 2022-05-23T18:01:46.699Z] 18:01:46     INFO -  clang-14: error: linker command failed with exit code 1 (use -v to see invocation)
[task 2022-05-23T18:01:46.699Z] 18:01:46    ERROR -  gmake[4]: *** [/builds/worker/checkouts/gecko/config/rules.mk:531: XUL] Error 1
[task 2022-05-23T18:01:46.699Z] 18:01:46     INFO -  gmake[4]: Leaving directory '/builds/worker/workspace/obj-build/toolkit/library/gtest'
[task 2022-05-23T18:01:46.699Z] 18:01:46    ERROR -  gmake[3]: *** [/builds/worker/checkouts/gecko/config/recurse.mk:72: toolkit/library/gtest/target] Error 2
[task 2022-05-23T18:01:46.699Z] 18:01:46     INFO -  gmake[3]: *** Waiting for unfinished jobs....
[task 2022-05-23T18:01:46.875Z] 18:01:46     INFO -  gmake[4]: Entering directory '/builds/worker/workspace/obj-build/mfbt/tests'
Flags: needinfo?(jschanck)

Forgot to update security/nss.symbols.

Flags: needinfo?(jschanck)
Pushed by jschanck@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/cfe0733004b7
switch to SECMOD_LockedModuleHasRemovableSlots. r=keeler
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: