Need help reading&editing .cfg file

Discussion in 'Mac Basics and Help' started by Takenlife, Nov 30, 2013.

  1. Takenlife macrumors member

    Joined:
    Sep 25, 2012
    #1
    Hi, this .cfg file has been a pain in the ass. I am trying to modify my router files so it blocks ads from router. I do not want to use applications like adblock or adblockplus, I want to know how to open .cfg files and read them and edit them. When I open them with textedit, it is all random symbols, and it is non readable. I am fairly noob in this area seeking for help from anyone that can help me with this. I have tried textwrangler as well and it opens up as same as textedit.
     
  2. Takenlife thread starter macrumors member

    Joined:
    Sep 25, 2012
    #2
    Hello, I really need a program to open up .cfg and READ properly. And without the random symbols. Or teach me how to see it properly because I have self manually opening them. I even downloaded new cfg files to try over and over again to see if that was an issue of any procedure. Please help!
     
  3. Sydde macrumors 68020

    Sydde

    Joined:
    Aug 17, 2009
    #3
    Are the characters at the beginning of the file
    Code:
    bplist00
    ?
     
  4. Takenlife thread starter macrumors member

    Joined:
    Sep 25, 2012
    #4
    No it looks like random characters on preview before and after opening. Yes a fresh downloaded copy from the router backup as .cfg extension. Can not see it properly. Anymore suggestions?
     
  5. yg17 macrumors G5

    yg17

    Joined:
    Aug 1, 2004
    Location:
    St. Louis, MO
    #5
    cfg is such a generic extension, it could be anything. There's no one program that could open it. Sounds like the file you're trying to edit is binary instead of plain text. I suppose if you know what you're doing, you could use a hex editor to modify it.
     
  6. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #6
    A. Please identify your specific router: manufacturer, model, and version. Also identify which country you're in, because there may be country-specific models if it's part of a cable-modem or other communications adapter.

    B. Do this:
    1. Move the cfg file to your desktop.
    2. Rename it to test.cfg.
    3. Launch Terminal.app.
    4. Copy and paste this exact command-line into the Terminal window:
      Code:
      hexdump -C ~/Desktop/test.cfg | head -n 10
      
    5. Copy and paste the complete output into a reply posted here, including any error messages that may appear.
     
  7. Takenlife thread starter macrumors member

    Joined:
    Sep 25, 2012
    #7
    Netgear WNDR3400v2
    FW: V1.0.0.38_1.0.61
    USA

    00000000 d5 fc eb b2 81 87 bb 2a 5e 89 7b 70 2f e7 4e ae |.......*^.{p/.N.|
    00000010 3a e5 ca b0 e6 05 73 b2 6a 51 49 42 1b 3f c8 4b |:.....s.jQIB.?.K|
    00000020 d5 53 0f a9 0b bc 6e 08 ac f0 8b ba 17 5e 0b 32 |.S....n......^.2|
    00000030 fe 5d 5a 7b 1c 4e 29 58 ab da 93 b3 95 db cf 74 |.]Z{.N)X.......t|
    00000040 8d ab 7e 5b eb cd 9c 3c 2c c1 dd 45 17 20 b8 6a |..~[...<,..E. .j|
    00000050 01 bb d8 7c da 00 57 24 93 7b 90 f7 d0 80 64 e1 |...|..W$.{....d.|
    00000060 29 7a cd 3d c7 23 7a 00 af 8f 31 40 6c c3 00 a5 |)z.=.#z...1@l...|
    00000070 55 90 61 19 65 80 9b 01 55 ec ef 1f cd ac 7f c0 |U.a.e...U.......|
    00000080 79 e3 01 cb d5 55 8a ed 93 2e 26 85 a3 91 21 f6 |y....U....&...!.|
    00000090 d9 21 23 98 62 ab 81 32 a0 7c b3 62 1c 68 22 ef |.!#.b..2.|.b.h".|

    That's what I got. Lastly I appreciate effort to help.
     
  8. yg17 macrumors G5

    yg17

    Joined:
    Aug 1, 2004
    Location:
    St. Louis, MO
    #8
    There is no way you're going to be able to manually edit that.
     
  9. Takenlife thread starter macrumors member

    Joined:
    Sep 25, 2012
    #9
    Well when I did that terminal thing, yes am fond of editing hex..to a point. But I wonder why my netgear made it so hard to edit?

    The purpose of this is because they limited my "block sites" input. I put the max sites I have blocked. Also, I do not want to use ADP because it is another application or extension that I have to bog down my browser. And I wanted to block everything through the router to block it to every device (like the iPhone's limitation w/o jb).

    Although if someone can help me on this again I would very much appreciate it.
     
  10. yg17 macrumors G5

    yg17

    Joined:
    Aug 1, 2004
    Location:
    St. Louis, MO
    #10
    Well I guess you could use a hex editor and modify it if you wanted to. Good luck lol
     
  11. Takenlife thread starter macrumors member

    Joined:
    Sep 25, 2012
    #11
    gee... i need more than a goodluck. ha.
     
  12. yg17 macrumors G5

    yg17

    Joined:
    Aug 1, 2004
    Location:
    St. Louis, MO
    #12
    That's all you'll get, because what you're attempting to do is probably impossible. This is a proprietary file format and not meant to be edited manually, not to mention that one incorrect byte in the wrong spot might turn your router into a paperweight.
     
  13. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #13
    That file probably isn't intended to be edited. It's just for making backups, and possibly for transferring from one device to another when you change routers. It's possible that the file data is encrypted, which would decrease the chances of editing it even more than if it were just undocumented.

    I did multiple searches and found nothing at all describing the format of the file. There's no available public documentation on it, as far as I can tell. The closest I found to any info on the config file was a suspicion of a malware attack via a compromised config file:
    http://forum1.netgear.com/showthread.php?p=384068
    No details or confirmation on that, just a suspicion.

    My google searches:
    netgear WNDR3400 config file
    netgear WNDR3400 config
    netgear WNDR3400 cfg file
    site:netgear.com WNDR3400 "file"
    site:netgear.com WNDR3400 "config"
    site:netgear.com WNDR3400 "cfg"
     
  14. Takenlife thread starter macrumors member

    Joined:
    Sep 25, 2012
    #14
    Thank you for helping me. So I am guessing netgear does this with all their newer routers. Maybe will go with another router in the future.

    Btw did you guys know that the "blocked sites" feature on netgear that version in quote above, has a limit to how many sites you can block. It's pathetic, but it's still running. I wanted to block from all devices (and including iPhone without jailbreak which atm it can't anyway).
     

Share This Page