You are here

Vanishing pictures

36 posts / 0 new
Last post
Mannast
Vanishing pictures

So I noticed only a few days ago that the virtual face, picture or avatar I had uploaded a couple of years ago was gone.  Okay - it was a Potter picture of Luna wearing the Griffon outfit from the film.  So I thought - gee it was removed.  I didn't get a message or note or anything, but <sigh> things happen.  I uploaded a photo I took at a festival or faire of a dragon egg sculpture.  I come back the next day (this morning, I think) and notice it, too, has been removed.  No note or message.  I sent a message off to Rolo, though I don't know if they are the person for such things.  And I uploaded a sily old picture of Tom Baker dressed as sherlock holmes.  I come back a few hours later and it is gone.  If I am violating something, I need to be made aware of it - otherwise, I'm not sure why my pictures keep getting removed.  If it is another matter - well, I wonder if others have experienced it.

Portable Hole System, Scry and Teleport System, Throwing Objects, Prodding Traps, Portable Placeables and a Vanilla Basemodule, among other things

  • up
    50%
  • down
    50%
Tarot Redhand

Try contacting Fester Pot instead, Rolo is busy doing something elsewhere for several months now.

<edit>

Just noticed mine has gone as well so I've pm'd FP myself.

TR

  • up
    50%
  • down
    50%
kevL's

for da record, the only avatar I see while browsing the forums is my own

they disappeared -- started to disappear? -- a week or so ago ...

  • up
    50%
  • down
    50%
kamal

Well I see kevL's and some other people. I just looked and mine had gone missing, restored it. A bug of some sort as mine is just a picture of the nwn2 toolset icon.

  • up
    50%
  • down
    50%
kevL's

kamal's reappeared fer me (yeah!)

  • up
    50%
  • down
    50%
niv

Not sure what's going on here. No one is removing pictures deliberately, and we haven't run any updates that would do so. Will keep an eye on it.

  • up
    100%
  • down
    0%
VaultDuke

I had to reupload mine as well a few days ago. Posting to see if it's still here, now.

 

edit: nope. They're being eaten by internet-Gremlins

 

 

 

  • up
    50%
  • down
    50%
kamal

Yes, I went into my profile and uploaded the icon when I saw this thread. My profile was not listing an icon when I looked.

  • up
    50%
  • down
    50%
Tarot Redhand

Same here. Let's see how long this new one lasts. Well at least it gave me the excuse to change it.

TR

  • up
    50%
  • down
    50%
Proleric
Proleric's picture

@TR - I don't see the new one. Must be a zen Cheshire cat...

NWN and DAO adventures at http://proleric.com/

  • up
    50%
  • down
    50%
kamal

"Same here. Let's see how long this new one lasts. Well at least it gave me the excuse to change it.

TR"

 

  • up
    100%
  • down
    0%
Tarot Redhand

One thought what image file format is everyone using who's had their avatar vanish. Mine are always in png. Also going to test another theory...

TR

  • up
    50%
  • down
    50%
Tarot Redhand

Well I've proved 1 thing. I can upload a new image and see it all over the vault. But as soon as I log out it vanishes. So at least part of the problem area has to be in the log out routines for this site.

If anyone is interested I've posted the image I was trying to use in the new forums here.

TR

  • up
    50%
  • down
    50%
kamal

Confirming what Tarot said. I logged out and back in, avatar gone.

  • up
    50%
  • down
    50%
Fester Pot

It would seem that an Drupal Core update to v7.56 was applied sometime between Friday and Saturday.

Portraits were affected by the update.
 

"Private files that have been uploaded by an anonymous user but not permanently attached to content on the site should only be visible to the anonymous user that uploaded them, rather than all anonymous users. Drupal core did not previously provide this protection, allowing an access bypass vulnerability to occur. This issue is mitigated by the fact that in order to be affected, the site must allow anonymous users to upload files into a private file system.

The security team has also received reports that this vulnerability is being exploited for spam purposes, similar to the scenario discussed in PSA-2016-003 for the public file system."

FP!

 

  • up
    100%
  • down
    0%
