Thomas Limoncelli
2006-Mar-01 23:03 UTC
[Samba] 3.0.21c safe_strcat string overflow w/ "net rpc share migrate files"
When migrating files off an existing Win2K file server using "net rpc share migrate files" with Samba 3.0.21c on SuSE 9.3 Pro I stumbled across a number of "string overflow by X in safe_strcat" errors on a few files with non-ASCII characters: myserver# net rpc share migrate files myshare --acls --attrs --timestamps -S win2k -U 'XXX\administrator' --destination=`hostname` Password: syncing [myshare] files and directories including ACLs, including DOS Attributes (preserving timestamps) [...] [2006/03/01 23:04:59, 0] lib/util_str.c:safe_strcat_fn(637) ERROR: string overflow by 4 in safe_strcat [Meyer ABCD Ostlandstr., Carl-K?ttgen-Str., Pe] Also, there are a number of (possibly related) errors of the kind: could not handle file: \some\long\path\with\special\characters\like ????: NT_STATUS_OBJECT_NAME_NOT_FOUND Would this likely be a Samba or W2K server bug? Is there any way to migrate these files using any sort of automated mangling? I'm willing to provide level 10 debug logs, Ethereal traces and whatever it may take to track it down. -TL
Jeremy Allison
2006-Mar-01 23:08 UTC
[Samba] 3.0.21c safe_strcat string overflow w/ "net rpc share migrate files"
On Thu, Mar 02, 2006 at 12:03:14AM +0100, Thomas Limoncelli wrote:> When migrating files off an existing Win2K file server using "net rpc > share migrate files" with Samba 3.0.21c on SuSE 9.3 Pro I stumbled > across a number of "string overflow by X in safe_strcat" errors on a few > files with non-ASCII characters: > > myserver# net rpc share migrate files myshare --acls --attrs > --timestamps -S win2k -U 'XXX\administrator' --destination=`hostname` > Password: > syncing [myshare] files and directories including ACLs, including DOS > Attributes (preserving timestamps) > [...] > [2006/03/01 23:04:59, 0] lib/util_str.c:safe_strcat_fn(637) > ERROR: string overflow by 4 in safe_strcat [Meyer ABCD Ostlandstr., > Carl-K?ttgen-Str., Pe] > > Also, there are a number of (possibly related) errors of the kind: > > could not handle file: \some\long\path\with\special\characters\like > ????: NT_STATUS_OBJECT_NAME_NOT_FOUND > > > Would this likely be a Samba or W2K server bug? Is there any way to > migrate these files using any sort of automated mangling? I'm willing to > provide level 10 debug logs, Ethereal traces and whatever it may take to > track it down.Please log a bug at bugzilla.samba.org and attach level 10 debug logs + ethereal traces. Thanks ! Jeremy