Closed Bug 1192982 Opened 4 years ago Closed 4 years ago

Use of strncpy in |addRange| in nptest.cpp can result in unterminated cstr

Categories

(Core :: Plug-ins, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla45
Tracking Status
firefox43 --- affected
firefox45 --- fixed

People

(Reporter: erahm, Assigned: andi)

References

(Blocks 1 open bug)

Details

(Keywords: coverity, Whiteboard: [CID 1274374])

Attachments

(1 file)

+++ This bug was initially created as a clone of Bug #517078 +++

Note: this is just in test code.

Coverity indicates |addRange| uses strncpy [1] in a way that can lead to an unterminated string buffer.

[1] https://hg.mozilla.org/mozilla-central/annotate/d6ea652c579992daa9041cc9718bb7c6abefbc91/dom/plugins/test/testplugin/nptest.cpp#l426
Assignee: nobody → bogdan.postelnicu
Attached patch Bug 1192982.diffSplinter Review
Hello Josh,

Could you please take a look other this patch?

THX
Attachment #8692967 - Flags: review?(jaas)
Attachment #8692967 - Flags: review?(jaas) → review+
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/3394473d2101
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
You need to log in before you can comment on or make changes to this bug.