Tarot Redhand

So how come some are anonymous and not all?

TR

  • up
    50%
  • down
    50%
Mannast

Of two minds - Frustrated that it is happening.  Glad it wasn't just me.indecision

  • up
    50%
  • down
    50%
meaglyn

All these people (me included) are registered users not anonyous users, though.  And the portrait is not visible to the user who uploaded it or anyone else  I'm not sure how that fix should do this unless it was itself broken.   I don't think we allow anonymous users to upload files anyway.

Cheers,

Meaglyn

  • up
    100%
  • down
    0%
Fester Pot

 Ya might have to reupload your portrait - I had to as well - but can't say why some are not showing and some are.

Use the browse function and locate your image on your local PC.

Scroll down and click SAVE under your account.

As an example, I modified Mannast and gave him a D&D card portrait to see if it worked.

FP!

  • up
    50%
  • down
    50%
Empyre65

Let's see if my golden knight avatar remains when I visit again tomorrow.

"Never laugh in the face of a live dragon." - Bilbo Baggins

  • up
    50%
  • down
    50%
Tarot Redhand

@FP Did that before. Just did it again. Still the same. Will try something else I've just thought of.

<edit>

That didn't work either.

TR

  • up
    50%
  • down
    50%
Fester Pot

Is it a .jpg file you are trying to make as your portrait? .gif and .png would work as well, like Empyre65 (.gif) and Meaglyn (.png), although I would stick to .jpg and .gif. Meaglyn has admin access and might be able to use .png where other roles may not be set to do so.

Empyre65, Mannast and VaultDuke all have the same permission role of Posting Privileges and none other, so I do not know why Empyre65 is able to upload a portrait and have it displayed and Mannast and VaultDuke cannot. Simply browsing to the .jpg file is not enough, so if either of you did not scroll down and select SAVE to save your account changes, this could be why.

As for you TR, your permission role is the basic Posting Privileges PLUS AME Fellow and Moderator.

Proleric has the basic Posting Privileges PLUS Author and Moderator and has reuploaded their portrait.

For testing purposes, I've knocked off your AME Fellow role and given you Author just like Proleric's roles. Let's see how that works as it might be related to the specific roles some users have been assigned outside of the Posting Privlieges.

Still, it does not answer the question as to why Mannast and VaultDuke's portraits are not being saved, yet Empyre65 has no problem with all three having the same site privileges. *shrugs*

FP!

  • up
    50%
  • down
    50%
GCoyote

Sometimes when I see these kinds of inconsistent errors on my site, the issue seems to be data corruption in the user account. We use vBulletin and that requires a cumbersome multiple step fix. Not sure how hard it would be in Drupal.

<b>"Please VOTE on the content you play."</b>

  • up
    50%
  • down
    50%
Proleric
Proleric's picture

Fester Pot wrote "Proleric has the basic Posting Privileges PLUS Author and Moderator and has reuploaded their portrait."

Actually, I didn't reupload my portrait - haven't touched it for months. I just tried logging out for the first time since this discussion began. Portrait vanished.

  • up
    50%
  • down
    50%
meaglyn

Yeah,  actually logging out removes it. I'd re-uploaded mine yesterday, but just a quick logout and back in and it's gone.   I have admin rights too so I don't think it's related to the fix FP referenced...

 

  • up
    50%
  • down
    50%
Fester Pot

Tried it myself just now.

Logging out nukes personalized portrait on logging back in. :/

FP!

  • up
    50%
  • down
    50%
Proleric
Proleric's picture

Likewise, after adding a new portrait, it persists when I return to the site, as long as I don't log off, then log in again.

EDIT : confirmed FP's finding that logging in is the culprit.

  • up
    50%
  • down
    50%
Tarot Redhand

Unfortunately the fix didn't work. One thing I did notice. When you select the picture to use but before you save your changes, only the picture name is shown. Now I can't remember 100% but I think it used to show the picture once you had selected it. Once you save the changes the picture shows. FWIW I am using png images and the one I am trying to use is displayed in the new forums which linked to in an earlier post here.

