• Willkommen im Geoclub - dem größten deutschsprachigen Geocaching-Forum. Registriere dich kostenlos, um alle Inhalte zu sehen und neue Beiträge zu erstellen.

Alle Jahre wieder: Geolog Anmeldung bei geocaching.com schlägt fehl

geomitast

Geocacher
Gibt es eigentlich ein besseres Forum auf dieser Welt!?
Retorische Frage, natürlich nicht!!!
Danke ihr an alle, die auch das wieder gelöst haben! :gott: :gott: :gott:

geomitast
 

hjoe

Geocacher
Bei mir gibt es immer noch ein Problem, und zwar beim Aufruf

Code:
# -G Lade Statistik zu GC.com hoch
# -g Nur HTML Seiten erstellen
$ geolog -g -G

Code:
Lade Anmeldeseite ... [------------] Angemeldet!
Lade die 'Edit Profile' Seite ... .[----]
Sende Profil ... .[ There is no form with ID "aspnetForm" at ./geolog2.93h.pl line 7385.

Es ist ein Fehler aufgetreten: There is no form with ID "aspnetForm" at /usr/lib/perl5/vendor_perl/5.26.2/WWW/Mechanize.pm line 1941.

Und hoffe natürlich wieder auf Hilfe der Experten
Danke
 

wrtlbrmpft

Geocacher
Da ich meine Profil-Info mit GSAK erstelle hab ich das Problem nicht (mehr). Allerdings funktioniert auch hier das automatische Hochladen schon lange nicht mehr - es muss in der Profilseite die Info von Hand reinkopiert werden.

Als Workaround könntest Du das auch machen. Hol Dir den Quellcode der Datei gcdir\gcprofile.html und kopiere den in das Feld About vom Profil mit <STR>A und <STR>V. Ich mach das so mit dem Output von GSAK auch.

Hoffe das hilft weiter.
 

wrtlbrmpft

Geocacher
Wiederum hat GS anscheinend die Anmeldeseite umgestellt. Mit folgender Änderung ist das bei mir gerade wieder durchgelaufen:

Zeile 78 alt:
Code:
my ($version) = "2.93h";
Zeile 78 neu:
Code:
my ($version) = "2.93i";

Zeile 3972 alt:
Code:
            form_number => 2,
Zeile 3972 neu:
Code:
            form_number => 1,

wrtlbrmpft
 

Coolmonkey

Geocacher
Du bist ja schneller als der Schall. :applaus:
Ist mir gerade vor einer Stunde aufgefallen, dass es nicht mehr funktioniert. :???:

Danke für die schnelle Hilfe.

Gruß
Coolmonkey
 

geomitast

Geocacher
Grooooooßsssssssartig!
Danke!
Wie schon öfters erwähnt bestes Forum, beste User!!!!

Gesendet von meinem SM-G900F mit Tapatalk

 

wrtlbrmpft

Geocacher
Nun wurde wieder mal die Cache-Seite umgestellt und der Cache-Typ war nicht mehr zu erkennen. Mit folgender Änderung sollte das wieder funktionieren:

Zeile 78 alt:
Code:
my ($version) = "2.93i";
Zeile 78 neu:
Code:
my ($version) = "2.93j";

Zeile 6263 alt:
Code:
        /<a href=\"\/about\/cache_types.aspx\" target=\"_blank\" title=\"About Cache Types\".*?<img src=\"\/images\/WptTypes\/[0-9]+\.gif\" alt=\"(.*?)\" title/si;
Zeile 6263 neu:
Code:
        /<a href=\"\/about\/cache_types.aspx\" target=\"_blank\" title=\"(.*?)\" class=\"cacheImage\">/si;
 

Coolmonkey

Geocacher
wrtlbrmpft schrieb:
Nun wurde wieder mal die Cache-Seite umgestellt und der Cache-Typ war nicht mehr zu erkennen.

Die haben wohl nichts Besseres zu tun. :???:

Ohne dich wären wir hier aufgeschmissen :2thumbs:

Danke für die schnelle Hilfe.

Gruß
Coolmonkey
 

wrtlbrmpft

Geocacher
Wieder wurde die Login-Seite geändert - hier die Anpassungen:

Zeile 78 alt:
Code:
my ($version) = "2.93j";

Zeile 78 neu:
Code:
my ($version) = "2.93k";

Zeile 3974 alt:
Code:
                'Username' => $user,

Zeile 3974 neu:
Code:
                'UsernameOrEmail' => $user,
 

reindeer

Geocacher
Ich bräuchte dringend Hilfestellung, da ich seit längerer Zeit leider den Anschluss zum geolog-Programm und den nötigen Anpassungen verloren habe.
Meine letzten funktionierenden Aktualisierungen stammen mittlerweile vom 11.09.2016:
http://geolog.reindeer-geocaching.de
Vielleicht könnte mir jemand eine funktionierende exe-Datei schicken?
Oder gibt es irgendwo eine Anleitung, wie das mit perl funktioniert?
Vielen Dank schon mal.
 
OP
marsipulami0815

marsipulami0815

Geocacher
Hallo reindeer,

falls Du selber patchen willst/möchtest/kannst, dann hier ein ein "diff" von der Version 2.92 zur 2.93k, so wie sie bei mir noch läuft. Das sind alle Änderungen, die ich hier im Forum dazu mitbekommen habe. Wahrscheinlich wirst Du das nicht selber können, da Du ja nach einer EXE-Datei fragst, aber vielleicht kann das jemand anderes mit dem u.a. diff erledigen.

Zu geolog unter Windows mit PERL kann ich Dir leider nicht weiterhelfen, da ich das nicht im Einsatz habe.

VG, Marcus

Code:
--- geolog.pl-2.92	2015-08-07 16:36:00.000000000 +0200
+++ geolog.pl-2.93k	2018-12-29 16:40:36.971737394 +0100
@@ -75,7 +75,7 @@ require utf8;
 
 no utf8;
 
-my ($version) = "2.92";
+my ($version) = "2.93k";
 
 my ($geolog_agent)    = "Geolog/$version ($^O)";
 my ($mozilla_browser) = "User-Agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.0.6) Gecko/2009011913 Firefox/3.0.6";
@@ -148,7 +148,7 @@ my $logConf = q(
         log4perl.appender.Logfile.Filter                        = LogFilter
         
         log4perl.filter.LogFilter                               = Log::Log4perl::Filter::LevelRange
-        log4perl.filter.LogFilter.LevelMin                      = INFO
+        log4perl.filter.LogFilter.LevelMin                      = TRACE
         log4perl.filter.LogFilter.LevelMax                      = FATAL
         log4perl.filter.LogFilter.AcceptOnMatch                 = true
         
@@ -259,8 +259,8 @@ my ($loginURL)   = "https://www.geocachi
 my ($logsURL)    = "http://www.geocaching.com/my/logs.aspx";
 my ($parkingURL) = "http://www.geocaching.com/images/attributes/parking-yes.gif";
 my ($publicURL)  = "http://www.geocaching.com/images/attributes/public-yes.gif";
-my ($profileURL) = "http://www.geocaching.com/profile/";
-my ($accountURL) = "http://www.geocaching.com/myaccount/settings/preferences";
+my ($profileURL) = "https://www.geocaching.com/profile/";
+my ($accountURL) = "https://www.geocaching.com/account/settings/preferences";
 my ($logBookURL) = "http://www.geocaching.com/seek/geocache.logbook";
 my ($logBookStartURL) = "http://www.geocaching.com/seek/cache_logbook.aspx";
 
@@ -3726,7 +3726,7 @@ sub post_html {
     my ( $url, $av_sleep, $nl, $notlogin, @postparams ) = @_;
     my ( $req, $resp );
     my ($retry) = 2;
-    TRACE "<$url><$av_sleep><$nl><$notlogin><&postparams>";
+    TRACE "<$url><$av_sleep><$nl><$notlogin><@postparams>";
 
     init_browser() if ( !defined($browser) );
     $url = url($url);
@@ -3836,7 +3836,7 @@ sub get_cache_listing_page {
         }
     }
 
-    Encode::from_to( $content, "utf8", "iso-8859-1" );
+    #Encode::from_to( $content, "utf8", "iso-8859-1" );
     $content =~ s/\r//g if ($rem_cm);
 
     if ( $wpt eq "" ) {
@@ -3916,10 +3916,7 @@ sub init_ua {
 sub init_browser {
     TRACE "";
     #$browser = WWW::Mechanize::GZip->new(ssl_opts => { SSL_version => 'SSLv3', SSL_cert_file => Mozilla::CA::SSL_ca_file() });
-#    $browser = WWW::Mechanize::GZip->new(ssl_opts => { SSL_version => 'TLSv1'});
-###20150801 https://forum.geoclub.de/viewtopic.php?f=103&t=72200&start=20
-   $browser = WWW::Mechanize::GZip->new(ssl_opts => {verify_hostname => 0, SSL_verify_mode => SSL_VERIFY_NONE });
-###20150801 https://forum.geoclub.de/viewtopic.php?f=103&t=72200&start=20
+    $browser = WWW::Mechanize::GZip->new(ssl_opts => { SSL_version => 'TLSv1_2'});
     $browser->agent_alias('Windows Mozilla');
 
     $browser->add_handler( response_data   => \&cb_count );
@@ -3953,7 +3950,7 @@ sub login {
     $resp    = $browser->get($loginURL);
     $content = $browser->content();
     TRACE("Content: $content");
-    if ( $content =~ /You are logged in as/msi ) {
+    if ( $content =~ /ctl00_uxLoginStatus_divSignedIn/msi ) {
 	INFO( $EN
 	      ?"] Still logged in ...\n"
 	      :"] Immer noch angemeldet ... \n"
@@ -3972,12 +3969,11 @@ sub login {
 
     do {
         $browser->submit_form(
-            form_name => 'aspnetForm',
+            form_number => 1,
             fields    => {
-                'ctl00$ContentBody$tbUsername' => $user,
-                'ctl00$ContentBody$tbPassword' => $password,
-            },
-            button => 'ctl00$ContentBody$btnSignIn'
+                'UsernameOrEmail' => $user,
+                'Password' => $password,
+            }
             );
         $content = $browser->content();
         TRACE("Content: $content");
@@ -3991,7 +3987,7 @@ sub login {
                 );
         }
         #if ( $content =~ /You are logged in as/msi ) {
-		if ( $content =~ /class=\"LoginContainer LoggedIn\"/msi ) {
+		if ( $content =~ /\/my\/default\.aspx/msi ) {
 	    INFO( $EN
 		  ?"] Logged in!\n"
 		  :"] Angemeldet!\n"
@@ -3999,7 +3995,7 @@ sub login {
             $loggedin = 1;
         }
 #        elsif ( $content =~ /Your username\/password combination does not match. Make sure you entered your information correctly./msi  )
-		elsif ( $content =~ /class=\"FormSummaryWidget FormErrorWidget/msi  )
+		elsif ( $content =~ /class=\"validation-summary-errors/msi  )
         {
 	    INFO( $EN
 		  ?"\nLogin error!!\nPlease specify password for \"$username\": "
@@ -6236,6 +6232,7 @@ sub cachecoords {
     if( $text =~ /\"oldLatLngDisplay\":\"(.*?)\"}};/si)
     {
         $text = $1;
+		Encode::from_to( $text, "utf8", "iso-8859-1" );
         if($text =~ /([N|S] [0-9]+° [0-9]+.[0-9]+)'( [E|W] [0-9]+° [0-9]+.[0-9]+)'/si)
         {
             $coords = $1 . $2;
@@ -6245,6 +6242,7 @@ sub cachecoords {
 	elsif($text =~ /<span id=\"uxLatLon\">(.*?)<\/span>/si)
 	{
 		$text = $1;
+		Encode::from_to( $text, "utf8", "iso-8859-1" );
 		#coordinates not modified. use the coords from page
 		if($text =~ /([N|S] [0-9]+° [0-9]+.[0-9]+)( [E|W] [0-9]+° [0-9]+.[0-9]+)/si)
 		{
@@ -6262,9 +6260,9 @@ sub cachetype {
     my ($type);
     my ($mytype) = "";
     $text =~
-        /<a href=\"\/about\/cache_types.aspx\" target=\"_blank\" title=\"About Cache Types\"><img src=\"\/images\/WptTypes\/[0-9]+\.gif\" alt=\"(.*?)\" title/si;
+        /<a href=\"\/about\/cache_types.aspx\" target=\"_blank\" title=\"(.*?)\" class=\"cacheImage\">/si;
     $type = $1;
-
+    Encode::from_to( $type, "utf8", "iso-8859-1" );
     LOOP:
     {
         foreach my $cachetype (@cacheTypeTable)
@@ -6291,6 +6289,7 @@ sub cachecontainer {
   if ( $text =~  m%<img src=\"/images/icons/container/.*?\.gif\" alt=\"$langField{'size'}: (.*?)\"%si  )
   {
     $container = $1;
+    Encode::from_to( $container, "utf8", "iso-8859-1" );
     #Switch container name to containerindex
     $containerIndex = -1;
     LOOP: {
@@ -6558,7 +6557,7 @@ sub cacheattributes {
 
     while ( $text =~ /\/images\/attributes\//s ) 
     {
-        $text =~ /\/images\/attributes\/(.*?)\.gif(.*)/si;
+        $text =~ /\/images\/attributes\/(.*?)\.png(.*)/si;
         $text = $2;
         if ( $1 ne "alert-on" && $1 ne "attribute-blank" ) {
             if ( $attr eq "" ) {
@@ -6660,7 +6659,7 @@ sub download_or_compare_log_pictures {
 
         while ( $content =~ m%<p class="AlignCenter">%si ) {
 
-            if ( $content =~ m%<img alt=.*?src=\"(http://img\.geocaching\.com/cache/log)/thumb(/.*?)(\.gif|\.jpg|\.png|\.jpeg|\.tiff|\.bmp)\".*?>.*?<small>(.*?)<\/small>(.*?)$%si )
+            if ( $content =~ m%<img alt=.*?src=\"(https://img\.geocaching\.com/cache/log)/thumb(/.*?)(\.gif|\.jpg|\.png|\.jpeg|\.tiff|\.bmp)\".*?>.*?<span>(.*?)<\/span>(.*?)$%si )
             {
                 $picname = beautify_name($4);
                 $picurl  = $1 . $2 . $3;
@@ -7386,7 +7385,7 @@ sub upload_gccom_profile {
     INFO( $EN ? "]\nSend profile ... ": "]\nSende Profil ... " );
     rsleep($sleeppage);
     $browser->submit_form(
-        form_name => 'aspnetForm',
+        form_id => 'aspnetForm',
         fields    => {
             'ctl00$ContentBody$uxProfileDetails' =>
                 ( suck_in( $directory . "/gcprofile." . $htmlext ) )
@@ -11579,32 +11578,7 @@ sub get_picture_logs {
             );
         return;
     }
-    if ( $content =~
-         /<input type="hidden" name="__VIEWSTATE1" id="__VIEWSTATE1" value="([^"]*?)"/si
-        )
-    {
-        $viewstate1 = $1;
-    }
-    else {
-        ERROR ( $EN
-                ? "Could not identify VIEWSTATE1 value\n"
-                : "Konnte VIEWSTATE1-Wert nicht finden\n"
-            );
-        return;
-    }
-    if ( $content =~
-         /<input type="hidden" name="__VIEWSTATEFIELDCOUNT" id="__VIEWSTATEFIELDCOUNT" value="([^"]*?)"/si
-        )
-    {
-        $viewstatefieldcount = $1;
-    }
-    else {
-        ERROR ( $EN
-                ? "Could not identify VIEWSTATEFIELDCOUNT value\n"
-                : "Konnte VIEWSTATEFIELDCOUNT-Wert nicht finden\n"
-            );
-        return;
-    }
+
     if ( $content =~ /ctl00_ContentBody_ProfilePanel1_lnkGallery.*?href="javascript:__doPostBack\('(.*?)',''\)">.*?ctl00_ContentBody_ProfilePanel1_lnkLists/si )
     {
         $eventtarget = $1;
@@ -11624,9 +11598,7 @@ sub get_picture_logs {
             $profileURL, $sleeppage, 0, 0,
             __EVENTTARGET  => $eventtarget,
             __EVENTARGUMENT => '',
-            __VIEWSTATEFIELDCOUNT => $viewstatefieldcount,
             __VIEWSTATE    => $viewstate,
-            __VIEWSTATE1   => $viewstate1
             );
         $content = $resp->content;
         store_file( $content, $directory . "/saving/pics_$count.html", 0, 0 )
@@ -11650,30 +11622,6 @@ sub get_picture_logs {
             );
             return;
         }
-        if ( $content =~ /<input type="hidden" name="__VIEWSTATE1" id="__VIEWSTATE1" value="([^"]*?)"/si )
-        {
-            $viewstate1 = $1;
-        }
-        else {
-            ERROR ( $EN
-                ? "Could not identify VIEWSTATE1 value\n"
-                : "Konnte VIEWSTATE1-Wert nicht finden\n"
-            );
-            return;
-        }
-        if ( $content =~
-             /<input type="hidden" name="__VIEWSTATEFIELDCOUNT" id="__VIEWSTATEFIELDCOUNT" value="([^"]*?)"/si
-            )
-        {
-            $viewstatefieldcount = $1;
-        }
-        else {
-            ERROR ( $EN
-                ? "Could not identify VIEWSTATEFIELDCOUNT value\n"
-                : "Konnte VIEWSTATEFIELDCOUNT-Wert nicht finden\n"
-                );
-            return;
-        }
         
         if ($count > $numberofPages)
         {
@@ -11690,7 +11638,7 @@ sub findloggcids {
     my (@result) = ();
 
     TRACE "<$text>";
-    while ( $text =~ m|http://www\.geocaching\.com\/seek/log\.aspx\?LUID=([^&]*?)&IID=|gsi )
+    while ( $text =~ m|https://www\.geocaching\.com\/seek/log\.aspx\?LUID=([^&]*?)&IID=|gsi )
     {
         if ( defined( $luid2gcid{$1} ) ) {
             push( @result, $luid2gcid{$1} );
@@ -11997,7 +11945,7 @@ sub db_putGcUser {
         %dbuser = %user;
     }
 
-    $sql = qq(INSERT OR REPLACE INTO gcUserTable (name, luid, userid) VALUES ( \"$dbuser{'name'}\", \"'$dbuser{'luid'}'\", \"$dbuser{'userid'}\" ));
+    $sql = qq(INSERT OR REPLACE INTO gcUserTable (name, luid, userid) VALUES ( \"$dbuser{'name'}\", \"$dbuser{'luid'}\", \"$dbuser{'userid'}\" ));
     $sth = $db->prepare($sql);
     $sth->execute;
 }
@@ -12060,8 +12008,8 @@ sub get_date_format {
     my ($content) = @_;
     TRACE "<content>";
     INFO( $EN
-          ? "\n  Search for date format"
-          : "\n  Suche Datumsformat"
+          ? "\n Search for date format "
+          : "\n Suche Datumsformat "
         );
     if ( $content =~ /<select.*? id=\"SelectedDateFormat\".*?>(.*?)<\/select>/si )
     {
@@ -12118,7 +12066,7 @@ sub get_language
         {
             INFO( $EN
                   ? "Could not identify selected language"
-                  : "Konnte ausgewaehltes Sprache nicht identifzieren"
+                  : "Konnte ausgewaehlte Sprache nicht identifzieren"
                 );
             return "";
         }
@@ -12126,7 +12074,7 @@ sub get_language
     else {
         INFO($EN
              ? "Could not identify selected language"
-             : "Konnte ausgewaehltes Sprache nicht identifzieren"
+             : "Konnte ausgewaehlte Sprache nicht identifzieren"
             );
         return "";
     }
@@ -12201,11 +12149,11 @@ sub getNameFromUid {
 
     $content = get_user_profile_page( $guid, 1 );
 
-    if ( $content =~ m%<span id=\"ctl00_ContentBody_lblUserProfile\".*?>$langField{'profileFor'} .*?: (.*?)</span>.*?id=\"ctl00_ContentBody_ProfilePanel1_lnkSeePosts.*?\&amp\;mid=(.*?)\"%si )
+    if ( $content =~ m%<a id=\"ctl00_ProfileHead_ProfileHeader_lnkSeePosts\".*?/profile/(.*?)-(.*?)/content/\">%si )
     {
-        $user{'name'}   = $1;
+        $user{'name'}   = $2;
         $user{'luid'}   = $guid;
-        $user{'userid'} = $2;
+        $user{'userid'} = $1;
     }
     else {
         $name = "UNKOWN (GC layout changed!)";
 

wrtlbrmpft

Geocacher
Hallo reindeer,

hier meine damalige Bemerkung zur erfolgreichen Installation von StrawberryPerl auf Windows 10:
https://geoclub.de/forum/viewtopic.php?f=103&t=78873&p=1259836&hilit=strawberry#p1259836
Traust Du Dir das zu?

Die aktuelle Version von geolog.pl ist allerdings in der Zwischenzeit 2.93k.

Weiter unten ist auch eine Notiz zur Installation von ActivePerl .
 

reindeer

Geocacher
Vielen Dank für eure Antworten. Ich habe StrawberryPerl installiert.
Dann habe ich obigen Code als Textdatei geolog.pl abgespeichert.
Aber ich glaube, ich muss noch einiges nachinstallieren (aber was?), denn beim Starten wird mir folgendes angezeigt:

C:\>perl c:\zumtesten\geolog.pl
Number found where operator expected at c:\zumtesten\geolog.pl line 1, near "2.92 2015"
(Missing operator before 2015?)
Number found where operator expected at c:\zumtesten\geolog.pl line 1, near "07 16"
(Missing operator before 16?)
Bareword found where operator expected at c:\zumtesten\geolog.pl line 2, near "2.93k"
(Missing operator before k?)
Number found where operator expected at c:\zumtesten\geolog.pl line 2, near "k 2018"
(Do you need to predeclare k?)
Number found where operator expected at c:\zumtesten\geolog.pl line 2, near "29 16"
(Missing operator before 16?)
Array found where operator expected at c:\zumtesten\geolog.pl line 3, near "@@"
(Missing semicolon on previous line?)
Array found where operator expected at c:\zumtesten\geolog.pl line 3, near "7 @@"
(Missing operator before @@?)
Can't modify constant item in predecrement (--) at c:\zumtesten\geolog.pl line 1, near "geolog."
syntax error at c:\zumtesten\geolog.pl line 1, near "2.92 2015"
Illegal octal digit '8' at c:\zumtesten\geolog.pl line 1, at end of line
BEGIN not safe after errors--compilation aborted at c:\zumtesten\geolog.pl line 5.

Ich wünsche Euch einen Guten Rutsch ins Neue Jahr! :margarita:
 

reindeer

Geocacher
OK, ich weiß ja ungefähr, wie es funktioniert.
Aber die mit:
pp -o c:/zumtesten/geolog.exe c:/zumtesten/geolog.pl
erzeugte exe-Datei bringt die gleichen Fehlermeldungen.
Wie lautet den der korrekte Programmaufruf?
 

SammysHP

Moderator
Teammitglied
Obiger "Code" ist kein Perl-Script, sondern nur die Änderungen, die an der letzten Version mittels "patch" durchgeführt werden müssen!
 
Oben