OSDN Git Service

キー難読化
authorkiri_feather <kiri_feather@users.sourceforge.jp>
Thu, 2 Dec 2010 10:18:32 +0000 (10:18 +0000)
committerKimura Youichi <kim.upsilon@bucyou.net>
Sat, 18 Feb 2012 14:16:50 +0000 (23:16 +0900)
非公式RT仕様戻し
USイベント判定ミス修正

git-svn-id: http://svn.sourceforge.jp/svnroot/tween/trunk@1152 e39ad16e-3079-482e-bb30-4b4d378143b6

Tween/Connection/HttpTwitter.vb
Tween/Connection/TwitPic.vb
Tween/Connection/imgly.vb
Tween/Connection/yfrog.vb
Tween/Tween.vb
Tween/Tween.vbproj
Tween/Twitter.vb

index 95b770a..c45942c 100644 (file)
@@ -10,13 +10,12 @@ Public Class HttpTwitter
     '''<summary>
     '''OAuthのコンシューマー鍵
     '''</summary>
-    Private Const ConsumerKey As String = "iOQHfiCUsyOyamW8JJ8jg"
+    Private Const ConsumerKey As String = "tLbG3uS0BIIE8jm1mKzKOfZ6EgUOmWVM"
 
     '''<summary>
     '''OAuthの署名作成用秘密コンシューマーデータ
     '''</summary>
-    Private Const ConsumerSecret As String = "5PS2oa5f2VaKMPrlZa7DTbz0aFULKd3Ojxqgsm142Dw"
-
+    Private Const ConsumerSecret As String = "M0IMsbl2722iWa+CGPVcNeQmE+TFpJk8B/KW9UUTk3eLOl9Ij005r52JNxVukTzM"
     '''<summary>
     '''OAuthのアクセストークン取得先URI
     '''</summary>
@@ -51,7 +50,7 @@ Public Class HttpTwitter
             tks = accessTokenSecret
             un = username
         End If
-        con.Initialize(ConsumerKey, ConsumerSecret, accessToken, accessTokenSecret, username, "screen_name")
+        con.Initialize(DecryptString(ConsumerKey), DecryptString(ConsumerSecret), accessToken, accessTokenSecret, username, "screen_name")
         httpCon = con
         connectionType = AuthMethod.OAuth
     End Sub
index c9d0447..a578bcc 100644 (file)
@@ -9,12 +9,12 @@ Public Class TwitPic
     '''<summary>
     '''OAuthのコンシューマー鍵
     '''</summary>
-    Private Const ConsumerKey As String = "iOQHfiCUsyOyamW8JJ8jg"
+    Private Const ConsumerKey As String = "tLbG3uS0BIIE8jm1mKzKOfZ6EgUOmWVM"
 
     '''<summary>
     '''OAuthの署名作成用秘密コンシューマーデータ
     '''</summary>
-    Private Const ConsumerSecretKey As String = "5PS2oa5f2VaKMPrlZa7DTbz0aFULKd3Ojxqgsm142Dw"
+    Private Const ConsumerSecretKey As String = "M0IMsbl2722iWa+CGPVcNeQmE+TFpJk8B/KW9UUTk3eLOl9Ij005r52JNxVukTzM"
 
     Private Const PostMethod As String = "POST"
     Private Const GetMethod As String = "GET"
@@ -86,6 +86,6 @@ Public Class TwitPic
     Public Sub New(ByVal accessToken As String, ByVal accessTokenSecret As String)
         MyBase.New(New Uri("http://api.twitter.com/"), _
                    New Uri("https://api.twitter.com/1/account/verify_credentials.json"))
-        Initialize(ConsumerKey, ConsumerSecretKey, accessToken, accessTokenSecret, "")
+        Initialize(DecryptString(ConsumerKey), DecryptString(ConsumerSecretKey), accessToken, accessTokenSecret, "")
     End Sub
 End Class
index a33f13a..db285c6 100644 (file)
@@ -9,12 +9,12 @@ Public Class imgly
     '''<summary>
     '''OAuthのコンシューマー鍵
     '''</summary>