TR

  • up
    50%
  • down
    50%
Fester Pot

Seems like v7.56 is the culprit as someone has reported the issue on the Drupal forum.

"This is still an issue for Drupal 7.56.

The committed patch has tests that do not test all possible variations of the issue. More specifically, the tests that calling the user_save() with an object that was just created works, but it does NOT test user_save() with a 'light' user object usually accessible from global $user. This 'light' user object has picture value loaded as FID rather then object and the code in user_save() is still unable to properly handle this situation.

Adam Clarey points out absolutely correctly that we need to handle the case where FID rather then file object is specified. We also need to add a test that will show that saving 'light' user object actually removes picture."
 

User picture is deleted after calls to user_save()


 

Problem/Motivation

User pictures are being deleted when user objects are re-saved.

user_save() calls drupal_write_record() to save the user account object. drupal_write_record() expects $account->picture to be the fid of the image file. So user_save() converts $account->picture from a file object to an integer before writing it to the database. Thus the file's properties are lost.

Proposed resolution

Save the file object to a variable before the call to drupal_write_record(). Set $account->picture back to the file object after the write.



Another user posted a fix, but it is beyond my meager average bear skills.
 

diff --git a/modules/user/user.module b/modules/user/user.module
index b239799..8f371c5 100644
--- a/modules/user/user.module
+++ b/modules/user/user.module
@@ -501,6 +501,10 @@ function user_save($account, $edit = array(), $category = 'account') {
         file_usage_delete($account->original->picture, 'user', 'user', $account->uid);
         file_delete($account->original->picture);
       }
+      // Fixes issue where user picture was deleted after calls to user_save().
+      if (is_object($account) && !is_object($account->picture) && $account->picture > 0) {
+        $account->picture = file_load($account->picture);
+      }
       $account->picture = empty($account->picture->fid) ? 0 : $account->picture->fid;
 
       // Do not allow 'uid' to be changed.


FP!

 

  • up
    50%
  • down
    50%
Empyre65

So, you are saying that mine is working because I didn't log out? Is here a reason I should be logging out like some of you are?

  • up
    50%
  • down
    50%
Tarot Redhand

I log out for 2 reasons. I consider it proper form i.e. for me it feels more polite. The other reason is paranoia. I have set my browser to delete both its cache and all cookies when I turn it off (also my Browser, Opera, has a built in adblocker which I have turned on and I use the both the adblock+ and ghostery extensions). So as I assume that this sight uses a cookie to record the fact of my being logged, I would be automatically logged out anyway when I close my browser.

BTW re my paranoia. Did you know that the DoubleClick (now owned by google) tracker is active on the front page before you login but not after?

TR

  • up
    100%
  • down
    0%
kamal

Also sometimes my browser just decides it's gonna log me out. I come to the vault and I'm not logged in. Whatever for me, since the browser autofills my info and I just click login, so I never bothered to investigate.

  • up
    100%
  • down
    0%
rjshae

Yup, I have the same issue. Log out => log in => no avatar. Ah the joys of open source software.

Presumably there is a site login cookie that times out after some number of days, leaving one logged out.

  • up
    50%
  • down
    50%
meaglyn

"Yup, I have the same issue. Log out => log in => no avatar. Ah the joys of open source software."

I wouldn't put it that way. FP has the code for the fix. Someone with access to the file system could apply that patch and make this problem go away in like 2 seconds.  You can't do that with closed source software...

  • up
    50%
  • down
    50%
rjshae

"I wouldn't put it that way. FP has the code for the fix. Someone with access to the file system could apply that patch and make this problem go away in like 2 seconds.  You can't do that with closed source software..."

Sure. Sometimes you get a fix right away, sometimes you don't... for a long, long time. I've been there.

 

  • up
    100%
  • down
    0%
niv

I've manually merged the patch in; it doesn't work! Will look into it further.

PS @Tarot: We don't run run DoubleClick or any ads. When you're seeing ads, then that's local to your browser and should be checked. What we DO run is google analytics in basic mode to have visitor statistics.

  • up
    100%
  • down
    0%