Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 01/10/2025 in all areas

  1. argumentum

    Get SSL ExpiryTime

    #include <WinHttp.au3> ; https://github.com/dragana-r/autoit-winhttp/tree/master ConsoleWrite("- ExpiryTime: " & _WinHttp_SSL_ExpiryTime("www.google.com") & @CRLF) Func _WinHttp_SSL_ExpiryTime($sSite, $iPort = 443, $sTimeType = "ExpiryTime") Local Const $tagINTERNET_CERTIFICATE_INFO = "dword ExpiryTime[2]; dword StartTime[2]; ptr SubjectInfo;" & _ "ptr IssuerInfo; ptr ProtocolName; ptr SignatureAlgName; ptr EncryptionAlgName; dword KeySize" Local $tINTERNET_CERTIFICATE_INFO, $hOpen = _WinHttpOpen() _WinHttpSetOption($hOpen, $WINHTTP_OPTION_SECURITY_FLAGS, 0x00003300) ; $SECURITY_FLAG_IGNORE_ALL Local $hConnect = _WinHttpConnect($hOpen, $sSite, $iPort) Local $hRequest = _WinHttpSimpleSendSSLRequest($hConnect, "GET", "/") Local $tBufferLength = DllStructCreate("dword") DllStructSetData($tBufferLength, 1, 2048) Local $sReturn, $tBuffer = DllStructCreate("byte[2048]") Local $iError, $aResult = DllCall($hWINHTTPDLL__WINHTTP, "bool", "WinHttpQueryOption", _ "handle", $hRequest, "dword", $WINHTTP_OPTION_SECURITY_CERTIFICATE_STRUCT, _ "struct*", DllStructGetPtr($tBuffer), "dword*", DllStructGetPtr($tBufferLength)) $iError = @error If Not $iError And $aResult[0] Then $tINTERNET_CERTIFICATE_INFO = DllStructCreate($tagINTERNET_CERTIFICATE_INFO, DllStructGetPtr($tBuffer)) $sReturn = __WinHttp_INTERNET_CERTIFICATE_INFO_Time($tINTERNET_CERTIFICATE_INFO, $sTimeType) ; these are "ExpiryTime" and "StartTime" Else $iError = 99 $sReturn = "error" EndIf $tBufferLength = 0 $tBuffer = 0 $tINTERNET_CERTIFICATE_INFO = 0 _WinHttpCloseHandle($hRequest) _WinHttpCloseHandle($hConnect) _WinHttpCloseHandle($hOpen) Return SetError($iError, 0, $sReturn) EndFunc ;==>_WinHttp_SSL_ExpiryTime Func __WinHttp_INTERNET_CERTIFICATE_INFO_Time($tStruct, $sTimeType = "ExpiryTime") Local $tSystTime = DllStructCreate("struct;word Year;word Month;word Dow;word Day;word Hour;word Minute;word Second;word MSeconds;endstruct") DllCall("kernel32.dll", "bool", "FileTimeToSystemTime", "struct*", DllStructGetPtr($tStruct, $sTimeType), "struct*", $tSystTime) Return StringFormat("%04d/%02d/%02d %02d:%02d:%02d", $tSystTime.Year, $tSystTime.Month, $tSystTime.Day, $tSystTime.Hour, $tSystTime.Minute, $tSystTime.Second) EndFunc ;==>__WinHttp_INTERNET_CERTIFICATE_INFO_Time Had to scrape the site to get this. Shared here so you don't have to go trough the same trouble. This function gets the date a SSL certificate expires on a web site. Edit: Added to "ExpiryTime" the possibility of getting "StartTime". Was already there, might as well give the opportunity to get that too. ..and this one has the rest of the info I could get. If anyone can get ProtocolName, SignatureAlgName and EncryptionAlgName, post it. TIA
    1 point
  2. Jos

    ScITE Themes Etc

    The settings for the edge.line are: The style for the line numbers in at the left-hand side is 33: You could have asked for this: .. as I think it simply is a matter of changing these setting as that defines how tabs/enters are handled for autocomplete: # Define which character will be added after Tab or Enter was entered and not on a Function/UDF: Can be \s \t \n for space;tab;newline autocomplete.au3.on.enter=\n autocomplete.au3.on.tab= ... so just get rid of the \n on that first line in your sciteuser.properties. Jos
    1 point
  3. Wow nice script.. Working pretty damn good
    1 point
  4. Nine

    Save as pdf

    Fair enough. You could be right.
    1 point
  5. Jos

    ScITE Themes Etc

    Nah... That is only for a few changes, but the majority like color settings do not require a restart when edited through SciTe. Just use sciteconfig to load a theme and the SciTe menu options to refine the settings in the user config file. This way you don't need to worry about it's proper location, which depend whether you use the installer or are running portable.
    1 point
  6. BinaryBrother

    ScITE Themes Etc

    That Theme should be added to the official list. It's pretty good.
    1 point
  7. ioa747

    ScITE Themes Etc

    And how do I change the color of the left line count? # 33 is used to display line numbers in the margin. style.*.33=fore:#DADADA,back:#161d27,$(font.base) # checkerboard pixel patter color 1 around fold trees fold.margin.colour=#2D3747 # checkerboard pixel patter color 2 around fold trees fold.margin.highlight.colour=#0D1117 # Color of symbol fill fold.back=#0D1117 https://www.autoitscript.com/forum/topic/211954-scite-change-colour-scheme/#comments
    1 point
  8. Numeric1

    The GASP Game

    @argumentum End the random victories ๐Ÿ•ถ๏ธ. And most importantly, don't forget the mouse this time, itโ€™s going to work a lot now. Yep... it was a bug ๐Ÿ˜‚.
    1 point
  9. The first post is all you need to read really and should give enough info for the setup.
    1 point
  10. here is mine Rename this file to ioa747_Dark.SciTEConfig and put it in %SCITE_USERHOME%\SciTEConfig folder Then open scite press ctrl 1 go to tab Editor colors and press change sheme #-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-# # START: DO NOT CHANGE ANYTHING AFTER THIS LINE #-#-#-#-# # ioa747 Dark Color scheme #------------------------------------------------------------ font.base=font:Verdana,size:11,$(font.override) font.monospace=font:Courier New,size:11 # 32 is the default style and its features will be inherited by all other styles unless overridden. style.*.32=fore:#D0D0D0,back:#0D1117,$(font.base) # Background color style.au3.32=$(font.base),back:#0D1117 caret.line.back=#000000 caret.line.back.alpha=256 caret.fore=#FFFFFF selection.fore=#C2FFAE selection.alpha=70 selection.back=#4FA7FF style.error.0=fore:#FF0000,back:#F0F0F0 style.error.1=fore:#FF0000,back:#FFFF00 style.error.2=fore:#FFFFFF,back:#FF0000 highlight.current.word.colour=#C2FFAE # NEEDED to fix global highlight in #forceref highlight.current.word.by.style=0 # NEEDED to fix global highlight for simple variable as $a highlight.current.word.minlength=2 # Calltips colors style.au3.38=fore:#00D7D7,back:#282800 calltips.color.highlight=#e7db74 # 33 is used to display line numbers in the margin. style.*.33=fore:#DADADA,back:#161d27,$(font.base) # checkerboard pixel patter color 1 around fold trees fold.margin.colour=#2D3747 # checkerboard pixel patter color 2 around fold trees fold.margin.highlight.colour=#0D1117 # Color of symbol fill fold.back=#0D1117 # indentation line style.au3.37=fore:#0D1117 # Brace highlight style.au3.34=fore:#84ACF0,back:#0D1117 # Brace incomplete highlight style.au3.35=fore:#B2B2B2,back:#0D1117 # White space style.au3.0=fore:#80C0FF,back:#0D1117 # Comment line style.au3.1=fore:#B2B2B2,back:#0D1117 # Comment block style.au3.2=fore:#B2B2B2,back:#0D1117 # Number style.au3.3=fore:#00DDDD,back:#0D1117 # Function style.au3.4=fore:#0096F0,back:#0D1117 # Keyword style.au3.5=fore:#84ACF0,back:#0D1117 # Macro style.au3.6=fore:#FF8000,back:#0D1117 # String style.au3.7=fore:#D9CD79,back:#0D1117 # Operator style.au3.8=fore:#FFAE5E,back:#0D1117 # Variable style.au3.9=fore:#FFCEFF,back:#0D1117 # Send keys in string style.au3.10=fore:#00B0B0,back:#0D1117 # Pre-Processor style.au3.11=fore:#0080C0,back:#0D1117 # Special style.au3.12=fore:#CB9898,back:#0D1117 # Abbrev-Expand style.au3.13=fore:#FF80C0,back:#0D1117 # COM Objects style.au3.14=fore:#CC68CC,back:#0D1117 # Standard UDF's style.au3.15=fore:#9A65DC,back:#0D1117 # User UDF's as defined by au3.keywords.user.udfs= in au3.UserUdfs.properties style.au3.16=fore:#DD4489,back:#0D1117 # Files UDF's style.au3.17=fore:#DD4489,underlined,back:#0D1117 # ConsoleWrite output background color style.*.32=fore:#D0D0D0,back:#0D1117,$(font.base) # Actual consoleWrite output style.errorlist.0=fore:#F9F9F9 # ConsoleWrite output highlighted style.errorlist.3=fore:#FF0000 # starting with > style.errorlist.4=fore:#32FFFF # starting with ! style.errorlist.10=fore:#FF0000 # starting with + style.errorlist.11=fore:#EA9515 # starting with - or < style.errorlist.12=fore:#E6DB74 # starting with --- style.errorlist.13=fore:#E87400 # style.errorlist.32=$(font.base),back:#0D1117 # END => DO NOT CHANGE ANYTHING BEFORE THIS LINE #-#-#-#-#-# #-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#
    1 point
×
×
  • Create New...