X-Git-Url: https://git.danieliu.xyz/?p=surf.git;a=blobdiff_plain;f=config.def.h;h=57cef76ec00a65b3249f9828fc70061315104419;hp=fca81c31401c90d4c509d12920b7391ed07f7b97;hb=7823ab6fc0d035a1e75a3d08867a0dfd04ff635f;hpb=0247e91b0067c715b19dedd7a3012624ee61576a diff --git a/config.def.h b/config.def.h index fca81c3..57cef76 100644 --- a/config.def.h +++ b/config.def.h @@ -3,12 +3,14 @@ static int surfuseragent = 1; /* Append Surf version to default WebKit user static char *fulluseragent = ""; /* Or override the whole user agent string */ static char *scriptfile = "~/.surf/script.js"; static char *styledir = "~/.surf/styles/"; +static char *certdir = "~/.surf/certificates/"; static char *cachedir = "~/.surf/cache/"; static char *cookiefile = "~/.surf/cookies.txt"; /* Webkit default features */ static Parameter defconfig[ParameterLast] = { SETB(AcceleratedCanvas, 1), + SETB(Certificate, 0), SETB(CaretBrowsing, 0), SETV(CookiePolicies, "@Aa"), SETB(DiskCache, 1), @@ -30,7 +32,7 @@ static Parameter defconfig[ParameterLast] = { SETB(SiteQuirks, 1), SETB(SpellChecking, 0), SETV(SpellLanguages, ((char *[]){ "en_US", NULL })), - SETB(StrictSSL, 1), + SETB(StrictTLS, 1), SETB(Style, 1), SETF(ZoomLevel, 1.0), }; @@ -90,11 +92,20 @@ static WebKitFindOptions findopts = WEBKIT_FIND_OPTIONS_CASE_INSENSITIVE | * The iteration will stop at the first match, beginning at the beginning of * the list. */ -static SiteStyle styles[] = { +static SiteSpecific styles[] = { /* regexp file in $styledir */ { ".*", "default.css" }, }; +/* certificates */ +/* + * Provide custom certificate for urls + */ +static SiteSpecific certs[] = { + /* regexp file in $certdir */ + { "://suckless\\.org/", "suckless.org.crt" }, +}; + #define MODKEY GDK_CONTROL_MASK /* hotkeys */ @@ -141,6 +152,7 @@ static Key keys[] = { { MODKEY|GDK_SHIFT_MASK, GDK_KEY_n, find, { .i = -1 } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_p, print, { 0 } }, + { MODKEY, GDK_KEY_x, showcert, { 0 } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_a, togglecookiepolicy, { 0 } }, { 0, GDK_KEY_F11, togglefullscreen, { 0 } }, @@ -153,6 +165,7 @@ static Key keys[] = { { MODKEY|GDK_SHIFT_MASK, GDK_KEY_i, toggle, { .i = LoadImages } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_v, toggle, { .i = Plugins } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_b, toggle, { .i = ScrollBars } }, + { MODKEY|GDK_SHIFT_MASK, GDK_KEY_t, toggle, { .i = StrictTLS } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_m, toggle, { .i = Style } }, };