-    Private Const ConsumerKey As String = "iOQHfiCUsyOyamW8JJ8jg"
+    Private Const ConsumerKey As String = "tLbG3uS0BIIE8jm1mKzKOfZ6EgUOmWVM"
 
     '''<summary>
     '''OAuthの署名作成用秘密コンシューマーデータ
     '''</summary>
-    Private Const ConsumerSecretKey As String = "5PS2oa5f2VaKMPrlZa7DTbz0aFULKd3Ojxqgsm142Dw"
+    Private Const ConsumerSecretKey As String = "M0IMsbl2722iWa+CGPVcNeQmE+TFpJk8B/KW9UUTk3eLOl9Ij005r52JNxVukTzM"
 
     Private Const PostMethod As String = "POST"
     Private Const GetMethod As String = "GET"
@@ -84,6 +84,6 @@ Public Class imgly
     Public Sub New(ByVal accessToken As String, ByVal accessTokenSecret As String)
         MyBase.New(New Uri("http://api.twitter.com/"), _
                    New Uri("https://api.twitter.com/1/account/verify_credentials.json"))
-        Initialize(ConsumerKey, ConsumerSecretKey, accessToken, accessTokenSecret, "")
+        Initialize(DecryptString(ConsumerKey), DecryptString(ConsumerSecretKey), accessToken, accessTokenSecret, "")
     End Sub
 End Class
index 35d8db0..874697c 100644 (file)
@@ -10,12 +10,12 @@ Public Class yfrog
     '''<summary>
     '''OAuthのコンシューマー鍵
     '''</summary>
-    Private Const ConsumerKey As String = "iOQHfiCUsyOyamW8JJ8jg"
+    Private Const ConsumerKey As String = "tLbG3uS0BIIE8jm1mKzKOfZ6EgUOmWVM"
 
     '''<summary>
     '''OAuthの署名作成用秘密コンシューマーデータ
     '''</summary>
-    Private Const ConsumerSecretKey As String = "5PS2oa5f2VaKMPrlZa7DTbz0aFULKd3Ojxqgsm142Dw"
+    Private Const ConsumerSecretKey As String = "M0IMsbl2722iWa+CGPVcNeQmE+TFpJk8B/KW9UUTk3eLOl9Ij005r52JNxVukTzM"
 
     Private Const PostMethod As String = "POST"
     Private Const GetMethod As String = "GET"
@@ -88,6 +88,6 @@ Public Class yfrog
     Public Sub New(ByVal accessToken As String, ByVal accessTokenSecret As String)
         MyBase.New(New Uri("http://api.twitter.com/"), _
                    New Uri("https://api.twitter.com/1/account/verify_credentials.xml"))
-        Initialize(ConsumerKey, ConsumerSecretKey, accessToken, accessTokenSecret, "")
+        Initialize(DecryptString(ConsumerKey), DecryptString(ConsumerSecretKey), accessToken, accessTokenSecret, "")
     End Sub
 End Class
index 01ac69b..5f5b918 100644 (file)
@@ -8430,7 +8430,7 @@ RETRY:
         End If
 
         'その他のリンク(@IDなど)を置き換える
-        status = Regex.Replace(status, "@<a target=""_self"" href=""https?://twitter.com/(#!/)?(?<url>[^""]+)""[^>]*>(?<link>[^<]+)</a>", "${url}")
+        status = Regex.Replace(status, "@<a target=""_self"" href=""https?://twitter.com/(#!/)?(?<url>[^""]+)""[^>]*>(?<link>[^<]+)</a>", "@${url}")
         'ハッシュタグ
         status = Regex.Replace(status, "<a target=""_self"" href=""(?<url>[^""]+)""[^>]*>(?<link>[^<]+)</a>", "${link}")
         '<br>タグ除去
index f866dc7..a2a727e 100644 (file)
@@ -77,6 +77,8 @@
     <WarningsAsErrors>41999,42016,42017,42018,42019,42020,42021,42022,42032,42036</WarningsAsErrors>
     <CodeAnalysisIgnoreBuiltInRuleSets>false</CodeAnalysisIgnoreBuiltInRuleSets>
     <CodeAnalysisIgnoreBuiltInRules>false</CodeAnalysisIgnoreBuiltInRules>
+    <DefineConstants>
+    </DefineConstants>
   </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'">
     <DebugSymbols>true</DebugSymbols>
index 413ea77..31b6ccb 100644 (file)
@@ -2821,8 +2821,8 @@ Public Class Twitter
                 Exit Sub
             ElseIf xElm.Element("event") IsNot Nothing Then
                 Debug.Print("event: " + xElm.Element("event").Value)
-                If Array.IndexOf(EventNameTable, xElm.Element("event").Name.LocalName) = -1 Then
-                    TraceOut("Unknown Event:" + xElm.Element("event").Name.LocalName + Environment.NewLine + line)
+                If Array.IndexOf(EventNameTable, xElm.Element("event").Value) = -1 Then
+                    TraceOut("Unknown Event:" + xElm.Element("event").Value + Environment.NewLine + line)
                 End If
                 Exit Sub
             ElseIf xElm.Element("direct_message") IsNot Nothing Then