Adding password to fog wipe task in pxe menu


  • Testers

    So I successfully followed the instructions here Re: DBAN booting into ad and got a working pxe menu option for the fog wipe task.
    However, I was trying to add a login option following the examples of the existing boot options that require login and wasn’t able to get it to boot to the wipe task after the login prompt. I feel like I’m just missing a simple line to tell it to boot.

    i.e. I make the fog.wipe option. Set boot options to mode=wipe wipemode=fast and then in the parameters I throw in

    login
    params
    param mac0 ${net0/mac}
    param arch ${arch}
    param username ${username}
    param password ${password}
    param wipe 1
    isset ${net1/mac} && param mac1 ${net1/mac} || goto bootme
    isset ${net2/mac} && param mac2 ${net2/mac} || goto bootme
    

    And then my boot option stops working.
    I’ve tried a few variations like having nothing after the param password line, adding just boot, and a few other random ideas that didn’t work.
    So what is the line I am missing to add a password to pxe menu option for an existing fog task?

    Thanks,
    -JJ


  • Moderator

    @JJ-Fullmer

    :urls
    set msdart-url http://192.168.1.155/2-MSDART
    :MENU
    menu
    colour --rgb 0xff0000 0 ||
    cpair --foreground 1 1 ||
    cpair --foreground 0 3 ||
    cpair --foreground 4 4 ||
    item --gap -- -------------------------------------
    item fog.local Boot from hard disk
    item msdart6x86 Microsoft DaRT for Windows Vista 32bit
    item msdart6x64 Microsoft DaRT for Windows Vista 64bit
    item msdart7x86 Microsoft DaRT for Windows 7 32bit
    item msdart7x64 Microsoft DaRT for Windows 7 64bit
    item msdart81x86 Microsoft DaRT for Windows 8.1 32bit
    item msdart81x64 Microsoft DaRT for Windows 8.1 64bit
    item fog.return Return to previous menu
    choose --default fog.local --timeout 5000000 target && goto ${target}
    :fog.local
    sanboot --no-describe --drive 0x80 || goto MENU
    :msdart6x86
    initrd ${msdart-url}/MSDaRT60x86.iso
    chain memdisk iso raw
    :msdart6x64
    initrd ${msdart-url}/MSDaRT60x64.iso
    chain memdisk iso raw
    :msdart7x86
    initrd ${msdart-url}/MSDaRT70x86.iso
    chain memdisk iso raw
    :msdart7x64
    initrd ${msdart-url}/MSDaRT70x64.iso
    chain memdisk iso raw
    :msdart81x86
    initrd ${msdart-url}/MSDaRT8.1x86.iso
    chain memdisk iso raw
    :msdart81x64
    initrd ${msdart-url}/MSDaRT8.1x64.iso
    chain memdisk iso raw
    :fog.return
    chain http://${fog-ip}/${fog-webroot}/service/ipxe/boot.php?mac=${net0/mac} ||
    prompt
    goto MENU
    

  • Testers

    @Quazz Do you have a working advanced menu?


  • Moderator

    @JJ-Fullmer I don’t know why it is functioning differently on your end, maybe you need to specify it’s a menu before it works with advanced menu, not sure.


  • Testers

    Adding to the Advanced Configuration (I just added :fog.wipe) simply added my menu entry to the default option and didn’t help the issue.
    I tried @Tom-Elliott’s hidden menu suggestion and that works as expected. However I kind of like the aesthetics of my custom fog pxe screen logo popping up when a computer is booted. Plus the company logo reassures users that it’s a normal screen rather than their computer being hacked or something because they’ve seen too many bad movies. However, I guess I’ll stick with the hidden menu for now, but I would rather have the advanced option.

    Though I would add that in a previous configuration on a fog server I had added the login parameters to a dban iso task the way I was originally trying to do here. So I imagine it is possible, though I realize that was launching a custom booted iso from a parameter line rather than booting to a internal fog task. Does anyone else have a working advanced menu with login maybe my fellow @Testers could help me out with this. Or maybe the feature is broken at the moment?


  • Testers

    @Quazz @Tom-Elliott
    There was no difference on a legacy machine, in case you were curious.

    Hmm, you mean Advanced configuration options to add menu options the old fashioned way? The description in the gui says that’s for the default file, but hey I’ll give it a try.


  • Moderator

    @JJ-Fullmer What happens if you navigate manually to advanced.php?

    Maybe I should mention that Advanced menu under iPXE menu configuration needs to be empty and it needs to be filled in under iPXE Boot Menu options


  • Testers

    @Quazz Tried that, no advanced menu appears. Also tried setting a key sequence to see if it would make the advanced menu appear, no luck there either. Also tried putting the advanced login on the all hosts screen and putting the wipe in the advanced category with no luck either.
    It just says chainloading failed after trying to load advanced.php
    0_1477578634323_Capture.PNG

    This is with efi boot and the bootfile ipxe.efi on a esxi VM as the host if it makes any difference.
    Actually I’ll see if it makes any difference on a legacy machine.


  • Moderator

    @JJ-Fullmer You need to keep advanced login menu on advanced login only and then enable login for advanced menu under the ipxe boot menu options I believe.


  • Testers

    @Tom-Elliott @Quazz
    How do I go about adding it said advanced login menu?
    I had tried setting the advanced login menu to be available to all hosts and then setting the wipe task to be available in the advanced login menu and it then failed to load advanced.php or something of that sort.
    I’ll give using the hidden menu a try.


  • Senior Developer

    I feel I should add on.

    Login boot options aren’t exactly usable if you’re building your own menus. If you really need login protection for specific menu items, you can do as @Quazz recommended and build the item as an advanced menu. Do NOT put login params on the new menu item, but use “Advanced Login” or you could protect access to the menu in whole by using hidden menu.

    Hidden menu will require a double step (Enter some key sequence + Login). Once successfully logged in, though, you would then see the menu. In this instance, you would no longer need the wipe task parameters.


  • Moderator

    I don’t know if the boot file accepts “param wipe 1” as a legitimate parameter.

    Easiest solution would be to use the advanced login menu and put it as an item there.

    Does the boot option give the option to enter credentials?

    Any error messages when you try the boot option?


Log in to reply
 

484
Online

38963
Users

10708
Topics

101604
Posts

Looks like your connection to FOG Project was lost, please wait while we try to reconnect.