View Issue Details

IDProjectCategoryView StatusLast Update
0001100bareos-core[All Projects] bconsolepublic2019-07-15 16:22
ReporterfrankuAssigned Tofranku 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product Version18.2.5 
Target Version18.2.7Fixed in Version 
Summary0001100: bconsole crashes when a pam authentication aborts
DescriptionI want to authenticate using bconsole on a director with PAM enabled.

The bconsole tries to authenticate using the interactive mode but stops working with the following output:

"free(): double free detected in tcache 2
BAREOS interrupted by signal 6: IOT trap
bconsole, bconsole got signal 6 - IOT trap. Attempting traceback."

In the director's logfile I can find this:
bareos-dir (200): dird/auth_pam.cc:193-0 PAM authentication failed: Error in service module
bareos-dir (10): dird/authenticate_console.cc:355-0 ERROR: Unable to authenticate console "PamConsole" at client:


Steps To ReproduceI used this code from the bconsole-pam test in the Bareos systemtests (shown only snippets):

# etc/pam.d/bareos.in has to be adapted to the right system paths and renamed to etc/pam.d/bareos

export PAM_WRAPPER=1
export PAM_WRAPPER_SERVICE_DIR=etc/pam.d/bareos

/usr/lib64/libpam_wrapper.so ../../../core/src/dird/bareos-dir -f -c etc/bareos/ -d200

../../../core/src/console/bconsole -c etc/bareos/

bconsole then asks for a password. After pressing enter the console crashes.
Additional InformationThe bug severity of minor is only justifiable because up to now this bug is known to appear in this special test-environment.
TagsNo tags attached.
bareos-master: impactyes
bareos-master: actionfixed
bareos-18.2: impactyes
bareos-18.2: actionfixed
bareos-17.2: impact
bareos-17.2: action
bareos-16.2: impact
bareos-16.2: action
bareos-15.2: impact
bareos-15.2: action
bareos-14.2: impact
bareos-14.2: action
bareos-13.2: impact
bareos-13.2: action
bareos-12.4: impact
bareos-12.4: action

Activities

franku

franku

2019-07-15 16:22

developer   ~0003480

Fix committed to bareos bareos-18.2 branch with changesetid 11597.

Related Changesets

bareos: master 9f24d0db

2019-07-12 16:36:49

franku

Ported: N/A

Details Diff
console: reset a pointer variable after free

fixes 0001100: bconsole crashes when a pam authentication aborts

This fixes a double free of a pointer when the called pam module
aborts the authentication i.e. in case of an error
Affected Issues
0001100
mod - core/src/console/auth_pam.cc Diff File

bareos: bareos-18.2 d145c8e9

2019-07-15 15:29:53

franku

Ported: N/A

Details Diff
console: reset a pointer variable after free

fixes 0001100: bconsole crashes when a pam authentication aborts

This fixes a double free of a pointer when the called pam module
aborts the authentication i.e. in case of an error
Affected Issues
0001100
mod - core/src/console/auth_pam.cc Diff File

Issue History

Date Modified Username Field Change
2019-07-15 15:01 franku New Issue
2019-07-15 15:01 franku Status new => assigned
2019-07-15 15:01 franku Assigned To => franku
2019-07-15 15:06 franku Steps to Reproduce Updated View Revisions
2019-07-15 15:06 franku Additional Information Updated View Revisions
2019-07-15 15:06 franku bareos-master: impact => yes
2019-07-15 15:06 franku bareos-18.2: impact => yes
2019-07-15 15:09 franku Description Updated View Revisions
2019-07-15 15:09 franku Steps to Reproduce Updated View Revisions
2019-07-15 15:09 franku Additional Information Updated View Revisions
2019-07-15 15:43 franku Status assigned => resolved
2019-07-15 15:43 franku Resolution open => fixed
2019-07-15 15:43 franku bareos-master: action => fixed
2019-07-15 15:43 franku bareos-18.2: action => fixed
2019-07-15 16:22 franku Changeset attached => bareos master 9f24d0db
2019-07-15 16:22 franku Changeset attached => bareos bareos-18.2 d145c8e9
2019-07-15 16:22 franku Note Added: 0003480