darryllane / Bluto

DNS Recon | Brute Forcer | DNS Zone Transfer | DNS Wild Card Checks | DNS Wild Card Brute Forcer | Email Enumeration | Staff Enumeration | Compromised Account Checking
GNU General Public License v3.0
619 stars 140 forks source link

Fix for 'UnboundLocalError: local variable 'user_names' referenced be… #22

Closed nuschpl closed 6 years ago

nuschpl commented 6 years ago

…fore assignment in line 926

darryllane commented 6 years ago

Hi! Id like to recreate this issue, would you mind sharing how you got to it?

nuschpl commented 6 years ago

I can't share the domain scanned but it's obvious looking at the code where the flow wrongly assumes variable is always set while it's not in some cases

niedz., 18 lis 2018, 11:48 użytkownik Darryl notifications@github.com napisał:

Hi! Id like to recreate this issue, would you mind sharing how you got to it?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/darryllane/Bluto/pull/22#issuecomment-439683375, or mute the thread https://github.com/notifications/unsubscribe-auth/AEuIVdW2GbwGuIhVPNHZCZQg3hA_f3Uxks5uwTrhgaJpZM4Yn1oK .

nuschpl commented 6 years ago

If you do "if variable:" in python it will check if variable has value, will check if variable is "", will check even if variable is None, but if variable is not set at all at the time it will raise NameError. So you need to either catch NameError exception or preinitialize all variables which have possibility to not being set with None in their full scope Regards B.Ż

niedz., 18 lis 2018, 12:18 użytkownik Bartłomiej Żogała nusch@nusch.pl napisał:

I can't share the domain scanned but it's obvious looking at the code where the flow wrongly assumes variable is always set while it's not in some cases

niedz., 18 lis 2018, 11:48 użytkownik Darryl notifications@github.com napisał:

Hi! Id like to recreate this issue, would you mind sharing how you got to it?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/darryllane/Bluto/pull/22#issuecomment-439683375, or mute the thread https://github.com/notifications/unsubscribe-auth/AEuIVdW2GbwGuIhVPNHZCZQg3hA_f3Uxks5uwTrhgaJpZM4Yn1oK .

darryllane commented 6 years ago

Thats fair enough, ill take a look when i get home

On Sun, 18 Nov 2018, 11:19 Bartłomiej Żogała <notifications@github.com wrote:

I can't share the domain scanned but it's obvious looking at the code where the flow wrongly assumes variable is always set while it's not in some cases

niedz., 18 lis 2018, 11:48 użytkownik Darryl notifications@github.com napisał:

Hi! Id like to recreate this issue, would you mind sharing how you got to it?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/darryllane/Bluto/pull/22#issuecomment-439683375, or mute the thread < https://github.com/notifications/unsubscribe-auth/AEuIVdW2GbwGuIhVPNHZCZQg3hA_f3Uxks5uwTrhgaJpZM4Yn1oK

.

— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub https://github.com/darryllane/Bluto/pull/22#issuecomment-439685099, or mute the thread https://github.com/notifications/unsubscribe-auth/AIUu5RoN8UQmpfgA6I3DLVydidisWnUAks5uwUIlgaJpZM4Yn1oK .