Is Fibonacci-XOR-rotate one-way-ish? Fix $n\in\mathbb{N}$ with $n &gt; 2$ and consider the following method.
Pick relatively prime seeds $x_1, x_2 \in \{0,1\}^n$ (where $x_1, x_2$ are interpreted as binary numbers. Then proceed with the following algorithm (C code is given below):

Let r = x1 ^ x2 (bitwise XOR; the &quot;Fibonacci&quot; step).
Rotate r to the right by 1 position.
Let x1 = x2 and x2 = r.
Output x1 and repeat.

Question. Given some output of unknown seeds after an unknown number of steps, is it &quot;computationally hard&quot; to find a pair of seeds that produce the given output after a number of steps?
Here's the C code:

#include &lt;stdio.h&gt;

unsigned rotate (unsigned n, int len); 
       // len == length of rotation (number of bits rotated)
unsigned fibo_xor_rotate(unsigned n1, unsigned n2, int len); 

// ---------------------------------
unsigned rotate (unsigned n, int len) // l == length
{
  unsigned b = n &amp; 1; // get right-most bit
  n = n &gt;&gt; 1;
  n = n | (b &lt;&lt; (len-1)); 
     // insert right-most bit at left end
  return n;
}
// ---------------------------------
unsigned fibo_xor_rotate(unsigned n1, unsigned n2, int len) 
    // Fibonacci XOR and then rotate
{
  unsigned result = n1 ^ n2; // &quot;Fibonacci&quot; step
  return rotate(result, len);  // &quot;Scramble&quot; step
}
// ---------------------------------
int main()
{
  int i = 0;
  unsigned x1 = 0xd;  // seed 1
  unsigned x2 = 0x80; // seed 2
  unsigned h; // helper variable
  int my_len = 8; // length of rotation, here: 8 (-&gt; byte length)
  while (i &lt; 100)
  {
    printf(&quot;%x,&quot;, x2);
    h = x2;
    x2 = fibo_xor_rotate(x1, x2, my_len); // fibo xor rotate
    x1 = h; // set x1 to &quot;old&quot; x2
    if (i % 10 == 9) { 
       printf(&quot;\n&quot;); // newline after 10 prints
    }
    i++;
  }
  return 0;
}
Given some output of unknown seeds after an unknown number of steps, is it &quot;computationally hard&quot; to find a pair of seeds that produce the given output after a number of steps?

Nope; two observations:

With two successive outputs, you can compute the internal state; if you see the outputs $y_1, y_2$, then the internal state immediately after the first output was $x_1 = y_1, x_2 = y_2$

Given the internal state, you can compute previous states; if the state at time $t$ was $x_1 = y_1, x_2 = y_2$, then the state at time $t-1$ was $x_1 = rotl(y_2) \oplus y_1, x_2 = y_1$ (where $rotl$ is 'rotate shift left by one')


These two observations allow an attacker to revert this generator as far as he needs to.
Actually, for reverting arbitrarily long distances, there are other tricks that reduce the number of computations needed (logarithmic in the size of the time delta; constant time is likely possible, but I don't want to promise that), however we don't need to go to that extent to show that this is weak.