<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; VBScript: Использование в скрипте STARTTLS]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=6469&amp;type=atom" />
	<updated>2011-11-22T13:12:46Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=6469</id>
		<entry>
			<title type="html"><![CDATA[Re: VBScript: Использование в скрипте STARTTLS]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=53769#p53769" />
			<content type="html"><![CDATA[<p>На сколько я понял это консольное приложение для работы по протоколу TLS. К сожалению (а может и к счастью <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /> ) не приходилось с ним работать, но предполагаю, что начать нужно с <strong>WshExec</strong> и выяснить поддерживает ли это приложение работу со стандартными потоками <strong>StdIn</strong> и <strong>StdOut</strong>. Т.к найти модуль этого приложения я сам не смог, то провести эксперимент соответственно тоже.</p><p>Предположительно копать нужно в аналогичном направлении.<br /></p><div class="codebox"><pre><code>
Option Explicit
Dim WshShell, WshExec
Set WshShell = CreateObject(&quot;WScript.Shell&quot;)
Set WshExec = WshShell.Exec(&quot;cmd.exe&quot;)
WshExec.StdIn.WriteLine &quot;ping 127.0.0.1&quot;
WshExec.Terminate()
MsgBox ConvertCharset(WshExec.StdOut.ReadAll,&quot;windows-1251&quot;,&quot;cp866&quot;)

Function ConvertCharset(text,srcCharset,destCharset)
	Dim stream
	Set stream = CreateObject(&quot;ADODB.Stream&quot;)
	stream.charset = srcCharset
	stream.type = 2
	stream.open
	stream.writeText text
	stream.position = 0
	stream.charset = destCharset
	ConvertCharset = stream.readText
End Function</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Xameleon]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=8836</uri>
			</author>
			<updated>2011-11-22T13:12:46Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=53769#p53769</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[VBScript: Использование в скрипте STARTTLS]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=53749#p53749" />
			<content type="html"><![CDATA[<p>Кто-либо знает, как в VBScript`е использовать STARTTLS? А то на локальном почтовом сервере авторизация идет через 25й порт с использованием STARTTLS...</p>]]></content>
			<author>
				<name><![CDATA[nostro]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27296</uri>
			</author>
			<updated>2011-11-21T13:23:15Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=53749#p53749</id>
		</entry>
</feed>
