Support » Plugin: WP Instagram Widget » URL signature expired

Viewing 6 replies - 1 through 6 (of 6 total)
  • changed
    # of photos: 6

    Plugin Author Scott (@scottsweb)

    (@scottsweb)

    This might be due to the way that images are scraped from the Instagram site. They have made changes to the JSON in the past that has stopped this method working correctly. Right now though I am not seeing any problems.

    Did switching from 9 to 6 photos fix it for you?

    Hi Scott.
    No. It actually didn’t.
    Tested the site on two different computers (Chrome) and still getting the error.
    No javascript errors on console.
    I develop using Chrome.
    On mozilla still getting the same error.
    Strangely on Safari from my iPhone 6, it does open correctly.

    Could it be that I’m sending too many requests from the same IP address?
    The other two computers that I mention above where I tested are from two locations where I usually work and develop this site.

    Chrome Network Headers Response:
    GENERAL
    Request URL: http://scontent-frx5-1.cdninstagram.com/vp/ae77610f0d6afa6bf0b7a55678d3986e/5B60E8E1/t51.2885-15/s150x150/e35/30079230_1907141035976984_4374829403960508416_n.jpg
    Request Method: GET
    Status Code: 403 Forbidden
    Remote Address: 185.60.216.52:80
    Referrer Policy: no-referrer-when-downgrade

    RESPONSE HEADERS
    Connection: keep-alive
    Content-Length: 21
    Content-Type: text/plain (Is this due to the 403 Forbidden??)
    Date: Tue, 14 Aug 2018 14:08:06 GMT
    Server: proxygen-bolt

    REQUEST HEADERS
    (Alert Icon)Provisional headers are shown
    DNT: 1
    Referer: http://aislapur.xicnet.com/
    User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36

    fetch
    fetch(“http://scontent-frx5-1.cdninstagram.com/vp/ae77610f0d6afa6bf0b7a55678d3986e/5B60E8E1/t51.2885-15/s150x150/e35/30079230_1907141035976984_4374829403960508416_n.jpg”, {“credentials”:”omit”,”headers”:{},”referrer”:”http://aislapur.xicnet.com/”,”referrerPolicy”:”no-referrer-when-downgrade”,”body”:null,”method”:”GET”,”mode”:”cors”});

    curl
    curl “http://scontent-frx5-1.cdninstagram.com/vp/ae77610f0d6afa6bf0b7a55678d3986e/5B60E8E1/t51.2885-15/s150x150/e35/30079230_1907141035976984_4374829403960508416_n.jpg” -H “Referer: http://aislapur.xicnet.com/” -H “User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36” -H “DNT: 1” –compressed

    Power Shell
    Invoke-WebRequest -Uri “http://scontent-frx5-1.cdninstagram.com/vp/ae77610f0d6afa6bf0b7a55678d3986e/5B60E8E1/t51.2885-15/s150x150/e35/30079230_1907141035976984_4374829403960508416_n.jpg” -Headers @{“Referer”=”http://aislapur.xicnet.com/”; “User-Agent”=”Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36”; “DNT”=”1”}

    webworksjoe

    (@webworksjoe)

    I’m experiencing the same issue with a recently launched site.

    Seems like if the signature expires before the cache, you get a 403 and the alt text displayed.

    Ended up turning into the https://lightwidget.com/ widget.
    So far working fine.
    A pitty since I really liked the look and feel I achieved with this plugin

    Plugin Author Scott (@scottsweb)

    (@scottsweb)

    @webworksjoe that is good feedback. We might be caching a touch aggressively in the plugin (default is 2 hours) and Instagram are expiring the URLs for images before that.

    If anyone on this thread is still experiencing problems, I would like you to add this code to your theme:

    
    add_filter('null_instagram_cache_time', 'my_cache_time');
    
    function my_cache_time() {
        return HOUR_IN_SECONDS/2;
    }
    

    This will reduce our cache time to 30 minutes which will hopefully mean there is less chance the URLs will expire.

    Please report back if that works for you.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘URL signature expired’ is closed to new replies.